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.18.0a1.tar.gz (799.1 kB view details)

Uploaded Source

Built Distributions

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

Uploaded CPython 3.9 Windows x86-64

edgedb-0.18.0a1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl (2.9 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.5+ x86-64

edgedb-0.18.0a1-cp39-cp39-macosx_10_14_x86_64.whl (1.4 MB view details)

Uploaded CPython 3.9 macOS 10.14+ x86-64

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

Uploaded CPython 3.8 Windows x86-64

edgedb-0.18.0a1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl (3.1 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.5+ x86-64

edgedb-0.18.0a1-cp38-cp38-macosx_10_14_x86_64.whl (1.4 MB view details)

Uploaded CPython 3.8 macOS 10.14+ x86-64

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

Uploaded CPython 3.7m Windows x86-64

edgedb-0.18.0a1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.whl (2.9 MB view details)

Uploaded CPython 3.7m manylinux: glibc 2.5+ x86-64

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

Uploaded CPython 3.7m macOS 10.14+ x86-64

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

Uploaded CPython 3.6m Windows x86-64

edgedb-0.18.0a1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.whl (2.9 MB view details)

Uploaded CPython 3.6m manylinux: glibc 2.5+ x86-64

edgedb-0.18.0a1-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.18.0a1.tar.gz.

File metadata

  • Download URL: edgedb-0.18.0a1.tar.gz
  • Upload date:
  • Size: 799.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1.tar.gz
Algorithm Hash digest
SHA256 d43f5bfb3825c8be2398d4fced475d69bae1d57c3c4e52b4dd3a1c6468cba6b1
MD5 a3a2e0420378a466637f89459bfe9746
BLAKE2b-256 ac9851977a507b1684a028adad7b18f3079f1af6b536018d365f07b06807f331

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: edgedb-0.18.0a1-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.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 9486eb47674012da9469de440c93400d142bfe2d296183adc0cb90e5d4b4764d
MD5 d7f0a6d18c7a099b70f03bd058d55032
BLAKE2b-256 cfa758920cad1437a94e5be409ec63c99a1351bfb3872be606335d97431061e3

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-0.18.0a1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 7b732b1ce6b1763913b61c5a10ea00c07ddc059a14a7d20367b53c5bc8ac67b3
MD5 ca9809e8bd7d0dcdc4fd58ef22773f49
BLAKE2b-256 3303a8b2efcf91c13d8b698645b00e2060d6620c7372399055e795f16b4c07a3

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp39-cp39-macosx_10_14_x86_64.whl.

File metadata

  • Download URL: edgedb-0.18.0a1-cp39-cp39-macosx_10_14_x86_64.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: CPython 3.9, macOS 10.14+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1-cp39-cp39-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 6e363ec5ba2284dfef53d355cdd74b4245e42993282887547b3ec5555b3ff54b
MD5 0904e6a62c720c2bb63f6a926c1de2dd
BLAKE2b-256 9113b7e82a867915777caa69a556e9968541242cc25042fb7c2c6b69a4193087

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: edgedb-0.18.0a1-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.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 0fb91170dd52bc80192a8da36e2770941b04caa4cc69ff3e81c95e57302dadea
MD5 4e37087c8b06e27fde2b36c25a69cfe1
BLAKE2b-256 39ea5c8678c8b94509af2daa91911953f77277cfe195efe730ef692d6db3a931

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-0.18.0a1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 07c0fae262492763f5803dd1c7ead9fd4dedf2a2f8d85209e761af58731b04be
MD5 5756659823533a4fcb190a802959678b
BLAKE2b-256 cd0c12ab1c1e9da77fe7a965552bb444c797d81bd88eb955cb432963b8a4f31f

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp38-cp38-macosx_10_14_x86_64.whl.

File metadata

  • Download URL: edgedb-0.18.0a1-cp38-cp38-macosx_10_14_x86_64.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: CPython 3.8, macOS 10.14+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1-cp38-cp38-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 fcae3f598b0dbc5334cfcdd45c079ade50182a048a14882f92ebd502f3b9cf31
MD5 04e5caf0b2fce0968ab76c4460615ad5
BLAKE2b-256 5a7e56d5b54fb52188f7c58e1fc73e88360d68443daa5b9163ac483e8229175a

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: edgedb-0.18.0a1-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.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 e58664f7a57e41fafe316f1a8582038a7b9351ecbad204e6d6d5b6e45ab2142c
MD5 edd279d8b9f9ceedb5b768a66010cd59
BLAKE2b-256 4974e5b0101c708d3a315fd8527236ae2d2fa97a6ca594cc1e5e729749458d58

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-0.18.0a1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 c1b01babdfaaff24927ee4b9a16a9f8bbe6a6a3ffdb2562346475da5d5444106
MD5 accbfa160997e893a701eb01360b5318
BLAKE2b-256 d2c213eb51a9bea60a6d4709da945ad6f782201db79aa21563b98627512c5328

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp37-cp37m-macosx_10_14_x86_64.whl.

File metadata

  • Download URL: edgedb-0.18.0a1-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.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1-cp37-cp37m-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 dd589b9a4a9a40c470ecf1b8e1d5c71581a41403f7aa5a7990bba652594e456b
MD5 a1a9886c4cd9329625dc543dffe1306a
BLAKE2b-256 0ed4ae76a4fdacf6dae9f96d197d4e54c7c42480b446be70752cf9296602dc52

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: edgedb-0.18.0a1-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.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 19ea7172f536a102bd81aa89bd886b1598cc32046ff4cd691fdea2b576a81252
MD5 364cfa83a40903f1ffd5646f8fa67977
BLAKE2b-256 9fd384bfa63910e530fb72fa93382406f05dc9ab5fc251ad2958b01a7eebdf9f

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-0.18.0a1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 1f5fd6223cf3101f4f0edd2178d88d339c227f6a329a6fa0cf5477391bdcf459
MD5 5091fd80bb0f17a795cdd9ef3c2b9cd0
BLAKE2b-256 e736cc61c396a17866ee12789884c9d1af5f33fcc1e2abc45e9a223ccc7ae27c

See more details on using hashes here.

File details

Details for the file edgedb-0.18.0a1-cp36-cp36m-macosx_10_14_x86_64.whl.

File metadata

  • Download URL: edgedb-0.18.0a1-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.4.2 importlib_metadata/4.7.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.6

File hashes

Hashes for edgedb-0.18.0a1-cp36-cp36m-macosx_10_14_x86_64.whl
Algorithm Hash digest
SHA256 679e1feaa13c8ba9bb39f98aaff8ba2e0cd4f7f5f3f47cc9487ee98167c361c8
MD5 3d7848da7dd9ea685f2685b71f4c4595
BLAKE2b-256 f9dde39c35892dad1c52bddc4a8cd871ec5cead10957e768f63abfdb94642d84

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