# NousResearch/hermes-agent · TOCTOU race in Claude Code version detection

## Open now

- 1 issue, 1 PR open on GitHub.
- #24751: bug(anthropic_adapter): TOCTOU race in _get_claude_code_version() — concurrent OAuth calls each spawn a subprocess to detect version
- PR #24768: fix(anthropic): serialize Claude Code version detection

These issues and PRs address a race condition in \`_get_claude_code_version()\` where concurrent OAuth calls each spawn redundant subprocesses. Proposed fixes involve serializing version detection to prevent this.

## TL;DR

- 4 member(s): 1 open issue(s), 0 closed issue(s), 1 open PR(s), 0 merged PR(s), 2 PR(s) closed without merging.
- No fix has been merged to main; one or more PRs were attempted (see below).
- **Recommended:** review the prior/competing PR(s) below. A fix was attempted but not merged; your case may extend or revive that work.

## Maintainer resolution verdict

- Internal-tracker verdict over this cluster's issue members: `unresolved`. 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.

## Open related issues

- #24751: bug(anthropic_adapter): TOCTOU race in _get_claude_code_version() — concurrent OAuth calls each spawn a subprocess to detect version

## Prior & competing PRs

- **#24752: fix(anthropic_adapter): prevent TOCTOU race in _get_claude_code_version()**. closed without merge · fix tier `suggested`
  - maintainer direction: category `uncategorized`; implication `needs_llm`
  - _suggested-tier fix detail withheld; re-request with `?tier=all` to include it._
- **#24768: fix(anthropic): serialize Claude Code version detection**. open
  - maintainer direction: category `duplicate_of`; implication `duplicate`; refs `#24752`, `#24751`
  - files: `agent/anthropic_adapter.py`, `tests/agent/test_anthropic_adapter.py`
- **#61185: Serialize Claude Code version detection**. closed without merge
  - maintainer direction: category `duplicate_of`; implication `duplicate`; refs `#24768`, `#24751`

## Fix status

- No merged fix on record.
- Subsystem: `agent`
