dbos-inc / dbos-transact-py

Ultra-Lightweight Durable Execution in Python
https://docs.dbos.dev
MIT License
244 stars 7 forks source link

Move from psycopg2 -> psycopg3 #98

Closed devhawk closed 1 month ago

devhawk commented 1 month ago

This PR moves our PG driver from psycopg2 to psycopg3. We are changing this because psycopg3 supports asyncio while psycopg2 does not.

Generally, the changes consisted of:

Assorted other changes

qianl15 commented 1 month ago

I updated the dependency to psycopg[c] instead of the binary one. https://www.psycopg.org/psycopg3/docs/basic/install.html#binary-installation

The reason is that there's no available binary for my laptop (macOS, M2 chip), which may affect our users as well.

Binary packages are produced on a best-effort basis; the supported platforms depend on the CI runners available to build the packages.