You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm one of the developers behind psqlpy. We've created a third-party library, which you can check out here. However, we've encountered a small problem that makes the integration nearly impossible without your assistance.
The issue lies within the _process_results method, where some unwrapping is performed. Asyncpg returns a Record object, but psqlpy does not. Instead, it behaves more like SQLite in this context, returning a list of dictionaries. Therefore, we don't need this unwrapping. Unfortunately, there is no appropriate engine type for our use case. We cannot use the SQLite engine type for obvious reasons.
Would it be possible to add a psqlpy-postgres type, so we can eliminate this Record object unwrapping?
Additionally, this change needs to be reflected in the Query class within the querystrings property. There might be other places affected, but these are what I identified during my reverse engineering.
Originally posted by @insani7y in #986 (comment)
As outlined above, there's a bit of code where we transform the response from the database into a list of dicts:
piccolo/piccolo/query/base.py
Lines 51 to 56 in e7b13fb
It assumes that Postgres engines will just be
asyncpg
based, which is no longer the case.We should move this logic to the
Engine
class.The text was updated successfully, but these errors were encountered: