fix(db): renumber note-taker migration 94→95 (collided with voice-profile 94) - #185
Merged
Conversation
…file 94) Two migrations both landed as 94: 94_email_voice_profile.sql (#176) and 94_note_taker.sql (#181). #176 merged and DEPLOYED first — email_voice_profiles exists on prod — so it keeps 94; #181's note-taker deploy failed on the prefix-uniqueness guard and its tables were never applied, so it renumbers to 95 with zero data impact (apply_migrations replays every numbered file idempotently on each deploy — ordering only). Reference comments in notes/core.py, acb_graph/models.py, and the note-taker spec updated to match. Unblocks main (the collision was failing the unit-test gate and blocking all deploys). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This was referenced Jul 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Incident
mainis red: two migrations both numbered 94 —94_email_voice_profile.sql(feat(email): voice & writing-style profile learned from past mail (mig 94) #176) — merged and deployed successfully first;email_voice_profilesexists on prod.94_note_taker.sql(AI Note Taker: architecture spec + research appendix + slice 0 (schema, acb_stt, /notes API + UI shell) #181) — merged second, deploy failed on thetest_migration_prefixesguard; its tables (notes, etc.) were never applied to prod (verified:to_regclass('notes')is null).test_migration_prefixesfails → the unit-test gate is red → all deploys are blocked.Fix
Renumber the not-yet-applied one:
94_note_taker.sql→95_note_taker.sql. Zero data impact —apply_migrations.shreplays every numbered file idempotently on each deploy (no "last applied" tracking; ordering is the only thing the number controls), and note-taker's tables were never created on prod. The already-applied voice-profile keeps 94. Reference comments innotes/core.py,acb_graph/models.py, and the note-taker spec updated to match.Same class as the #168→#170 collision; the guard did its job, this clears it.
Verify
test_migration_prefixespasses locally.🤖 Generated with Claude Code