News for hackers. Stuff that matters.
Re:Pg8000 – Pure-Python PostgreSQL driver by bencollier49 on Friday May 14, 2021 @03:45AM (#27151808)
Delighted to see this. Installation of psycopg2 can be a nuisance thanks to the native compilation steps which don't always work as planned and rely on specific versions of libssl.
Re:Pg8000 – Pure-Python PostgreSQL driver by bogcotton on Friday May 14, 2021 @08:27AM (#27153473)
After suffering with this myself, I started using the psycopg2-binary package exclusively: https://pypi.org/project/psycopg2-binary/

Haven't had any issues since!

Re:Pg8000 – Pure-Python PostgreSQL driver by gjvc on Friday May 14, 2021 @10:57AM (#27154976)
good to hear, but beware what it says in the last paragraph here https://pypi.org/project/psycopg2/ ...

"The binary package is a practical choice for development and testing but in production it is advised to use the package built from sources."

...or use one from your operating system distribution.

Re:Pg8000 – Pure-Python PostgreSQL driver by SonOfLilit on Friday May 14, 2021 @11:17AM (#27155169)
To all those wondering _why_ that is the recommendation, I did some digging and the answer is "the binary package is compiled against one version of libssl, and if your system happens to use a different one, in some weird edge cases it will lead to a segfault"
Re:Pg8000 – Pure-Python PostgreSQL driver by sirsinsalot on Friday May 14, 2021 @11:45AM (#27155484)
Odd then that Digital Ocean's App Platform for Django deployment requires the binary version in your requirements file.
Re:Pg8000 – Pure-Python PostgreSQL driver by gjvc on Friday May 14, 2021 @04:14AM (#27151965)
exactly my motivation for ferreting it out and it's worked great for the simple scenarios. the only thing i'm missing is a .mogrify() function.

this guy has put one together though; might see if we can get it migrated into the original version.

https://github.com/realazthat/aiopg8000/blob/master/aiopg800...