# Engine worker checkpoint Updated: 2026-09-09 ## Followup checkpoint (openai/gpt-5.6-terra) - Source worktree: `/home/alex/sots-engine` at `7741d42fc5e4e761e6449bdaf0e4a61d00036a23`; RE state root: `/home/alex/sots-re` at `3bfde5a70d874a723e797a695bbd847fd82c0aa7`. - Preserved command-replay leaf writes during `RunStrategicTurn`'s final record fold, then added an `app_command_replay` regression that verifies an applied replay write changes the board and is included exactly once beyond all phase records. - Changed configured empty save directories from skips to failures in the modified app turn, app turn-record, design census, Mars save, and Mars domain corpus consumers. Unset dependencies retain their existing skip behavior; unreadable and parse-error saves remain failures without skip wording. - Observation: `git diff --check` passed before focused build/test execution. Existing unrelated rollout changes are present in the engine worktree and were left untouched. - `mars_stream_test_save` now stops after reporting parser errors, before accessing typed-shape assumptions. `mars_stream_domains` reports parse/read errors and omits those saves from its domain archive. This turned the malformed-save signal termination into ordinary nonzero test failures; it is a test-boundary fix within the assigned contract, not an architecture change. - Results: fresh `/tmp/opencode/sots-engine-followup` host build succeeded. With `SOTS_SAVES_DIR=/home/alex/sots-re/verify/results/saves`, `ctest --test-dir /tmp/opencode/sots-engine-followup --output-on-failure -R '^(app_command_replay|app_turn|app_turn_record|mars_stream_save|mars_stream_domains)$'` passed 5/5 twice, after the final test-boundary change. - Negative evidence: each modified corpus executable returned nonzero for the configured empty directory `/tmp/opencode/sots-empty-corpus`: app turn, app turn-record, Mars save, Mars domains, and design census (the census was given `SOTS_DATA_DIR=/tmp/opencode`). Each of the four applicable consumers returned a normal nonzero failure for configured malformed `/tmp/opencode/sots-invalid-corpus/malformed.sav`; no skip wording or signal termination. - Skip evidence: `env -u SOTS_SAVES_DIR -u SOTS_DATA_DIR ctest --test-dir /tmp/opencode/sots-engine-followup --output-on-failure -R '^(app_turn|app_turn_record|mars_stream_save|mars_stream_domains|game_design_census)$'` reported all five as CTest skipped. Only unset dependencies take that path. - `git diff --check` passed after the final edits. No broad gate was run. Existing unrelated rollout changes in both worktrees remain untouched. - Completion: followup contract implemented and focused evidence recorded. Next action: stop; lead may consume this checkpoint for the coordinated source-stable gate. - Implemented nonserialized `MT19937::words_drawn()` accounting. It resets on `seed()` and successful `load_state()` and is not included in save serialization. - `CountingRandom` now measures bounded-integer rejection consumption from that monotone count, so a rejection loop may cross any number of twists. - Removed S13 wrapper aggregation of P01..P12 counters; appended player records are the only contributors to final turn totals. - Added MT boundary/rejection and reset/load tests, plus an app corpus test that validates reported RNG words against the independently persisted generator post-state. - Corpus absence now returns 77 for app/census tests; unreadable or parse-error saves fail and nonzero executed saves remain required. CTest skip properties were added to dependency tests. - Verification: fresh build at `/tmp/opencode/sots-engine-accounting` configured and built successfully. `SOTS_SAVES_DIR=/home/alex/sots-re/verify/results/saves ctest --output-on-failure` passed 52 of 59 tests; the remaining 7 were reported by CTest as skipped. - Skip inventory verified with verbose CTest: `game_config_replay` lacks `SOTS_M1_TRACE` and `SOTS_DATA_DIR`; `game_data_realdata`, `game_design_realdata`, and `mars_text_realdata` lack data inputs; `game_design_census` lacks `SOTS_DATA_DIR`; `game_sim_smoke_real_save` lacks `SOTS_SAVES_JSON`; `mars_vfs_realdata` lacks `SOTS_GOB_DIR`. No configured corpus failure was skipped: `app_turn`, `app_turn_record`, `mars_stream_save`, and `mars_stream_domains` executed against the required saves directory and passed. - Focused rerun passed `mars_rng_unit`, `app_turn`, and `app_turn_record`; `game_design_census` was CTest-skipped for its missing data-root dependency. `git diff --check` is clean. - Limitation: full asset-dependent acceptance remains unavailable locally because the listed asset and trace paths are unset. The configure cache does not consume `-DSOTS_SAVES_DIR`; the required path was supplied to CTest through its runtime environment.