All Projects → psycopg → Psycopg3

psycopg / Psycopg3

Licence: lgpl-3.0
New generation PostgreSQL database adapter for the Python programming language

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Psycopg3

Takeoff
A rapid development environment using docker for convenience.
Stars: ✭ 271 (-2.52%)
Mutual labels:  database, postgresql, development
Postgres
Postgres.js - The Fastest full featured PostgreSQL client for Node.js
Stars: ✭ 2,193 (+688.85%)
Mutual labels:  database, postgresql, driver
Hasql
Performant PostgreSQL driver with a flexible mapping API
Stars: ✭ 415 (+49.28%)
Mutual labels:  database, postgresql, driver
Psycopg2
PostgreSQL database adapter for the Python programming language
Stars: ✭ 2,425 (+772.3%)
Mutual labels:  database, postgresql, driver
Massive Js
A data mapper for Node.js and PostgreSQL.
Stars: ✭ 2,521 (+806.83%)
Mutual labels:  database, postgresql
Dbq
Zero boilerplate database operations for Go
Stars: ✭ 273 (-1.8%)
Mutual labels:  database, postgresql
Prest
PostgreSQL ➕ REST, low-code, simplify and accelerate development, ⚡ instant, realtime, high-performance on any Postgres application, existing or new
Stars: ✭ 3,023 (+987.41%)
Mutual labels:  database, postgresql
Pg chameleon
MySQL to PostgreSQL replica system
Stars: ✭ 274 (-1.44%)
Mutual labels:  database, postgresql
Temboard
PostgreSQL Remote Control
Stars: ✭ 218 (-21.58%)
Mutual labels:  database, postgresql
Neo4j Java Driver
Neo4j Bolt driver for Java
Stars: ✭ 241 (-13.31%)
Mutual labels:  database, driver
Sqlfiddle3
New version based on vert.x and docker
Stars: ✭ 242 (-12.95%)
Mutual labels:  database, postgresql
Scany
Library for scanning data from a database into Go structs and more
Stars: ✭ 228 (-17.99%)
Mutual labels:  database, postgresql
Db
Data access layer for PostgreSQL, CockroachDB, MySQL, SQLite and MongoDB with ORM-like features.
Stars: ✭ 2,832 (+918.71%)
Mutual labels:  database, postgresql
Django Migration Linter
🚀 Detect backward incompatible migrations for your django project
Stars: ✭ 231 (-16.91%)
Mutual labels:  database, postgresql
Piccolo
A fast, user friendly ORM and query builder which supports asyncio.
Stars: ✭ 219 (-21.22%)
Mutual labels:  database, postgresql
Gorm Bulk Insert
implement BulkInsert using gorm, just pass a Slice of Struct. Simple and compatible.
Stars: ✭ 241 (-13.31%)
Mutual labels:  database, postgresql
Mikro Orm
TypeScript ORM for Node.js based on Data Mapper, Unit of Work and Identity Map patterns. Supports MongoDB, MySQL, MariaDB, PostgreSQL and SQLite databases.
Stars: ✭ 3,874 (+1293.53%)
Mutual labels:  database, postgresql
Php Crud Api
Single file PHP script that adds a REST API to a SQL database
Stars: ✭ 2,904 (+944.6%)
Mutual labels:  database, postgresql
Migrations
SQL database migrations for Golang go-pg and PostgreSQL
Stars: ✭ 251 (-9.71%)
Mutual labels:  database, postgresql
3dcitydb
3D City Database - The Open Source CityGML Database
Stars: ✭ 210 (-24.46%)
Mutual labels:  database, postgresql

psycopg3 -- PostgreSQL database adapter for Python

psycopg3 is a modern implementation of a PostgreSQL adapter for Python.

Installation

The library is still in a development stage and is not available on PyPI in the form of packages yet. You can install it directly from the GitHub project__::

$ pip install git+https://github.com/psycopg/psycopg3.git#subdirectory=psycopg3
$ python3
>>> import psycopg3

.. __: https://github.com/psycopg/psycopg3

You are required to have the libpq, the PostgreSQL client library, already installed in the system before using psycopg3. On Debian system you can obtain it by running::

sudo apt-get install libpq5

Please check your system's documentation for information about installing the libpq on your platform.

Hacking

In order to work on the psycopg3 source code you should clone this repository::

git clone https://github.com/psycopg/psycopg3.git
cd psycopg3

Please note that the repository contains the source code of several Python packages: that's why you don't see a setup.py here. The packages may have different requirements:

  • The psycopg3 directory contains the pure python implementation of psycopg3. The package has only a runtime dependency on the libpq, the PostgreSQL client library, which should have been already installed in your system.

  • The psycopg3_c directory contains an optimization module written in C/Cython. In order to build it you will need a few development tools: please look at Local installation__ in the docs for the details.

    .. __: https://www.psycopg.org/psycopg3/docs/install.html#local-installation

You can create a local virtualenv and install there the packages in development mode__, together with their development and testing requirements::

python -m venv .venv
source .venv/bin/activate
pip install -e ./psycopg3[dev,test]     # for the base Python package
pip install -e ./psycopg3_c             # for the C extension module

.. __: https://pip.pypa.io/en/stable/reference/pip_install/#install-editable

Now hack away! You can use tox to validate the code::

pip install tox
tox -p4

and to run the tests::

psql -c 'create database psycopg3_test'
export PSYCOPG3_TEST_DSN="dbname=psycopg3_test"
tox -c psycopg3 -s
tox -c psycopg3_c -s

Please look at the commands definitions in the tox.ini files if you want to run some of them interactively: the dependency should be already in your virtualenv. Feel free to adapt these recipes if you follow a different development pattern.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].