fix: renumber migrations to fix staging deployment #592
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.
Summary
Fixes staging deployment by renumbering migrations to match what staging has already applied.
Problem
Staging already applied migration 008 (metadata separation) before we inserted the new cleanup migration. When we added the cleanup as 008 and renumbered metadata to 009, staging tried to apply 009 again and failed with "column already exists".
Current State
Solution
008_clean_invalid_data.sql→007a_clean_invalid_data.sql009_separate_official_metadata.sql→008_separate_official_metadata.sql(back to original)How This Fixes It
With this renumbering:
Staging behavior:
Production behavior:
Testing
This is a critical fix to unblock staging deployment.