{"id":21170055,"url":"https://github.com/covenantsql/cql-python-driver","last_synced_at":"2025-07-06T17:02:58.372Z","repository":{"id":57756206,"uuid":"149561458","full_name":"CovenantSQL/cql-python-driver","owner":"CovenantSQL","description":"Python driver for CovenantSQL","archived":false,"fork":false,"pushed_at":"2022-08-26T04:10:26.000Z","size":60,"stargazers_count":7,"open_issues_count":1,"forks_count":6,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-05T06:03:53.952Z","etag":null,"topics":["covenantsql","cql","python","python3","sql"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CovenantSQL.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-20T06:22:39.000Z","updated_at":"2024-01-19T10:25:44.000Z","dependencies_parsed_at":"2022-08-23T19:10:41.755Z","dependency_job_id":null,"html_url":"https://github.com/CovenantSQL/cql-python-driver","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/CovenantSQL/cql-python-driver","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CovenantSQL%2Fcql-python-driver","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CovenantSQL%2Fcql-python-driver/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CovenantSQL%2Fcql-python-driver/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CovenantSQL%2Fcql-python-driver/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CovenantSQL","download_url":"https://codeload.github.com/CovenantSQL/cql-python-driver/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CovenantSQL%2Fcql-python-driver/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260046165,"owners_count":22950814,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["covenantsql","cql","python","python3","sql"],"created_at":"2024-11-20T15:55:51.485Z","updated_at":"2025-06-15T20:35:00.501Z","avatar_url":"https://github.com/CovenantSQL.png","language":"Python","readme":"PyCovenantSQL\n===============\n\n.. contents:: Table of Contents\n   :local:\n\nThis package contains a pure-Python CovenantSQL client library, based on `PEP 249`_.\n\n\nNOTE: PyCovenantSQL only support high level APIs defined in `PEP 249`_.\n\n.. _`PEP 249`: https://www.python.org/dev/peps/pep-0249/\n\n\nRequirements\n-------------\n\n* Python -- one of the following:\n\n  - CPython_ : 2.7 and \u003e= 3.4\n  - PyPy_ : Latest version\n\n* Packages:\n\n  - Requests_ \u003e= 2.19\n  - Arrow_ \u003e= 0.13\n\n* CovenantSQL Adapter Server:\n\n  - CovenantSQL_ \u003e= 0.0.3\n\n\n.. _CPython: https://www.python.org/\n.. _PyPy: https://pypy.org/\n.. _Requests: http://www.python-requests.org/\n.. _Arrow: https://github.com/crsmithdev/arrow\n.. _CovenantSQL: https://github.com/CovenantSQL/CovenantSQL\n\n\n\nInstallation\n------------\n\nPackage is uploaded on `PyPI \u003chttps://pypi.org/project/PyCovenantSQL\u003e`_.\n\nYou can install it with pip::\n\n    $ python3 -m pip install PyCovenantSQL\n\n\nDocumentation\n-------------\n\nDocumentation is available online: http://developers.covenantsql.io/\n\nKey file and dsn can get from: http://developers.covenantsql.io/docs/quickstart\n\nFor support, please fire a issue at `Github\n\u003chttps://github.com/CovenantSQL/CovenantSQL/issues/new\u003e`_.\n\nExample\n-------\n\nThe following examples make use of a simple table\n\n.. code:: sql\n\n   CREATE TABLE `users` (\n       `id` INTEGER PRIMARY KEY AUTOINCREMENT,\n       `email` varchar(255) NOT NULL,\n       `password` varchar(255) NOT NULL\n   );\n\n\n.. code:: python\n\n    import pycovenantsql\n\n\n    # Connect to the database with dsn\n    # host and port are your local CovenantSQL Adapter server\n    connection = pycovenantsql.connect(\n                                 dsn='covenantsql://your_database_id',\n                                 host='localhost',\n                                 port=11108,\n                                 )\n\n    try:\n        with connection.cursor() as cursor:\n            # Create a new record\n            sql = \"INSERT INTO `users` (`email`, `password`) VALUES (%s, %s)\"\n            cursor.execute(sql, ('webmaster@python.org', 'very-secret'))\n\n        # connection is autocommit. No need to commit in any case.\n        # connection.commit()\n\n        with connection.cursor() as cursor:\n            # Read a single record\n            sql = \"SELECT `id`, `password` FROM `users` WHERE `email`=%s\"\n            cursor.execute(sql, ('webmaster@python.org',))\n            result = cursor.fetchone()\n            print(result)\n    finally:\n        connection.close()\n\nThis example will print:\n\n.. code:: python\n\n    {'password': 'very-secret', 'id': 1}\n\n\nResources\n---------\n\n* DB-API 2.0: http://www.python.org/dev/peps/pep-0249\n\n* CovenantSQL Website: https://covenantsql.io/\n\n* CovenantSQL testnet quick start:\n  https://testnet.covenantsql.io/quickstart\n\n* CovenantSQL source code:\n  https://github.com/CovenantSQL/CovenantSQL\n\n\nLicense\n-------\n\nPyCovenantSQL is released under the Apache 2.0 License. See LICENSE for more information.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcovenantsql%2Fcql-python-driver","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcovenantsql%2Fcql-python-driver","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcovenantsql%2Fcql-python-driver/lists"}