BE-DP-33 · The v1 tables and columns no step claims
ID BE-DP-33 · Level L0 · Pack Pack R4 · The migration machinery · Run order after the pull request for #324 is merged; then each night, as part of the reconcile · Issue #324
v1 is still developing (D75), so a table or a column can appear in it on any night. The reconcile's check v1 unclaimed lists, every night (R-MIG-10):
- every table of the night's snapshot that no step reads, with its row count;
- every column of a table some step reads that no step reads.
A step claims what it reads in migration.claims, beside its code. A listed line is claimed by a step, or signed by you as ignored in migration.accepted_differences with its reason (R-MIG-06). It stops nothing: the night still finishes.
This step runs the check once on the copy, so you see what it lists today. Lines name tables and columns, never a person, so they're safe to post (D15).
Before
Section titled “Before”- The pull request for #324 is merged, and you are on main after
git pull,pnpm supabase db resetand BE-DP-07. docker ps --filter name=v1copylists the copy as Up.
1 · A snapshot, and the check
Section titled “1 · A snapshot, and the check”docker exec -i supabase_db_opleet psql -qX -U postgres -d postgres -v ON_ERROR_STOP=1 <<'SQL'select migration.begin_run('BE-DP-33, local, on the v1 copy') as run;select migration.snapshot() as tables_copied;select split_part(row_key, ' ', 1) as kind, count(*) as lines from migration.reconcile()where check_name = 'v1 unclaimed' group by 1 order by 1;select row_key, detail from migration.reconcile() where check_name = 'v1 unclaimed' order by 1;select migration.finish_run('succeeded');SQLExpect
Section titled “Expect”tables_copied35 or so.- Tables no step reads yet: the ones whose steps aren't merged. Today that is the drivers step's (
leads,antrian,deleted_leads), the rentals, operations and money steps' (for examplecontracts,handovers,maintenance,stock_opname_*,debts), but not v1's own backups: a table whose name containsbackupis signed by that pattern and counted on one line,tables named backup(zuki, #591). - Columns: the columns of a read table that no step reads, such as
app_settings.keyandcreated_at. - Each later step's pull request claims its tables, so the list shrinks as the steps merge. A table v1 adds that no step reads stays until a step claims it or you sign it.
Post the two tables on #324. For each line, say one of:
- "a step will read it": name the step, or leave it to the Backend Engineer;
- "ignore": with a reason, and the Backend Engineer writes your signature into the migration for your review (R-MIG-06).
If it fails
Section titled “If it fails”tables_copied0:v1_liveisn't linked. Run BE-DP-07, then the block again.- Anything else: post the
ERRORline on #324.
Nothing to undo beyond the night's run: pnpm supabase db reset removes the snapshot.
Log each run as a comment on #324: date · who · result, with the two tables.