Skip to content

The agent that grows with you

docs(update): post-commit contract in the compacted update-pipeline docs

Teknium741f29d5173b
diff --git a/hermes_cli/AGENTS.md b/hermes_cli/AGENTS.md
index 23bc568dd04..825fc63365a 100644
--- a/hermes_cli/AGENTS.md
+++ b/hermes_cli/AGENTS.md
@@ -136,7 +136,8 @@ The stage-by-stage contract: `website/docs/developer-guide/cli-internals.md` §
`_ZIP_PRESERVED_NESTED` build outputs into the swap.
- Restarts are fleet-wide and drain-first, bounded by the home each unit runs on
(`update_fleet_scope.py`); another install's runtime is never restarted.
-- A provably-stale gateway fails the update (exit 1); every run writes a receipt under
+- After the commit point nothing fails `hermes update`: a stale gateway or failed post-commit
+ step is a receipt `followup` with its obligation kept armed. Receipts live under the ROOT home's
`logs/update_receipts/`.
- Nothing runs pulled code in the pre-pull interpreter. `update_handoff.py` and
`update_serve_obligations.py` are a FROZEN compat surface (`tests/compat/old_updater_surface.json`):
diff --git a/website/docs/developer-guide/cli-internals.md b/website/docs/developer-guide/cli-internals.md
index d3610e70e91..a4c848b0d61 100644
--- a/website/docs/developer-guide/cli-internals.md
+++ b/website/docs/developer-guide/cli-internals.md
@@ -51,10 +51,23 @@ it guards. `plan → snapshot → apply → restart-per-kind → verify → repo
left alone, never restarted (#93349).
- **Verify**: gateways stamp `code_sha`/`code_version` into `gateway_state.json` on every
runtime-status write (`gateway/status.py`); the updater compares each live gateway against the
- fresh checkout and prints a fleet version matrix. A provably-stale gateway fails the update
- (exit 1) — automation must never treat a mixed-version fleet as healthy.
-- **Report**: every run writes a machine-readable receipt to `~/.hermes/logs/update_receipts/`
- (`latest.json` pointer; steps, skips WITH reasons, restart outcome, plan, fleet snapshot).
+ fresh checkout and prints a fleet version matrix. After the commit point (the tree moved) nothing
+ fails `hermes update` (exit 0 unless the code was rolled back): a provably-stale or stopped
+ gateway, a failed build/launcher/config migration/bytecode sweep/channel adoption/Windows resume
+ each print `⚠`, land in the receipt as `outcome: "success"` with `followups: [{step, reason}]`,
+ and keep their own obligation armed (`source-completion-pending` for the tail, the fleet-restart
+ obligation for gateways) so the next launch or `hermes update` — including "Already up to date" —
+ retries them. The owed-fleet-restart CLI startup warning is what keeps a mixed-version fleet from
+ ever looking healthy. Exit 2 (refused/concurrent) and exit 1 (nothing committed / rolled back)
+ keep their meaning.
+- **Report**: every run writes a machine-readable receipt to the ROOT home's
+ `logs/update_receipts/` (never a sticky profile's; `update.log` likewise) — `latest.json` pointer;
+ steps, skips WITH reasons, restart outcome, plan, fleet snapshot, `followups`. The receipt is on
+ disk as `outcome: "running"` from the start and refreshed at each stage boundary; the next
+ update marks a `running` record whose processes are gone `interrupted` and says so. Readers
+ (`hermes logs update`, debug bundle, dashboard status, pm receipts) use the root home too.
+ A dependency-sync failure in the completion bootstrap is a `dependencies` follow-up (A6), and
+ Ctrl-C after the commit point finalizes `interrupted` (exit 130), never `failed`.
Before a source swap, the parent captures plan/snapshots/receipt and its Windows pause token.
`update_completion.py` runs new-code PM preparation with site initialization disabled, then
selected-Python builds, maintenance, scans/restarts and verification. Git/current/ZIP share