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.7 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():
    client = edgedb.create_client()
    # Create a User object type
    client.execute('''
        CREATE TYPE User {
            CREATE REQUIRED PROPERTY name -> str;
            CREATE PROPERTY dob -> cal::local_date;
        }
    ''')

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

    # Select User objects.
    user_set = client.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 client.
    client.close()

if __name__ == '__main__':
    main()

Development

Instructions for installing EdgeDB and edgedb-python locally can be found at edgedb.com/docs/reference/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-1.2.0.tar.gz (920.6 kB view details)

Uploaded Source

Built Distributions

edgedb-1.2.0-cp310-cp310-win_amd64.whl (1.4 MB view details)

Uploaded CPython 3.10 Windows x86-64

edgedb-1.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.8 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

edgedb-1.2.0-cp310-cp310-macosx_10_9_x86_64.whl (1.5 MB view details)

Uploaded CPython 3.10 macOS 10.9+ x86-64

edgedb-1.2.0-cp39-cp39-win_amd64.whl (1.4 MB view details)

Uploaded CPython 3.9 Windows x86-64

edgedb-1.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.9 MB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

edgedb-1.2.0-cp39-cp39-macosx_10_9_x86_64.whl (1.5 MB view details)

Uploaded CPython 3.9 macOS 10.9+ x86-64

edgedb-1.2.0-cp38-cp38-win_amd64.whl (1.4 MB view details)

Uploaded CPython 3.8 Windows x86-64

edgedb-1.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.2 MB view details)

Uploaded CPython 3.8 manylinux: glibc 2.17+ x86-64

edgedb-1.2.0-cp38-cp38-macosx_10_9_x86_64.whl (1.5 MB view details)

Uploaded CPython 3.8 macOS 10.9+ x86-64

edgedb-1.2.0-cp37-cp37m-win_amd64.whl (1.4 MB view details)

Uploaded CPython 3.7m Windows x86-64

edgedb-1.2.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.8 MB view details)

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

edgedb-1.2.0-cp37-cp37m-macosx_10_9_x86_64.whl (1.5 MB view details)

Uploaded CPython 3.7m macOS 10.9+ x86-64

File details

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

File metadata

  • Download URL: edgedb-1.2.0.tar.gz
  • Upload date:
  • Size: 920.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for edgedb-1.2.0.tar.gz
Algorithm Hash digest
SHA256 ee0e68adbb50285db1273ec9ecf45b38ef904a6d06cf78202c83403561142a5d
MD5 e1b6bc31eb8abc665f0445f6662aa735
BLAKE2b-256 50d96a356c714bc7916e7cdf2e86d6d86437a78b8161646463adf0d02c7ee735

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: edgedb-1.2.0-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for edgedb-1.2.0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 dac1084fd87815218fe7a493124ce6c58d02cf874a323017773c216d0c6a8942
MD5 3c6dea6285aef4692d6d48d222c0c0a6
BLAKE2b-256 6e44b20990b321fdcfec2509f9a621cd0fa224f13ba608ae25bb15fac77af141

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-1.2.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 7d275bd636f01732c7dd155cd3aa7c4d04b3d5d6e7c99cc32c8ef7be7b73e761
MD5 9403b13f86c11e5732fa322ae0584c2e
BLAKE2b-256 7347726a0bd6139166359b4f895e8908375cab21f65eb92d0ab90c58e4352a9b

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp310-cp310-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-1.2.0-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 a3dbdee7a109a67050f9b4eb0c96908714f01e68e4ac0c9494d2dca755c3c66a
MD5 3555e3b6d136ebe429ba89a1d3d6420b
BLAKE2b-256 feed1d4afcb1cdf8bb30a3bfaf1acb9cd971c0604b740d2bc4b2645ab8e65fcf

See more details on using hashes here.

File details

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

File metadata

  • Download URL: edgedb-1.2.0-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for edgedb-1.2.0-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 111ca83fbbda4e2364333979be1879ad92e754ffaa192bf01533c5160ec34308
MD5 4465381cea7cabb4cbcb46748e949b6e
BLAKE2b-256 dca1745e9fe081caff9f81f1180dc2aed71c153c287c4f0436a080e1e5a619c7

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-1.2.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 df9969911c7bdf64db071e7b36b075054fc6659ea2fcfdabc9d785d368485d2e
MD5 fcc5fa7250f19a35979b6893af0de91f
BLAKE2b-256 7ad1544695671e8f3600af347e26186f022bd23bf19d4b3e7b5cc1a7145b1342

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp39-cp39-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-1.2.0-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 93df4ad23482e1785c5c234840d91cf41564743d5596e41886ee2ece8d8d78c3
MD5 cf2657fa7eb8f33d105f4b16290b7ea8
BLAKE2b-256 849f8454e303f8e280b35355cf1697f302b4bc9d148c87cb5459e7e76bc7ce8f

See more details on using hashes here.

File details

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

File metadata

  • Download URL: edgedb-1.2.0-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for edgedb-1.2.0-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 a04397b0fd157728cbe06ecdaf0dc287e1da8557c32c32baa867d2b4825e9f58
MD5 b7271ab9529978555fe5ed7a3e0cc6a8
BLAKE2b-256 fa3ede87e3b142ef5d6901288338c9f957077e9c4c17188349d1200111be9fd8

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-1.2.0-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3003f455020493fee466e5430f90d30e7e4b02395748bc2b7cccac7b51d831ae
MD5 5ce91813f4f31761ca6c64e7cb103a1f
BLAKE2b-256 daeb87b9580541922c28dc9cf36988c8f79a82bb6f1a193572e2b01a06130a42

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp38-cp38-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-1.2.0-cp38-cp38-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 ab283ec9b7ed3c99c15231925124616d327b3e21e20538271677435ad14c96dd
MD5 2520d681a0964ab8729a87e42fc4dbe4
BLAKE2b-256 02075b2581e37adcfb7eefb3499a3103c997eb2abc67d243240a1369ed8ec951

See more details on using hashes here.

File details

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

File metadata

  • Download URL: edgedb-1.2.0-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for edgedb-1.2.0-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 69ff6127ff2fd671631c4dd38bff3b64bdd69231084729eabd95187ccf194eb8
MD5 3d30826a91823e12328d36f029397332
BLAKE2b-256 89935bdfbb11836738849feb3468da02be883442e013701c0f604de55758b9b6

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-1.2.0-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3d69cda325e86ace45b62b6047e2e38131db4462fecd6298f96c1fe551b19430
MD5 b566cee29e9e3be47ad814977a1962ce
BLAKE2b-256 769d66c8f2d973dfe81bc38bdd65b8ada00cd22fb8a054df432b6bc504753e3b

See more details on using hashes here.

File details

Details for the file edgedb-1.2.0-cp37-cp37m-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for edgedb-1.2.0-cp37-cp37m-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 421d24f50333ddf52b344f7e3ab65b62fda5f551f5671328c8dbba269d41e03e
MD5 9e5a31cfd0ef01daf0bd80986d7903e0
BLAKE2b-256 70d01ef8ad061ec97c6c5819c3854429ab0751655cdfa6ffc58e3eeeb3f12818

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