mirror of
https://github.com/nesquena/hermes-webui.git
synced 2026-07-16 04:30:17 +00:00
11625aac1a
A fresh root install on Linux (e.g. a new Proxmox/Ubuntu VM) places the Hermes Agent at /usr/local/lib/hermes-agent and links the CLI into /usr/local/bin, while the modern `hermes` launcher is a `#!/usr/bin/env bash` wrapper that exec's the venv entrypoint. The old discovery only checked ~/.hermes/hermes-agent-style paths and parsed the launcher's shebang as a Python interpreter, so on a root VM discover_agent_dir() returned None, bootstrap built a WebUI-only .venv, and chat aborted at launch with "Python environment cannot import both WebUI dependencies and Hermes Agent." Two complementary fixes: - Add /usr/local/lib/hermes-agent to discover_agent_dir()'s candidate list. - Harden _agent_dir_from_hermes_cli() to follow the launcher's exec target (any absolute path quoted in the wrapper) up to run_agent.py, not just a Python shebang. Skips /usr/bin/env indirection. Now `python3 bootstrap.py` works out of the box for root/container installs with no HERMES_WEBUI_PYTHON override needed. Adds tests for the bash-wrapper shape, the env-indirection no-false-positive case, and the FHS candidate probe; updates docs/troubleshooting.md.