# NousResearch/hermes-agent · Cross-process locking for MCP OAuth token refresh

## Open now

- Nothing open on GitHub.

A bug where concurrent agent processes sharing the same HERMES_HOME directory corrupt rotating OAuth tokens due to missing cross-process file locking during MCP token refresh. The members cover the bug report and two related fixes addressing serialization and file locking.

## 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 #111186. Verify it addresses your case.
- **Recommended:** read PR #111186 (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-111186`. 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

- #71335: \[Bug\]\[auth\] Concurrent agent processes sharing HERMES_HOME corrupt rotating MCP OAuth grants (Notion) — no cross-process lock on mcp-tokens

## Prior & competing PRs

- **#111186: MCP OAuth refresh is fenced across processes so a rotated refresh token is presented exactly once (#71335, salvage #94846)**. merged to main · fix tier `verified`
  - maintainer direction: category `merged`
  - files: `tests/tools/test_mcp_oauth.py`, `tests/tools/test_mcp_oauth_manager.py`, `tools/mcp_oauth.py`, `tools/mcp_oauth_provider.py`
- **#71377: fix(mcp): add cross-process file lock around OAuth token refresh (#71335)**. closed without merge
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#71715`
- **#71715: fix(mcp): serialize rotating OAuth refreshes**. closed without merge
  - maintainer direction: category `merged_via`; implication `superseded`; refs `8ad7ae06e7`, `#111186`

## Fix status

- Merged to main in PR #111186 (cited above). No release data is tracked. Verify downstream.
- Fix last verified (merged) `2026-09-15`.
- Subsystem: `agent`
