django-pgpubsub icon indicating copy to clipboard operation
django-pgpubsub copied to clipboard

Psycopg3 support

Open NathanSmeltzer opened this issue 1 year ago • 4 comments

Are there plans to support Psycopg 3? I tried installing both psycopg2 and psycopg[c] (Psycopg3) but received this error which seems due to Psycopg 3 not having a poll method for its Connection class:

File "/usr/local/lib/python3.10/site-packages/pgpubsub/listen.py", line 71, in process_notifications
    pg_connection.poll()
AttributeError: 'Connection' object has no attribute 'poll'

Supporting this would clear up some confusion as cookiecutter django now installs Psycopg 3 by default. Libraries like django-debug-toolbar support both versions.

NathanSmeltzer avatar Jul 05 '23 13:07 NathanSmeltzer