fix(scripts): no-issue: normalise migration storage in determinism precheck#10146
Queued
dannash100 wants to merge 1 commit into
Queued
fix(scripts): no-issue: normalise migration storage in determinism precheck#10146dannash100 wants to merge 1 commit into
dannash100 wants to merge 1 commit into
Conversation
…echeck The determinism harness builds its baseline DB at the pre-migration commit, which can pre-date the build-less switch and so records `.js` migration names. At HEAD, areMigrationsAvailable() consulted migrations directly, tripping createMigrationInterface's `.js`-vs-`.ts` guard before migrateAndHash() could run the upgrade that normalises them. Normalise the storage in the precheck too (exporting normaliseMigrationStorageExtensions from @tamanu/upgrade), matching what upgrade() does before any migration state is read.
|
🦸 Review Hero Summary No issues found. Looks good! |
passcod
approved these changes
Jun 26, 2026
Any commits made after this event will not be merged.
|
E2E failure report E2E failed for run 21589. The report artifact contains the merged Playwright HTML report with failure videos, screenshots, and traces where available. |
Any commits made after this event will not be merged.
Any commits made after this event will not be merged.
Any commits made after this event will not be merged.
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.
Changes
Fixes the Migration determinism check, which has been red on
mainsince #10097 (the build-less switch). The determinism harness builds its baseline DB at the pre-migration commit — which can pre-date the build-less switch and so records.jsmigration-storage names — then at HEADareMigrationsAvailable()consulted migrations directly, trippingcreateMigrationInterface's.js-vs-.tsguard beforemigrateAndHash()could run the upgrade that normalises them. This normalises the storage in that precheck too (exportingnormaliseMigrationStorageExtensionsfrom@tamanu/upgrade), matching whatupgrade()already does before any migration state is read. Idempotent / no-op once names are normalised, so it doesn't affect normal post-switch runs.Auto-Deploy
Options
Tests
Review Hero
.github/review-hero/suppressions.yml. Also runs automatically at the end of any auto-fix run.Remember to...