Skip to content

issue with custom data types between schemas on same connection #72

Closed
@defg

Description

@defg
  • asyncpg version: 0.8.4
  • PostgreSQL version: PostgreSQL 9.6.0
  • Python version: Python 3.5.2
  • Platform: Ubuntu 14.04.2 LTS
  • Do you use pgbouncer?: No
  • Do you use the wheel package or built locally
    (if locally, which version of Cython was used)?
    : pypi pip pkg
  • Can you the issue be reproduced when running under
    uvloop?
    : Yes

I'm receiving the exception
"asyncpg.exceptions.FeatureNotSupportedError: cached plan must not change result type"
when I try to use a custom enum type across 2 schemas in the same connection. This happens even when I'm using independent transactions. This behavior doesn't happen when I issue the SQL in postgres directly.

I've written a sample python script along with some SQL to reproduce the issue.

https://gist.github.com/defg/8fd9e97efd1ba5195052a0faa1457dcc

Maybe something is cached w/o regard for the schema?

I'm working around this issue for the time being by making a connection per schema, but it would be much easier in the future if I could access different schemas on the same connection w/o error.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions