diff --git a/django/db/backends/sqlite3/base.py b/django/db/backends/sqlite3/base.py index f495ff39a1f..feae360567e 100644 --- a/django/db/backends/sqlite3/base.py +++ b/django/db/backends/sqlite3/base.py @@ -301,7 +301,7 @@ class DatabaseWrapper(BaseDatabaseWrapper): for column_name, ( referenced_column_name, referenced_table_name, - ) in relations: + ) in relations.items(): cursor.execute( """ SELECT REFERRING.`%s`, REFERRING.`%s` FROM `%s` as REFERRING diff --git a/docs/releases/4.1.1.txt b/docs/releases/4.1.1.txt index f97015b9fa0..2e4782f9040 100644 --- a/docs/releases/4.1.1.txt +++ b/docs/releases/4.1.1.txt @@ -52,3 +52,6 @@ Bugfixes * Reallowed, following a regression in Django 4.1, creating reverse foreign key managers on unsaved instances (:ticket:`33952`). + +* Fixed a regression in Django 4.1 that caused a migration crash on SQLite < + 3.20 (:ticket:`33960`).