mirror of
https://github.com/Significant-Gravitas/AutoGPT.git
synced 2026-02-09 22:35:54 -05:00
Array fields in `schema.prisma` are non-nullable, but generated migrations don’t add `NOT NULL` constraints. This causes existing rows to get `NULL` values when new array columns are added, breaking schema expectations and leading to bugs. ### Changes 🏗️ - Backfill all `NULL` rows on non-nullable array columns to empty arrays - Set `NOT NULL` constraint on all array columns ### Checklist 📋 #### For code changes: - [x] I have clearly listed my changes in the PR description - [x] I have made a test plan - [x] I have tested my changes according to the test plan: - [x] Existing `NULL` rows are properly backfilled - [x] Existing arrays are not set to default empty arrays - [x] Affected columns became non-nullable in the db