Implement atomic publish activation and success state transition.
Scope
- Update metadata.json → status = SUCCESS, completed_at set, published = true
- Write temporary pointer file (_latest.tmp)
- Payload:
- run_id
- version = v{run_id}
- published_at (UTC)
- Atomically swap using
os.replace → _latest.json
Execution order requirement:
- Integrity gate passes
- Version copy completes
metadata.json updated to SUCCESS
- Atomic pointer swap
Acceptance Criteria:
- Pointer always references fully copied version
- No partial pointer writes possible
- Pointer never updated if metadata update fails
- Dashboard reads only
_latest.json
Implement atomic publish activation and success state transition.
Scope
os.replace→_latest.jsonExecution order requirement:
metadata.jsonupdated to SUCCESSAcceptance Criteria:
_latest.json