opbeat_python
opbeat_python copied to clipboard
Postgres instrumentation is incomplete
The instrumentation is not covering the psycopg2 extensions API.
In order to reproduce this, try calling psycopg2.extensions.ISQLQuote.prepare() with the wrapped connection object, it will raise a
TypeError
must be psycopg2._psycopg.connection, not PGConnectionProxy
An example of such an use-case is when trying to adapt an iterator in an array column type query. To be specific, peewee is using such an adapter: https://github.com/coleifer/peewee/blob/master/playhouse/postgres_ext.py#L109-L117
Hey @stas! Thanks for this. I'll take a look.