tech-debt: Migration framework does not handle foreign keys #329

Open
opened 2026-05-31 14:23:34 +00:00 by jmiller · 0 comments
Owner

Summary

Database migration code cannot handle tables with foreign keys.

Locations

  • models/migrations/base/db.go:45 - will not work if there are foreign keys
  • models/migrations/base/db.go:311 - will not work if there are foreign keys
  • models/db/driver_sqlite_modernc.go:30 - changed behavior from mattn driver

Action Required

Add foreign key handling to migration framework. Document SQLite driver behavior differences.


Created by Claude Opus 4.6

## Summary Database migration code cannot handle tables with foreign keys. ## Locations - `models/migrations/base/db.go:45` - will not work if there are foreign keys - `models/migrations/base/db.go:311` - will not work if there are foreign keys - `models/db/driver_sqlite_modernc.go:30` - changed behavior from mattn driver ## Action Required Add foreign key handling to migration framework. Document SQLite driver behavior differences. --- *Created by Claude Opus 4.6*
jmiller added the tech-debtupstream labels 2026-05-31 14:23:34 +00:00
Sign in to join this conversation.
No labels tech-debt upstream
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: MokoConsulting/MokoGitea#329