Skip to main content

EdgeDB Python driver

Project description

https://github.com/edgedb/edgedb-python/workflows/Tests/badge.svg?event=push&branch=master https://img.shields.io/pypi/v/edgedb.svg https://img.shields.io/badge/join-github%20discussions-green

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 -> cal::local_date;
        }
    ''')

    # Insert a new User object
    conn.query('''
        INSERT User {
            name := <str>$name,
            dob := <cal::local_date>$dob
        }
    ''', name='Bob', dob=datetime.date(1984, 3, 1))

    # Select User objects.
    user_set = conn.query(
        '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

edgedb-0.13.0.tar.gz (776.3 kB view details)

Uploaded Source

Built Distributions

edgedb-0.13.0-cp39-cp39-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.9 Windows x86-64

edgedb-0.13.0-cp39-cp39-manylinux1_x86_64.whl (2.9 MB view details)

Uploaded CPython 3.9

edgedb-0.13.0-cp39-cp39-macosx_10_14_x86_64.whl (1.3 MB view details)

Uploaded CPython 3.9 macOS 10.14+ x86-64

edgedb-0.13.0-cp38-cp38-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.8 Windows x86-64

edgedb-0.13.0-cp38-cp38-manylinux1_x86_64.whl (3.0 MB view details)

Uploaded CPython 3.8

edgedb-0.13.0-cp38-cp38-macosx_10_14_x86_64.whl (1.3 MB view details)

Uploaded CPython 3.8 macOS 10.14+ x86-64

edgedb-0.13.0-cp37-cp37m-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.7m Windows x86-64

edgedb-0.13.0-cp37-cp37m-manylinux1_x86_64.whl (2.9 MB view details)

Uploaded CPython 3.7m

edgedb-0.13.0-cp37-cp37m-macosx_10_14_x86_64.whl (1.3 MB view details)

Uploaded CPython 3.7m macOS 10.14+ x86-64

edgedb-0.13.0-cp36-cp36m-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.6m Windows x86-64

edgedb-0.13.0-cp36-cp36m-manylinux1_x86_64.whl (2.9 MB view details)

Uploaded CPython 3.6m

edgedb-0.13.0-cp36-cp36m-macosx_10_14_x86_64.whl (1.3 MB view details)

Uploaded CPython 3.6m macOS 10.14+ x86-64

File details

Details for the file edgedb-0.13.0.tar.gz.

File metadata

  • Download URL: edgedb-0.13.0.tar.gz
  • Upload date:
  • Size: 776.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0.tar.gz
Algorithm Hash digest
SHA256 196b3b84b49e64c0460e48ad52f0fe313ebf5c9948fca8a54b41c7b32f42202e
MD5 6740dde86e7384b51a5a0b79170584f6
BLAKE2b-256 f1681fc3dadb573c9052dc06fa64f70eb55c24065d377d97ddca3fcb167fd194

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 1.2 MB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 838dde9b3c6a82ca037fa8b2114c5bf186bf5f472870ba46b7cc3474fb0aae86
MD5 05035a292cde999543329e2fa862acd9
BLAKE2b-256 2af380c2a1690bf1831997bf448789f7bd157a8deb17c2a24762049346af82ad

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp39-cp39-manylinux1_x86_64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp39-cp39-manylinux1_x86_64.whl
  • Upload date:
  • Size: 2.9 MB
  • Tags: CPython 3.9
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp39-cp39-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 13d8c2e36218433ce5fa68b382ae6b3e81e9dceefeab55cbaed48ec731680a30
MD5 41a4d466dc02c8861b44aea66d34d884
BLAKE2b-256 72dc7123eb91b8434bd2f7e70923d46723a9e6963316c6f5a28b9b1cf565ad83

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp39-cp39-macosx_10_14_x86_64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp39-cp39-macosx_10_14_x86_64.whl
  • Upload date:
  • Size: 1.3 MB
  • Tags: CPython 3.9, macOS 10.14+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp39-cp39-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 4a12ff1ce71854a64d6abc9fec93cf02aa0b70877c76f3785caec841f3d34066
MD5 33df71f230cde9eec383fdfef769e455
BLAKE2b-256 dc36e76696df02af56569e7ba87ba4e19082f1392baff5ebb48e602fca50f152

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: edgedb-0.13.0-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.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 9d81a20cc3c01c9a6cbc29a0f96b0dd7ae2d4b1a4ddb01962e2217102e6d4042
MD5 b466e3512001fdead8579fca7cc45c4b
BLAKE2b-256 75d88a95d308f5983cdbd50efa266cddc0390722e935e52f1efbe0056747908c

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp38-cp38-manylinux1_x86_64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp38-cp38-manylinux1_x86_64.whl
  • Upload date:
  • Size: 3.0 MB
  • Tags: CPython 3.8
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp38-cp38-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 3bd8479bf7231aefb07ba3ca67de3859f3e80d31a33ceee292a60fbb88fd3aa1
MD5 9d14e18bdbb35c00f27d7215fa56a74b
BLAKE2b-256 dbcc1c0a69b958f60d2775a3b07e1b2fd814ebc5d38e40db6078bba854aed4e2

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp38-cp38-macosx_10_14_x86_64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp38-cp38-macosx_10_14_x86_64.whl
  • Upload date:
  • Size: 1.3 MB
  • Tags: CPython 3.8, macOS 10.14+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp38-cp38-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 b719baf7e2e6073baed4858a74cd54382f72c6ff8bc5ba2ad7a2f30a2aadc5ea
MD5 5c9e5718b439bee06a8e1f3c65e02de1
BLAKE2b-256 737988e4c7d2d0176c561c2c4c221cadba310cbd04adb4ea6af8d52e27b89c28

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 1.2 MB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 409df89f5c6ea46e0298111aeaa4d0e7170d45d0b897e7feaaaba3ffb13dacbd
MD5 def2dd33300312e1af9c160f6bb5c1fd
BLAKE2b-256 956cfbb89ae7eea792b33f0019be0d7411ee2d68193619c21eb80015a3c0d803

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp37-cp37m-manylinux1_x86_64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp37-cp37m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 2.9 MB
  • Tags: CPython 3.7m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp37-cp37m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 b3709092363412b4935e58537f104ae9c164a8adf377fa01a3321a3d18929c40
MD5 01ee48435ededa10d513e4eb516bff31
BLAKE2b-256 af0ae8317b1159b1f0aeb34d00ffd5e01070bacae48e9e178a877825c161168b

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp37-cp37m-macosx_10_14_x86_64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp37-cp37m-macosx_10_14_x86_64.whl
  • Upload date:
  • Size: 1.3 MB
  • Tags: CPython 3.7m, macOS 10.14+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp37-cp37m-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 83d8e8d21591b15f5c9834204ba9a39e053951d029ec49f3804a0eedf08e330d
MD5 1160686362fa1af76168ea6b565abbca
BLAKE2b-256 dd265ded7e9807ed69b69d75d908f20658970e0198f32164c5da2493b6e777c7

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 1.2 MB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 97991857d80ddb0ebf1d3674b57995cd7315f098828591dbe6d87484211b9568
MD5 39aa913dd80317453fdbb927d9883f0c
BLAKE2b-256 307a2e163ff31f7094857eea8a436ffd34a0a8fa83cdbbfa45ff72ecb608d1eb

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp36-cp36m-manylinux1_x86_64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp36-cp36m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 2.9 MB
  • Tags: CPython 3.6m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp36-cp36m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 fff57d2700ff28e5c9733e1c9a779584fde43ab3d67ce9620ac48d5b866c6f1d
MD5 09219f90e332c005cf951c73dfdc26bb
BLAKE2b-256 6cea60c2381d172644c627823aeae5431b49b9a142db98eb9ecf125d58a1fefc

See more details on using hashes here.

File details

Details for the file edgedb-0.13.0-cp36-cp36m-macosx_10_14_x86_64.whl.

File metadata

  • Download URL: edgedb-0.13.0-cp36-cp36m-macosx_10_14_x86_64.whl
  • Upload date:
  • Size: 1.3 MB
  • Tags: CPython 3.6m, macOS 10.14+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

File hashes

Hashes for edgedb-0.13.0-cp36-cp36m-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 a48c63757cac1227e469a1f102d171472218e4f6bdf1ef1006bbab5a0a6ea5b1
MD5 6b89ddc27aeb3c5980bb94cad5f5d1bd
BLAKE2b-256 e75d023c34349ae20aeca1d8396530b407ceb626185223f5ee0d91d5e86bb7fe

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page