# NousResearch/hermes-agent · SSH backend tilde path resolution fix

## Open now

- Nothing open on GitHub.

These issues and PRs address a bug where file tool operations on the SSH terminal backend incorrectly expand tilde (~) against the gateway/host HOME directory instead of the remote SSH user's HOME. The work involves passing paths through to the remote for resolution rather than expanding them locally.

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

## Closed / duplicate issues

- #71201: \[Bug\]: write_file/patch expand ~ against the gateway HOME, not the ssh remote HOME — tilde-path writes fail on the ssh terminal backend (survives #57998)

## Prior & competing PRs

- **#122657: fix(tools): resolve ssh file paths and cwds on the remote, not the Hermes host**. merged to main · fix tier `verified`
  - maintainer direction: category `merged`
  - files: `tests/tools/test_ssh_remote_cwd.py`, `tools/environments/ssh.py`, `tools/file_tools.py`, `tools/file_tools_paths.py`, `tools/file_tools_write_guards.py`, `tools/terminal_tool.py`, `tools/terminal_tool_config.py`
- **#71280: fix(tools): pass ~ through to the ssh remote instead of expanding against gateway HOME (#71201)**. closed without merge
  - maintainer direction: category `implemented_elsewhere`; implication `superseded`; refs `641c49f841`, `#122657`, `#121686`
- **#107940: fix(tools): ssh backend file tools resolve ~ against the remote home, not the gateway's (#71201, salvage #71280)**. closed without merge
  - maintainer direction: category `uncategorized`; implication `needs_llm`; refs `#71280`

## Fix status

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