mirror of
https://github.com/ent/ent.git
synced 2026-05-22 09:31:45 +03:00
Since SQLite does not allow enabling/disabling foreign key checks within a transaction, Atlas disabled foreign key checks before opening a transaction and re-enables them after commit/rollback. This involves checking for violations every time the auto migrate tool checks for changing. By opening a transaction only in case there are changes, we can avoid this when not needed. Closes https://github.com/ariga/atlas/issues/3297