async with conn.begin_twophase() as transaction:
AttributeError: __aenter__
2. recover_twophase() is broken
result is not awaited:
File "/Users/ovmikhaylov/work/aiopg/aiopg/sa/connection.py", line 363, in recover_twophase
return [row[0] for row in result]
TypeError: 'ResultProxy' object is not iterable
3. rollback_prepared() is broken
Due to error in f-string:
File "/Users/ovmikhaylov/work/aiopg/aiopg/sa/connection.py", line 368, in rollback_prepared
await self.execute(f"ROLLBACK PREPARED {xid:!r}")
ValueError: Invalid format specifier
Python Version
3.10
aiopg Version
1.3.3
OS
Darwin gmbp.local 20.6.0 Darwin Kernel Version 20.6.0: Tue Oct 12 18:33:42 PDT 2021; root:xnu-7195.141.8~1/RELEASE_X86_64 x86_64
Additional context
No response
Code of Conduct
[X] I agree to follow the aio-libs Code of Conduct
Describe the bug
To Reproduce
just use these methods)
Expected behavior
Logs/tracebacks
1. begin_context() is not a context
According to docs: https://aiopg.readthedocs.io/en/stable/sa.html#aiopg.sa.SAConnection.begin_twophase
but in reality:
2. recover_twophase() is broken
result is not awaited:
3. rollback_prepared() is broken
Due to error in f-string:
Python Version
aiopg Version
OS
Darwin gmbp.local 20.6.0 Darwin Kernel Version 20.6.0: Tue Oct 12 18:33:42 PDT 2021; root:xnu-7195.141.8~1/RELEASE_X86_64 x86_64
Additional context
No response
Code of Conduct