# NousResearch/hermes-agent · fail_closed hook non-zero exit not blocking

## Open now

- Nothing open on GitHub.

These issues and PRs concern a bug where fail_closed shell hooks that exit non-zero or crash without producing a directive do not correctly block execution. The work focuses on ensuring fail_closed behaves as expected in those edge cases.

## TL;DR

- 6 member(s): 0 open issue(s), 1 closed issue(s), 0 open PR(s), 1 merged PR(s), 4 PR(s) closed without merging.
- A fix was merged to main in PR #131909. Verify it addresses your case.
- **Recommended:** read PR #131909 (and any competing PRs below) before filing. Confirm the merged change covers your symptom.

## Maintainer resolution verdict

- Internal-tracker verdict over this cluster's issue members: `resolved` · deciding PR(s): `pr-131909`. This is distinct from the fix status above. Weigh it yourself.

## How this cluster was grouped

- Link evidence (`STRUCTURAL_SPANNING`): every member is connected by structural evidence: shared changed files, or a closing/superseded reference.
- Pairwise link density `0.33`: the share of member pairs that carry a link, counting a structural link in full and a relevance-only link at 0.36. `1.00` means every pair is linked.

## Closed / duplicate issues

- #102405: shell hooks: \`fail_closed\` does not block when the hook exits non-zero with empty stdout

## Prior & competing PRs

- **#131909: fix(hooks): keep fail-closed gates from permitting crashed hooks \[risk 0.20\]**. merged to main · fix tier `verified`
  - maintainer direction: category `merged`; implication `superseded`
  - files: `agent/shell_hooks.py`, `tests/agent/test_shell_hooks.py`, `website/docs/user-guide/features/hooks.md`
- **#102417: fix(hooks): keep fail-closed gates from permitting crashed hooks**. closed without merge
  - maintainer direction: category `implemented_elsewhere`; implication `superseded`; refs `#131909`
- **#108664: fix(shell_hooks): fail_closed must also block when the hook crashes silently**. closed without merge
  - maintainer direction: category `implemented_elsewhere`; implication `superseded`; refs `#108664`, `#102417`, `#122576`, `#108664`
- **#122576: fix(shell_hooks): fail_closed blocks a non-zero exit with no directive**. closed without merge
  - maintainer direction: category `wontfix_bydesign`; implication `wontfix`; refs `#102405`, `#131909`, `#102417`
- **#122651: fix(agent): fail closed when a fail_closed shell hook exits non-zero without a directive**. closed without merge
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#122576`, `#122576`

## Fix status

- Merged to main in PR #131909 (cited above). No release data is tracked. Verify downstream.
- Fix last verified (merged) `2026-10-03`.
