diff options
| author | siddus <dcsid10@gmail.com> | 2026-05-27 18:35:28 -0400 |
|---|---|---|
| committer | Jacob Walls <jacobtylerwalls@gmail.com> | 2026-06-11 10:07:02 -0400 |
| commit | c6f81b383251dc9fd0918b4ba040c993444b931e (patch) | |
| tree | 95713e49084752818ed0f261064f121940b8ef9a /scripts/prepare_commit_msg.py | |
| parent | e8cff2921ba169d806a15de18304f431f12700f4 (diff) | |
Fixed #33185 -- Fixed sqlmigrate crash for RenameModel with a self-referential foreign key.
When collecting SQL (e.g. for sqlmigrate), a RenameModel operation's
table rename is not executed, so the subsequent field alteration
introspected the renamed table before it existed. On MySQL this raised
"Table doesn't exist", and on PostgreSQL the missing introspection
silently omitted the self-referential foreign key's drop and recreate.
The schema editor now records table renames while collecting SQL and
redirects constraint-name introspection to the still-existing old table
name, which carries the same constraints. Applying migrations is
unaffected.
Diffstat (limited to 'scripts/prepare_commit_msg.py')
0 files changed, 0 insertions, 0 deletions
