fix: marker_seen deletes commit with the wall change

A wall cause change (endpoint move, thickness/position, player_marker off,
no longer window) committed the wall row in the FULL transaction while its
marker_seen deletes rode the later NORMAL derived-memory transaction. A crash
between them left the stale row, and restart restored the marker with the
anchor recomputed from the NEW geometry, revealing a position the player never
saw (DESIGN 5.8).

updateWall now deletes the affected rows in the same FULL transaction as the
replaced row, exactly as the composite FK cascade already does for wall.remove.
The live del frames are unchanged and marker inserts stay in the derived
transaction: wall+deletes commit, derived inserts, then ack.

The marker cause signature moves to world.markerSig so the write-time delete
and the online retraction cannot drift.

Proof: a leakfault-only markerCrash hook quits between the wall commit and
the derived write; tools/markers.test.mjs covers all four causes and restarts
on a clean build, asserting no marker for the changed wall (no new anchor) and
restoring the untouched window's marker as the positive control.

Ref #60
This commit is contained in:
2026-11-19 23:52:13 +01:00
parent c3c0a39188
commit a69563f701
8 changed files with 160 additions and 27 deletions
+7
View File
@@ -908,3 +908,10 @@ Each entry quotes the superseded statement (excerpt) and names the surviving rul
That is 5.8 [#42], which superseded both; this block fixed heights and units only, and what a
low wall hides (#44) and thickness (#45) were settled afterwards in 5.9 and 5.10." Historical
provenance only; the surviving rules are current §1, §5.7, §5.8, §5.9, §5.10.
17. **All marker deletes in the derived transaction (2026-11-19, #60).** Old §8: "marker
inserts/deletes are derived player memory and ride the mutation's `NORMAL` transaction (the
same one as the explored chunks)". Narrowed after the #60 crash review: a cause-change delete
rides the wall row's `FULL` transaction (inserts stay `NORMAL`), because a crash between the
two would restore the marker with the new geometry and reveal a position the player never saw.
Surviving rules: current §5.8, §8.