hermes-agent/hermes_cli
Teknium 731aa0ccc9 fix(browser): stop stale cdp_url from stalling every startup by 10+ seconds
Tool-schema assembly at CLI/Desktop startup runs the browser-family
check_fns (browser, browser_cdp, browser_dialog, browser_vision). Each
of those gates called _get_cdp_override(), which resolves the configured
endpoint over HTTP (GET /json/version, timeout=10) — so a *stale*
browser.cdp_url pointing at a dead debug browser cost ~7 serial blocking
socket connects before the banner rendered. Measured on a real Windows
install with a dead http://[::1]:9222 config: 15.1s of an 18s launch,
with no warning or error — just mystery slowness. The value is easy to
leave behind: /browser connect writes a session-scoped env override, but
'hermes config set browser.cdp_url' persists forever while the debug
Chrome it pointed at dies on the next browser restart.

Split the helper:

- _get_cdp_override_raw() — returns the configured value (env var or
  config.yaml) with zero network I/O. Used by every is-it-configured
  gate: check_browser_requirements, _browser_cdp_check, _is_local_mode,
  _is_local_backend, _navigation_session_key, _should_inject_engine
  (via _is_local_mode), and the hermes doctor chromium-skip check.
- _get_cdp_override() — unchanged contract (raw + /json/version
  resolution), now only called on paths that are about to connect:
  session creation and the dialog-supervisor attach.

This follows the existing rule in check_browser_requirements ('do not
execute agent-browser --version here') and the browser.manage status
path, which already banned _get_cdp_override for exactly this reason
(test_browser_manage_status_does_not_call_get_cdp_override): schema
assembly must not perform blocking I/O.

A/B on the same machine, same dead endpoint: get_tool_definitions()
15.08s unpatched -> 1.89s patched, with browser_cdp/browser_dialog
still advertised (gate now keys off configuration, not reachability —
matching the documented lazy-supervisor contract in
_browser_dialog_check).

Adds a regression test asserting the browser_cdp check_fn never touches
the network.
2026-07-27 14:32:05 -07:00
..
dashboard_auth
proxy
subcommands feat(approvals): hermes approvals suggest — mine approval history into allowlist proposals 2026-07-26 17:49:03 -07:00
__init__.py
_early_recovery.py
_parser.py feat: raise default tool-calling iteration limit from 90 to 500 2026-07-26 12:54:45 -07:00
_subprocess_compat.py
active_sessions.py
agent_import.py feat(cli): hermes import-agent — import Claude Code and Codex CLI setups 2026-07-26 17:47:07 -07:00
approval_mode.py feat(approvals): add cross-surface mode command 2026-07-26 21:13:03 -07:00
approvals_suggest.py feat(approvals): hermes approvals suggest — mine approval history into allowlist proposals 2026-07-26 17:49:03 -07:00
auth.py fix(models): match bare Kimi Coding k3 when searching kimi 2026-07-26 21:22:40 -07:00
auth_commands.py
azure_detect.py
backup.py fix(state): stop cancelling our own POSIX locks on live SQLite databases 2026-07-25 21:44:43 -07:00
banner.py
blueprint_cmd.py
browser_connect.py
build_info.py
bundles.py
callbacks.py feat(clarify): add multi-select (checkbox) support to clarify tool 2026-07-26 17:46:55 -07:00
checkpoints.py
claw.py
cli_agent_setup_mixin.py
cli_billing_mixin.py
cli_commands_mixin.py feat(approvals): add cross-surface mode command 2026-07-26 21:13:03 -07:00
cli_output.py
clipboard.py
codex_models.py
codex_runtime_plugin_migration.py
codex_runtime_switch.py
colors.py
commands.py feat(approvals): add cross-surface mode command 2026-07-26 21:13:03 -07:00
completion.py
config.py revert: PR #72817 — session activity watchdog, stall notify, compress timeout 2026-07-28 00:15:00 +05:00
console_engine.py
container_boot.py
context_switch_guard.py
copilot_auth.py
credential_lifecycle.py
cron.py
curator.py fix(curator): make the autonomous write policy consistent (#67140) 2026-07-25 19:27:17 -07:00
curses_ui.py fix(models): match bare Kimi Coding k3 when searching kimi 2026-07-26 21:22:40 -07:00
dashboard_register.py
debug.py
default_soul.py
dep_ensure.py
diagnostics_upload.py
dingtalk_auth.py
doctor.py fix(browser): stop stale cdp_url from stalling every startup by 10+ seconds 2026-07-27 14:32:05 -07:00
dump.py revert: PR #72817 — session activity watchdog, stall notify, compress timeout 2026-07-28 00:15:00 +05:00
env_loader.py
fallback_cmd.py refactor(fallback): single owner for backend identity and failure-scoped skips 2026-07-26 23:41:54 -07:00
fallback_config.py
focus_view.py feat(cli): /focus — reduced-output view with hidden-line recovery and status indicator 2026-07-26 18:10:34 -07:00
gateway.py fix(setup): stop asking about self-configuring platform knobs 2026-07-26 08:43:24 -07:00
gateway_enroll.py
gateway_windows.py fix(update): migrate legacy pythonw Windows gateway launchers to the hidden-console design 2026-07-26 17:50:54 -07:00
goals.py
gui_uninstall.py
hooks.py feat(delegate): expose redacted child tool history 2026-07-26 20:36:47 -07:00
init_command.py feat(cli): /init — generate or update AGENTS.md from a project scan 2026-07-26 17:46:29 -07:00
input_sanitize.py
inventory.py refactor(cli): route every aux picker through one provider-inventory seam 2026-07-25 22:47:12 -07:00
journey.py
kanban.py fix(kanban): cover remaining add_notify_sub call sites for chat_type (#56580) 2026-07-26 13:42:33 -07:00
kanban_db.py fix(kanban): strip stale session routing from dispatched worker env 2026-07-26 16:27:52 -07:00
kanban_decompose.py
kanban_diagnostics.py
kanban_specify.py
kanban_swarm.py
logs.py
main.py fix(update): close the stale-bytecode class with a launch-time checkout-fingerprint sweep 2026-07-27 11:33:40 -07:00
managed_scope.py
managed_uv.py fix(update): refresh stale managed-uv catalog so SQLite runtime repair can succeed 2026-07-26 17:20:27 -07:00
mcp_catalog.py
mcp_config.py feat(mcp): fnmatch glob support in tools.include/exclude filters 2026-07-26 08:26:09 -07:00
mcp_picker.py
mcp_security.py
mcp_startup.py fix(mcp): propagate profile HERMES_HOME override into shared discovery owner; restore stdio startup + WSTransport tests 2026-07-26 14:14:03 -07:00
memory_oauth.py
memory_setup.py fix(update): refresh active memory provider deps after venv rebuild 2026-07-26 19:29:18 -07:00
middleware.py
migrate.py
moa_cmd.py
moa_config.py
model_catalog.py
model_cost_guard.py
model_normalize.py fix(model): don't strip alias-derived prefixes for the custom provider bucket 2026-07-27 19:32:12 +05:30
model_search.py fix(picker): fold live bare k3 wire id into curated kimi-k3 row 2026-07-26 21:22:40 -07:00
model_setup_flows.py
model_switch.py nous portal anthropic wire 2026-07-27 11:53:48 -04:00
models.py fix(picker): fold live bare k3 wire id into curated kimi-k3 row 2026-07-26 21:22:40 -07:00
nous_account.py
nous_auth_keepalive.py
nous_billing.py
nous_subscription.py
onepassword_secrets_cli.py
oneshot.py feat(clarify): add multi-select (checkbox) support to clarify tool 2026-07-26 17:46:55 -07:00
pairing.py
partial_compress.py
pets.py
platforms.py
plugins.py fix subagent lifecycle ownership invariants 2026-07-26 23:27:30 -07:00
plugins_cmd.py fix(update): close the stale-bytecode class with a launch-time checkout-fingerprint sweep 2026-07-27 11:33:40 -07:00
portal_cli.py
profile_describer.py
profile_distribution.py
profiles.py
projects_cmd.py
projects_db.py
prompt_size.py fix(prompt-size): include names-only skills in breakdown 2026-07-26 18:06:21 -07:00
provider_catalog.py
providers.py nous portal anthropic wire 2026-07-27 11:53:48 -04:00
proxy_cli.py
psutil_android.py
pt_input_extras.py
pty_bridge.py
pty_session.py
relaunch.py
route_identity.py
runtime_provider.py nous portal anthropic wire 2026-07-27 11:53:48 -04:00
secret_prompt.py
secrets_cli.py
security_advisories.py
security_audit.py
security_audit_startup.py
send_cmd.py
service_manager.py fix(hermes_cli): drop privileges before clearing s6-log lock 2026-07-27 19:19:01 +05:30
session_export.py
session_export_html.py
session_export_md.py
session_filters.py fix(sessions): preserve recently active sessions during pruning 2026-07-26 19:30:21 -07:00
session_listing.py
session_recap.py
session_recovery.py fix(sessions): verify fully reconstructed recovery 2026-07-26 23:34:29 -07:00
setup.py
setup_hidden_env.py fix(setup): stop asking about self-configuring platform knobs 2026-07-26 08:43:24 -07:00
setup_whatsapp_cloud.py
skills_config.py
skills_hub.py fix(skills): never change a skill's source registry on update 2026-07-26 19:29:56 -07:00
skin_cmd.py
skin_engine.py
slack_cli.py
sqlite_runtime.py
sqlite_safe_read.py fix(sessions): close the snapshot check/use race and guard damaged state_meta 2026-07-25 23:05:30 -07:00
sqlite_util.py
status.py revert: PR #72817 — session activity watchdog, stall notify, compress timeout 2026-07-28 00:15:00 +05:00
stdio.py
suggestions_cmd.py
telegram_managed_bot.py
timeouts.py
tips.py feat: raise default tool-calling iteration limit from 90 to 500 2026-07-26 12:54:45 -07:00
tools_config.py fix(install): clear stale Windows cua lock 2026-07-26 16:01:54 -07:00
toolset_validation.py fix(config): surface invalid platform_toolsets instead of silently dropping tools (#38798) 2026-06-26 14:07:43 +05:30
uninstall.py
urllib_security.py
voice.py
web_git.py
web_server.py fix(model): narrow custom-provider fallback exclusion to real custom: syntax 2026-07-27 19:32:12 +05:30
webhook.py
win_pty_bridge.py
windows_ssh_runtime.py
write_approval_commands.py
xai_retirement.py