From 4979d77a4a908650df15a181d00a921680d5110a Mon Sep 17 00:00:00 2001 From: Teknium Date: Fri, 3 Apr 2026 12:32:10 -0700 Subject: [PATCH] =?UTF-8?q?fix:=20complete=20browser=5Ftool=20profile=20is?= =?UTF-8?q?olation=20=E2=80=94=20replace=20remaining=203=20hardcoded=20HER?= =?UTF-8?q?MES=5FHOME=20instances?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The original PR fixed 4 of 7 instances. This fixes the remaining 3: - _launch_local_browser() PATH setup (line 908) - _start_recording() config read (line 1545) - _cleanup_old_recordings() path (line 1834) --- tools/browser_tool.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/browser_tool.py b/tools/browser_tool.py index 8339fdd9c..546ed3cd1 100644 --- a/tools/browser_tool.py +++ b/tools/browser_tool.py @@ -905,7 +905,7 @@ def _run_browser_command( # Ensure PATH includes Hermes-managed Node first, Homebrew versioned # node dirs (for macOS ``brew install node@24``), then standard system dirs. - hermes_home = Path(os.environ.get("HERMES_HOME", Path.home() / ".hermes")) + hermes_home = get_hermes_home() hermes_node_bin = str(hermes_home / "node" / "bin") existing_path = browser_env.get("PATH", "") @@ -1542,7 +1542,7 @@ def _maybe_start_recording(task_id: str): if task_id in _recording_sessions: return try: - hermes_home = Path(os.environ.get("HERMES_HOME", Path.home() / ".hermes")) + hermes_home = get_hermes_home() config_path = hermes_home / "config.yaml" record_enabled = False if config_path.exists(): @@ -1831,7 +1831,7 @@ def _cleanup_old_recordings(max_age_hours=72): """Remove browser recordings older than max_age_hours to prevent disk bloat.""" import time try: - hermes_home = Path(os.environ.get("HERMES_HOME", Path.home() / ".hermes")) + hermes_home = get_hermes_home() recordings_dir = hermes_home / "browser_recordings" if not recordings_dir.exists(): return