Spaces:
Paused
Paused
Commit History
-
Tier 1, step 5: close the coverage gaps and the doc drift (C6-C16, E1, E2)
Claude +1: Claude Opus 5Unverified signatureThe mutation-proven gaps first. Each of these was verified by re-introducing the exact defect and confirming the new test goes red. C8 — drawBuildingBars and drawBuildGhost were covered only by assert.doesNotThrow, so replacing either body with `return;` survived the full suite: every health bar, build-progress bar, output gauge and paused/stalled badge in the game could vanish with CI green on both Node versions. The recording ctx this file already had is now used to assert real output, that a damaged building gets a bar, and that a paused producer is drawn differently from a running one. (Not "draws more" — a running-but-throttled factory draws the busier badge of the two.) C9 — dropping aiColonyTarget, aiLastThreatAt, or the entire playerAi block from persist.js also survived. Re-checked by mutation: both single-field drops now fail. The failure mode is "the AI behaves differently after reload", the hardest class of bug to report. C14 — commit ac44339's ore-surplus army-cap featu…cce54f5
-
Address remaining review defects: B3–B6 + load-hardening + static checks
Claude +1: Claude Opus 4.8Unverified signatureA fanned-out team of agents fixed the remaining SAFE items from the architecture review, partitioned by file so they never collided; verified and committed centrally. All identity for valid data (guarded on field presence/range), so determinism + round-trip guarantees hold — behavior changes only for corrupt/tampered/NaN input. Load hardening (engine/persist.js, test/save-hardening.test.js): - B3: clamp a wonder's `charge` to [0,1] on load — a hand-edited charge:1 no longer trips an instant standalone-endless win (victory.js). - B4: recompute the galaxy `g`-id counter (`entitySeq`) from live g-ids across all worlds on load, mirroring maxOwnEntityId for the u/b counter — a low/missing entitySeq can no longer mint a colliding g-id over an in-flight colony ship / freighter / relief ship. - B5: coerce untrusted order/orderQueue coords (finite, in-map) and worker cargo (finite qty, real commodity) so a tampered save can't NaN-poison the movement/gather math. - Non-array `researchQu…fdea120