EdgeDB Python driver
Project description
edgedb-python is the official EdgeDB driver for Python. It provides both blocking IO and asyncio implementations.
The library requires Python 3.6 or later.
Documentation
The project documentation can be found here.
Installation
The library is available on PyPI. Use pip to install it:
$ pip install edgedb
Basic Usage
import datetime
import edgedb
def main():
# Establish a connection to an existing database named "test"
# as an "edgedb" user.
conn = edgedb.connect('edgedb://edgedb@localhost/test')
# Create a User object type
conn.execute('''
CREATE TYPE User {
CREATE REQUIRED PROPERTY name -> str;
CREATE PROPERTY dob -> local_date;
}
''')
# Insert a new User object
conn.fetchall('''
INSERT User {
name := <str>$name,
dob := <local_date>$dob
}
''', name='Bob', dob=datetime.date(1984, 3, 1))
# Select User objects.
user_set = conn.fetchall(
'SELECT User {name, dob} FILTER .name = <str>$name', name='Bob')
# *user_set* now contains
# Set{Object{name := 'Bob', dob := datetime.date(1984, 3, 1)}}
# Close the connection.
conn.close()
if __name__ == '__main__':
main()
Development
Instructions for installing EdgeDB and edgedb-python locally can be found at edgedb.com/docs/internals/dev/.
To run the test suite, run $ python setup.py test.
License
edgedb-python is developed and distributed under the Apache 2.0 license.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
File details
Details for the file edgedb-0.7.0a8.tar.gz
.
File metadata
- Download URL: edgedb-0.7.0a8.tar.gz
- Upload date:
- Size: 712.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 09a86cb8ce3e617671e36590ab8d50db2228b6f4e47ef448fa1749ef1189eb2e |
|
MD5 | 6805790bca731208fd2b3c1f79dddfaa |
|
BLAKE2b-256 | 77a2b27c78d846a51414e8e6a8409fd2752f89e9ce1feceaf02ccf09f9b54bbd |
File details
Details for the file edgedb-0.7.0a8-cp38-cp38-win_amd64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp38-cp38-win_amd64.whl
- Upload date:
- Size: 1.2 MB
- Tags: CPython 3.8, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7384090dfbb81ff4cff0a6987a0e471ccc5292f0f757d162ce436efa87f887fc |
|
MD5 | 4e0b1cc3cd27b08ec05f6f944aae59e6 |
|
BLAKE2b-256 | 31259ff8b1ea35ed1e67e39a86bbfe93fd4dcf98a7ec5cb2994f347c2aba8a18 |
File details
Details for the file edgedb-0.7.0a8-cp38-cp38-manylinux1_x86_64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp38-cp38-manylinux1_x86_64.whl
- Upload date:
- Size: 2.8 MB
- Tags: CPython 3.8
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a4731ad8cb2613713b5e5318049a311806502b8de2123fed76e59cb74a0a11df |
|
MD5 | 6953fb8aea459ba255afc51272d4aef3 |
|
BLAKE2b-256 | a6b4b06545be327ac3189c91072a5521c035f490a95d01499c8d0ad280f5b495 |
File details
Details for the file edgedb-0.7.0a8-cp38-cp38-macosx_10_13_x86_64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp38-cp38-macosx_10_13_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.8, macOS 10.13+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 812109b2e98c7e36c08640559cb036b45417f1b59885db443c27c81e192a5af8 |
|
MD5 | 244acedccba0bdad940c4215b3797fd4 |
|
BLAKE2b-256 | 5278699ebbd6c7b36ef5273f0417404793da88a8fd99c40af180681ba3c8a9b3 |
File details
Details for the file edgedb-0.7.0a8-cp37-cp37m-win_amd64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp37-cp37m-win_amd64.whl
- Upload date:
- Size: 1.1 MB
- Tags: CPython 3.7m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4c9a3550041f133ca57f5696d7701351a9085f89756b4b00f6d48b415c16995e |
|
MD5 | 0955c104e982277376a97600304b4ab2 |
|
BLAKE2b-256 | 3dd57a938711d02e71ad54970caeb21c5ecbe544184890f4e78c47e9ce2c46f0 |
File details
Details for the file edgedb-0.7.0a8-cp37-cp37m-manylinux1_x86_64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp37-cp37m-manylinux1_x86_64.whl
- Upload date:
- Size: 2.7 MB
- Tags: CPython 3.7m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e9034c762a14f624381417ce309dfde3b9783ca7f46c0a6b9b182942c5370498 |
|
MD5 | 2aa033bcbf44fea41349c5bc9339bb63 |
|
BLAKE2b-256 | b729762da19ce1847e10d03501875a3b1d4e1c54a831c5cfab0c10cd0bf07bca |
File details
Details for the file edgedb-0.7.0a8-cp37-cp37m-macosx_10_13_x86_64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp37-cp37m-macosx_10_13_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.7m, macOS 10.13+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8e61ffbebbca8aa1227b2bb6ab39b4791726f10ab3fbd94f69d570b7ef3eb74d |
|
MD5 | 283c47dd8c8181cd76e0fd00b6f7c9b6 |
|
BLAKE2b-256 | 0ecf5f93591aa9a9446d4f6deea23815926a09d2376309241dcec74105ae9929 |
File details
Details for the file edgedb-0.7.0a8-cp36-cp36m-win_amd64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp36-cp36m-win_amd64.whl
- Upload date:
- Size: 1.1 MB
- Tags: CPython 3.6m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9059fc96a0a42cf6e1f7dba75ffd52939fb61adc68fdb610a0081cca8f3dba60 |
|
MD5 | 7a59adbcd06b213216dd3f13771461f3 |
|
BLAKE2b-256 | cc204cdf4ef06585398db1c28fb8f8c8583818b364e860e3742aee8c4d443992 |
File details
Details for the file edgedb-0.7.0a8-cp36-cp36m-manylinux1_x86_64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp36-cp36m-manylinux1_x86_64.whl
- Upload date:
- Size: 2.7 MB
- Tags: CPython 3.6m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7291fb67ee3636d82ce8d198167c692ec636f5e0f17bef225314cb7f9e0d2058 |
|
MD5 | d0df55a25079279c107796959acc0116 |
|
BLAKE2b-256 | 2a6a79a79b5145ddfb8ff6cba5afd73f7424570dd6926395de55a335a681de68 |
File details
Details for the file edgedb-0.7.0a8-cp36-cp36m-macosx_10_13_x86_64.whl
.
File metadata
- Download URL: edgedb-0.7.0a8-cp36-cp36m-macosx_10_13_x86_64.whl
- Upload date:
- Size: 1.3 MB
- Tags: CPython 3.6m, macOS 10.13+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.41.1 CPython/3.7.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f47202a9a7082cde5bd9d325ce7d5366df7191ac0eb2f6825551836065431c4d |
|
MD5 | e75e407ccba920f602bdb131d9d61b82 |
|
BLAKE2b-256 | cb1c2d541a2711f1e82c3b090cf8b0191ddb1ddfd012af5545e10fbe41d9cafa |