Internal record of all changes. Will be refined into public changelog entries.
- CR-01 — Fixed TOCTOU race in
LocalFileSnapshotStore.load_snapshot:open()thenos.fstat(fd)replacesstat()+open()pattern - CR-02 — Added module-level logger in
agent_output_to_payload(parallel/types.py), replaced rootlogging.warning() - WR-03 — Added empty-keys guard to
ContextBroker.signing_secret/current_key_idproperties - WR-05 — Made
_remove_from_indexreturnFailure(code=ErrorCode.CORRUPTED_INDEX)on JSON errors (consistent with_add_to_index) - WR-06 — Added step-overflow pre-check in
create_next_envelope(envelope.py) - WR-08 — Replaced silent non-dict conversion with
ValueErrorinLocalModelAdapter.run - WR-02 — Removed stale/redundant local imports from
test_snapshot.py - WR-04 — Fixed temp directory leaks in
TestPreV04SnapshotCompatviasetup_method/teardown_method - WR-07 — Added
test_load_snapshot_fails_when_body_pipeline_id_differs_from_filenametest
- Conducted comprehensive review of all 31 source modules + 24 test files
- IN-01 — Removed stale local imports in
test_snapshot.py - IN-02 — Added signature verification docs to
InMemorySnapshotStore - IN-03 — Fixed double
ContextBrokercreation inCoreRelayPipeline.create() - IN-04 — Conditional fork metadata serialization (omit None fields)
- IN-05 — Added thread safety documentation to
LocalFileSnapshotStore
- Reordered index sort before envelope storage in
InMemorySnapshotStore.save_snapshotto prevent inconsistent state on sort failure
- Added
pipeline_idcross-check in bothLocalFileSnapshotStore.load_snapshot()andInMemorySnapshotStore.load_snapshot()
- Promoted
_extract_step_from_snapshot_idto publicextract_step_from_snapshot_idinsnapshot_protocol.py
- Added
logger.warning()in_remove_from_indexwhen overwriting non-conforming index files
- 50 test name violations in
test_audit_events.py,test_audit_redactor.py,test_audit_sink.pyrenamed to full sentences by appending connecting words (_when_constructed,_when_provided,_when_called,_with_isinstance, etc.) - Commit
96de10b—fix(tests): rename 50 tests to full sentences per Rule 7.1 - All 422 unit tests pass, mypy clean
- Design phase: Identified gap, designed
BranchReceiptfrozen dataclass event, wrote design doc todocs/superpowers/specs/2026-05-18-branch-receipt-event-design.md, user approved - Task 1 (commit
0260996): AddedBranchReceiptdataclass toevents.pywith 22 fields, added toAuditEventunion +__all__, 4 construction tests. Code review fix in01557e6. - Task 2 (commit
d0841e1):_apply_first_winsreturnstuple[Result[JSONDict], list[ForkResult]].apply_join_strategypublic signature unchanged. - Task 3 (commit
9628159):execute_parallel_stepemits oneBranchReceiptper fork after all forks complete. FIRST_WINS runs all forks (no early cancellation). AddedBranchReceiptexport torelay/audit/__init__.py. All 426 tests pass, mypy clean. - Task 4 fixes (commit
734622c): Addedisinstance(join_strategy, JoinStrategy)early validation inexecute_parallel_step. Fixed FIRST_WINS integration timing test for all-forks-run behavior. 454 tests pass, mypy clean. - Implementation plan at
docs/superpowers/plans/2026-05-18-branch-receipt-event.md - Public changelog v0.5.1 updated with full implementation details
test_parallel_step_with_invalid_join_strategy_returns_failure— added early validation inexecute_parallel_step(before.valueaccess) to returnFailure(INVALID_JOIN_STRATEGY)for raw stringstest_first_wins_commits_envelope_before_slow_fork_completes→test_first_wins_commits_envelope_after_all_forks_complete— timing assertion changed from< 1.0to>= 2.0
- Made
LocalModelAdapternon-frozen, removedobject.__setattr__hack - Fixed 4 mypy errors in
context_broker.py(lambda Any expressions) - Added
__all__topipeline_rollback.py - Warn on text key collision in
agent_output_to_payload - Added
asyncio_default_fixture_loop_scopeto suppress deprecation warning
- Added
INDEX_NOT_FOUNDfailure code test - Multiple source fixes (F-13 through F-24) in audit module
- Created
SnapshotStoreProtocol insnapshot_protocol.py - Renamed
SnapshotStore→LocalFileSnapshotStore - Created
InMemorySnapshotStorefor testing - Wired
snapshot_storefield injection intoCoreRelayPipeline - Updated all consumers:
core_pipeline.py,pipeline_rollback.py,__init__.py - Made
CloseableProtocol@runtime_checkable - Added Protocol acceptance tests
- 16 exhaustive tests for
InMemorySnapshotStore - 5 pipeline wiring tests