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
Describe the bug
I use Tortoise ORM with FastAPI contrib and MySQL database. There are some places in my code where I use toirtoise.transactions.in_transaction and it causes this error sometimes:
AssertionError: (<aiomysql.connection.Connection object at 0x7ec4f3382120>, {<aiomysql.connection.Connection object at 0x7ec4f3d648f0>, <aiomysql.connection.Connection object at 0x7ec4f3d20530>, <aiomysql.connection.Connection object at 0x7ec4f3367b30>, <aiomysql.connection.Connection object at 0x7ec4f3364770>, <aiomysql.connection.Connection object at 0x7ec4f3d22ba0>})
I use multiple gunicorn workers and all of them having this issue simultaneously. Issue repeats several times an hour.
To Reproduce
Create FastAPI application with registered Tortoise:
Describe the bug
I use Tortoise ORM with FastAPI contrib and MySQL database. There are some places in my code where I use
toirtoise.transactions.in_transaction
and it causes this error sometimes:I use multiple gunicorn workers and all of them having this issue simultaneously. Issue repeats several times an hour.
To Reproduce
Create FastAPI application with registered Tortoise:
Add transaction somewhere in your routes:
And MySQL connection:
mysql://root:password@localhost:3306/db
Expected behavior
App works normally, no exceptions got
The text was updated successfully, but these errors were encountered: