Hacker News new | ask | show | jobs
by jsmeaton 748 days ago
It doesn’t work with psycopg or many other libraries that use c extensions. That’s the main reason.
2 comments

Only because they were compiled against cpython and not pypy right? If pypy had taken off/over, wouldn't it have been the other way around, where you need to do a special compile any time you want to use a C project with cpython rather than using the prebuilt pypy-compatible version?

Edit: things seem to have changed since I last looked into compiling a dependency for pypy. https://doc.pypy.org/en/latest/faq.html#do-c-extension-modul... now says they support c-extension modules without modifications

The package you mentioned, some postgres thing apparently, mentions they support pypy 3.9 and 3.10: https://www.psycopg.org/psycopg3/docs/basic/install.html

By “some postgres thing”, you mean…pretty much the only way that one would connect to Postgres in Python!
Right, I just wasn't familiar with it (never heard this name before) and the only association I could think of for this abbreviated name was psyops and cops. Turns out it's actually for postgres which, of course, is a name I very well know. Didn't realize it was a well-known library!
Oh, I'd thought some significant effort had gone into emulating the CPython C extension interface.

But maybe even with that, it's unable to support some extensions?