Skip to content
This repository was archived by the owner on Aug 19, 2025. It is now read-only.

Replace psycopg2-binary with psycopg2 (#198)#204

Merged
lovelydinosaur merged 1 commit intoencode:masterfrom
retnikt:patch-1
May 1, 2020
Merged

Replace psycopg2-binary with psycopg2 (#198)#204
lovelydinosaur merged 1 commit intoencode:masterfrom
retnikt:patch-1

Conversation

@retnikt
Copy link
Copy Markdown
Contributor

@retnikt retnikt commented May 1, 2020

No description provided.

Copy link
Copy Markdown
Contributor

@lovelydinosaur lovelydinosaur left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, thanks.

@lovelydinosaur lovelydinosaur merged commit a411e44 into encode:master May 1, 2020
@retnikt retnikt deleted the patch-1 branch May 1, 2020 08:24
@JayH5
Copy link
Copy Markdown

JayH5 commented May 1, 2020

Just a drive-by comment that this change probably needs a bit of a warning in the changelog as the psycopg2 package requires build tools, libpq, etc, whereas before the psycopg2-binary package did not.

@lovelydinosaur
Copy link
Copy Markdown
Contributor

Okay, which makes me want to re-evaluate what benefit this change would give us.

@retnikt
Copy link
Copy Markdown
Contributor Author

retnikt commented May 1, 2020

Well, really I think users should have the choice between the binary or non-binary version depending on their circumstances. The only option for this I believe would be to remove the requirement entirely and tell users in the docs that one of them is required for table creation/migrations. This also allows the flexibility of running your migrations entirely separately from your web server.

@lovelydinosaur
Copy link
Copy Markdown
Contributor

Then let's drop psycopg2 and pymysql entirely, and make sure that the next version is a proper version bump, and calls out the requirement to install a sync driver if you're using alembic or SQL Alchemy's engine.create_all()

retnikt added a commit to retnikt/databases that referenced this pull request May 1, 2020
retnikt added a commit to retnikt/databases that referenced this pull request May 1, 2020
vmarkovtsev added a commit to vmarkovtsev/databases that referenced this pull request Oct 19, 2020
Changelog:

- Use backend native fetch_val() implementation when available (encode#132)
- Replace psycopg2-binary with psycopg2 (encode#198) (encode#204)
- Speed up PostgresConnection fetch() and iterate() (encode#193)
- Access asyncpg Record field by key on raw query (encode#207)
- Fix type hinting for sqlite backend (encode#227)
- Allow setting min_size and max_size in postgres DSN (encode#210)
- Add option pool_recycle in postgres DSN (encode#233)
- Fix SQLAlchemy DDL statements (encode#226)
- Make fetch_val call fetch_one for type conversion (encode#246)
- Allow extra transaction options (encode#242)
- Unquote username and password in DatabaseURL (encode#248)
vmarkovtsev added a commit to vmarkovtsev/databases that referenced this pull request Oct 19, 2020
Changelog:

- Use backend native fetch_val() implementation when available (encode#132)
- Replace psycopg2-binary with psycopg2 (encode#198) (encode#204)
- Speed up PostgresConnection fetch() and iterate() (encode#193)
- Access asyncpg Record field by key on raw query (encode#207)
- Fix type hinting for sqlite backend (encode#227)
- Allow setting min_size and max_size in postgres DSN (encode#210)
- Add option pool_recycle in postgres DSN (encode#233)
- Fix SQLAlchemy DDL statements (encode#226)
- Make fetch_val call fetch_one for type conversion (encode#246)
- Allow extra transaction options (encode#242)
- Unquote username and password in DatabaseURL (encode#248)
@vmarkovtsev vmarkovtsev mentioned this pull request Oct 19, 2020
vmarkovtsev added a commit to vmarkovtsev/databases that referenced this pull request Oct 20, 2020
Changelog:

- Use backend native fetch_val() implementation when available (encode#132)
- Replace psycopg2-binary with psycopg2 (encode#198) (encode#204)
- Speed up PostgresConnection fetch() and iterate() (encode#193)
- Access asyncpg Record field by key on raw query (encode#207)
- Fix type hinting for sqlite backend (encode#227)
- Allow setting min_size and max_size in postgres DSN (encode#210)
- Add option pool_recycle in postgres DSN (encode#233)
- Fix SQLAlchemy DDL statements (encode#226)
- Make fetch_val call fetch_one for type conversion (encode#246)
- Allow extra transaction options (encode#242)
- Unquote username and password in DatabaseURL (encode#248)
vmarkovtsev added a commit to vmarkovtsev/databases that referenced this pull request Oct 20, 2020
Changelog:

- Use backend native fetch_val() implementation when available (encode#132)
- Replace psycopg2-binary with psycopg2 (encode#198) (encode#204)
- Speed up PostgresConnection fetch() and iterate() (encode#193)
- Access asyncpg Record field by key on raw query (encode#207)
- Fix type hinting for sqlite backend (encode#227)
- Allow setting min_size and max_size in postgres DSN (encode#210)
- Add option pool_recycle in postgres DSN (encode#233)
- Fix SQLAlchemy DDL statements (encode#226)
- Make fetch_val call fetch_one for type conversion (encode#246)
- Allow extra transaction options (encode#242)
- Unquote username and password in DatabaseURL (encode#248)
vmarkovtsev added a commit that referenced this pull request Oct 20, 2020
Changelog:

- Use backend native fetch_val() implementation when available (#132)
- Replace psycopg2-binary with psycopg2 (#198) (#204)
- Speed up PostgresConnection fetch() and iterate() (#193)
- Access asyncpg Record field by key on raw query (#207)
- Fix type hinting for sqlite backend (#227)
- Allow setting min_size and max_size in postgres DSN (#210)
- Add option pool_recycle in postgres DSN (#233)
- Fix SQLAlchemy DDL statements (#226)
- Make fetch_val call fetch_one for type conversion (#246)
- Allow extra transaction options (#242)
- Unquote username and password in DatabaseURL (#248)
@vmarkovtsev
Copy link
Copy Markdown
Contributor

Here I am, the one who released 0.4.0 and broke my own production builds because of this 😓

So shall I remove these requirements completely then?

vmarkovtsev added a commit to vmarkovtsev/databases that referenced this pull request Oct 21, 2020
vmarkovtsev added a commit to vmarkovtsev/databases that referenced this pull request Oct 21, 2020
vmarkovtsev added a commit to vmarkovtsev/databases that referenced this pull request Oct 21, 2020
vmarkovtsev added a commit that referenced this pull request Nov 16, 2020
niurkacanals added a commit to niurkacanals/databases-sql-expert that referenced this pull request Sep 2, 2022
dudleyhunt86 added a commit to dudleyhunt86/database-Django that referenced this pull request Oct 7, 2022
adamharris1219 added a commit to adamharris1219/database-Scripts that referenced this pull request Nov 24, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants