mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-04-28 06:51:16 +08:00
fix: remove 115 verified dead code symbols across 46 production files
Automated dead code audit using vulture + coverage.py + ast-grep intersection, confirmed by Opus deep verification pass. Every symbol verified to have zero production callers (test imports excluded from reachability analysis). Removes ~1,534 lines of dead production code across 46 files and ~1,382 lines of stale test code. 3 entire files deleted (agent/builtin_memory_provider.py, hermes_cli/checklist.py, tests/hermes_cli/test_setup_model_selection.py). Co-authored-by: alt-glitch <balyan.sid@gmail.com>
This commit is contained in:
@@ -589,25 +589,4 @@ def camofox_console(clear: bool = False, task_id: Optional[str] = None) -> str:
|
||||
})
|
||||
|
||||
|
||||
# ---------------------------------------------------------------------------
|
||||
# Cleanup
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
def cleanup_all_camofox_sessions() -> None:
|
||||
"""Close all active camofox sessions.
|
||||
|
||||
When managed persistence is enabled, only clears local tracking state
|
||||
without destroying server-side browser profiles (cookies, logins, etc.
|
||||
must survive). Ephemeral sessions are fully deleted on the server.
|
||||
"""
|
||||
managed = _managed_persistence_enabled()
|
||||
with _sessions_lock:
|
||||
sessions = list(_sessions.items())
|
||||
if not managed:
|
||||
for _task_id, session in sessions:
|
||||
try:
|
||||
_delete(f"/sessions/{session['user_id']}")
|
||||
except Exception:
|
||||
pass
|
||||
with _sessions_lock:
|
||||
_sessions.clear()
|
||||
|
||||
Reference in New Issue
Block a user