Skip to content

docs(adr): ADR-049 Amendment 2 - graduated fail-loud fallback policy#983

Merged
ohdearquant merged 1 commit into
mainfrom
docs/adr049-amendment-2
Jul 14, 2026
Merged

docs(adr): ADR-049 Amendment 2 - graduated fail-loud fallback policy#983
ohdearquant merged 1 commit into
mainfrom
docs/adr049-amendment-2

Conversation

@ohdearquant

Copy link
Copy Markdown
Owner

Summary

Amends ADR-049's Decision section 2, whose unconditional mandate ("Fallback to local dispatch is mandatory ... never a hard dependency") was never updated when the graduated fail-loud fallback shipped (bba4c4a). This amendment records the contract the code now implements:

  • Closed FallbackReason set with stable string codes (config_mismatch, namespace_mismatch, no_socket, parse_failure, protocol_mismatch) and legitimacy tiers governing quiet/WARN/ERROR observability.
  • KHIVE_DAEMON_STRICT=1 rejects any would-be fallback with a structured, marker-carrying error (default off).
  • Positively observed respawn failures (spawn error, child exited before socket bind) return a stable respawn_failed error in both modes instead of silently serving cold local dispatch; detailed context goes to local structured logging only.
  • KHIVE_NO_DAEMON=1 remains the sanctioned daemonless opt-out; genuinely daemonless environments keep quiet fallback.

Sequencing

Docs-only. Lands before/with #963 so its daemon-path changes are re-gated against the amended contract rather than the stale section-2 mandate.

🤖 Generated with Claude Code

Supersedes the unconditional local-dispatch fallback mandate in Decision
section 2 with the shipped graduated policy: reason-coded fallback tiers
(no-daemon quiet, rollout-transient WARN, illegitimate ERROR + strict
rejection under KHIVE_DAEMON_STRICT=1) and fail-loud respawn_failed for
positively observed daemon-recovery failures.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

@oceanwaves630 oceanwaves630 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Amendment 2 reviewed in full: graduated reason-coded policy, strict-mode semantics, and the confirmed-respawn rejection contract are coherent with the merged fail-loud direction, and the caller-visible error correctly excludes spawn detail. Approved.

@ohdearquant
ohdearquant marked this pull request as ready for review July 14, 2026 13:34
@ohdearquant
ohdearquant merged commit 4f00425 into main Jul 14, 2026
22 checks passed
@ohdearquant
ohdearquant deleted the docs/adr049-amendment-2 branch July 14, 2026 13:34
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