# NousResearch/hermes-agent · gateway --replace host-lock and race condition fixes

## Open now

- Nothing open on GitHub.

These items concern bugs and fixes around the gateway's --replace flag, including issues where host-lock refusal is skipped, a second gateway instance starts after a lost lock race, and related deadlock or respawn-storm behaviors. The members describe both the problems and corresponding fix attempts.

## TL;DR

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

- #119837: --replace skips the host-lock refusal, so a supervised unit that loses the start race runs a second gateway beside the multiplexer

## Prior & competing PRs

- **#120122: fix(gateway): --replace no longer starts a second gateway on a lost lock race, respawn-storms beside a standalone owner, or deadlocks on the stale systemd drop-in (#119837, #119807, #119467)**. merged to main · fix tier `verified`
  - maintainer direction: category `merged`
  - files: `gateway/host_attach.py`, `gateway/run.py`, `hermes_cli/gateway_service_unit.py`, `tests/gateway/test_host_attach_lifecycle.py`, `tests/gateway/test_host_gateway_lock_refusal.py`, `tests/hermes_cli/test_systemd_replace_dropin.py`, `website/docs/user-guide/multi-profile-gateways.md`
- **#119838: fix(gateway): --replace no longer skips the host-lock refusal**. closed without merge
  - maintainer direction: category `merged_via`; implication `superseded`; refs `1a4da74add`, `#120122`

## Fix status

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