Skip to content

S15/S17 part: migration-aware recovery check and incident evidence model (pure, unwired) - #46

Merged
im-tyler merged 2 commits into
mainfrom
claude/w4-s15-s17-incidents
Oct 4, 2026
Merged

im-tyler merged 2 commits into
mainfrom
claude/w4-s15-s17-incidents

Conversation

@im-tyler

@im-tyler im-tyler commented Oct 4, 2026

Copy link
Copy Markdown
Contributor

Changes

  • src/recovery-compat.ts: pure check of whether rollback to the retained version stays compatible with applied migrations. Unread or unclassified state => hold. A newer contract/irreversible migration => incompatible (a recorded specific recovery plan is reported but is never a pass). Newer additive (expand) migrations or none => compatible. It never claims to prove the artifact rollback (provesArtifactRollback: false).
  • src/incident-evidence.ts: observations (health, log excerpt, deploys, migration state) become a record that separates facts, hypotheses (type forbids high; correlation caveat; medium needs two evidence kinds), unknowns, set-aside other-service evidence, an ordered read-only timeline (unparseable times kept last and flagged), a candidate-only proposal and an actionable escalation.
  • Both modules are pure and UNWIRED: no flag needed, default behaviour unchanged, no storage, no I/O, no model.

Checks

  • pnpm run lint clean. Clean build, node --test over dist: 2002 pass, 0 fail (19 new tests).
  • 8 negative controls, each verified by mutating the code and watching a test fail, then restoring: unknown-to-hold gate, blocking class, unclassified class, thin-sample healthy, service attribution filter, high confidence, deploy-after-onset/failed filter, medium-needs-corroboration.
  • Skipped scripts/grader-sensitivity (fixed port 8901 collision between agents); CI runs it.

Not verified / still open

  • Nothing is wired: no delivery rollback gate, no incident page timeline, no migration-state reader on a real target. No live observation, deploys or model calls. Only "checked", not "verified outcome".
  • Log redaction is the caller's responsibility (excerpts are clamped only).

🤖 Generated with Claude Code

https://claude.ai/code/session_01VqsBNqvaWezf1DwQrAnVgX


Generated by Claude Code

claude added 2 commits October 4, 2026 03:16
Pure, unwired modules. recovery-compat.ts: rollback to the retained version
vs applied migrations; unknown/unclassified => hold, contract/irreversible
=> incompatible, never proves the artifact rollback. incident-evidence.ts:
observations -> facts / hypotheses (never high) / unknowns / set-aside
other-service evidence / ordered timeline / escalation.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VqsBNqvaWezf1DwQrAnVgX
@im-tyler
im-tyler merged commit 4ebe00a into main Oct 4, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants