# NousResearch/hermes-agent · Gateway agent cache stale after cross-process session writes

## Open now

- Nothing open on GitHub.

The members appear to share one theme: the gateway's cached agent can hold stale context when another process appends to the same session. One issue describes the problem, and the pull requests propose ways to invalidate or rebuild the cached agent, with one also mentioning preserving prompt caching.

## TL;DR

- 4 member(s): 0 open issue(s), 1 closed issue(s), 0 open PR(s), 1 merged PR(s), 2 PR(s) closed without merging.
- A fix was merged to main in PR #46237. Verify it addresses your case.
- **Recommended:** read PR #46237 (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-46237`. 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.50`: 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

- #45966: Gateway replies with stale context when another process appends to the same session (cross-process agent-cache split-brain)

## Prior & competing PRs

- **#46237: fix(gateway): cross-process agent-cache coherence (#45966) + preserve prompt caching**. merged to main · fix tier `verified`
  - maintainer direction: category `merged`
  - files: `gateway/run.py`, `tests/gateway/test_agent_cache.py`
- **#45949: fix(gateway): rebuild cached agent when a session grows in another process**. closed without merge
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#45966`, `#46237`
- **#46095: fix(gateway): invalidate agent cache on cross-process session writes (#45966)**. closed without merge
  - maintainer direction: category `merged_via`; implication `superseded`; refs `#45966`, `#46237`

## Fix status

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