Skip to content

Commit f28d275

Browse files
authored
[v3-1-test] Protect against hanging thread in aiosqlite 0.22+ (#60217) (#60245)
The change in model of aiosqlite impacted sqlalchemy handling of closing the connection - the way how currrent sqlalchemy works with it is that it leaves threads hanging. This is fixed in sqlalchemy main - sqlalchemy/sqlalchemy#13039 but until they release it and until we have the sqlalchemy>=2.0.46, we should upper-bind the aiosqlite (cherry picked from commit 9b364ca)
1 parent 562a463 commit f28d275

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

airflow-core/pyproject.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,11 @@ dependencies = [
6969
"a2wsgi>=1.10.8",
7070
# aiosqlite 0.22.0 has a problem with hanging pytest sessions and we excluded it
7171
# See https://github.com/omnilib/aiosqlite/issues/369
72-
"aiosqlite>=0.20.0,!=0.22.0",
72+
# It seems that while our test issues are fixed in 0.22.1, sqlalchemy 2 itself
73+
# is not compatible with it and leaves thread hanging This is already fixed in main of sqlalchemy
74+
# But not released yet - and we will likely have to add >=2.0.46+ for sqlalchemy when released to
75+
# protect against it https://github.com/sqlalchemy/sqlalchemy/issues/13039
76+
"aiosqlite>=0.20.0,<0.22.0",
7377
# Alembic is important to handle our migrations in predictable and performant way. It is developed
7478
# together with SQLAlchemy. Our experience with Alembic is that it very stable in minor version
7579
# The 1.13.0 of alembic marked some migration code as SQLAlchemy 2+ only so we limit it to 1.13.1

0 commit comments

Comments
 (0)