{"record":{"id":"63b41de76a6b5acf","repo":"NousResearch/hermes-agent","slug":"could-not-find-the-hermes-cli-under-is-hermes","errorCode":null,"errorMessage":"Could not find the hermes CLI under {}. Is Hermes installed? Re-run the installer to repair the install.","messagePattern":"Could not find the hermes CLI under (.+?)\\. Is Hermes installed\\? Re-run the installer to repair the install\\.","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"apps/bootstrap-installer/src-tauri/src/update.rs","lineNumber":320,"sourceCode":"        target_app_from_args(std::env::args().skip(1))\n    } else {\n        None\n    };\n\n    let hermes = resolve_hermes(&install_root).ok_or_else(|| {\n        let msg = format!(\n            \"Could not find the hermes CLI under {}. Is Hermes installed? \\\n             Re-run the installer to repair the install.\",\n            install_root.display()\n        );\n        emit(\n            &app,\n            BootstrapEvent::Failed {\n                stage: None,\n                error: msg.clone(),\n            },\n        );\n        anyhow!(msg)\n    })?;\n\n    // Synthetic manifest so the existing progress UI renders our stages.\n    emit(\n        &app,\n        BootstrapEvent::Manifest {\n            stages: update_stages(target_app.is_some()),\n            protocol_version: None,\n        },\n    );\n\n    // ---- stage 1: wait for the old desktop to die ------------------------\n    // The desktop exec'd us then called app.exit(), but process teardown is\n    // async on Windows. If it still holds the venv shim, `hermes update`\n    // aborts with exit 2. If it still holds the packaged app.asar,\n    // install.ps1's repair/re-clone path cannot move/remove the install tree.\n    // Give both handles a bounded window to clear. Surfaced as its own stage\n    // (rather than a silent pre-step) so a slow close / force-kill reads as","sourceCodeStart":302,"sourceCodeEnd":338,"githubUrl":"https://github.com/NousResearch/hermes-agent/blob/c896c09c42910c584c4c7d2325b58c14713ea42c/apps/bootstrap-installer/src-tauri/src/update.rs#L302-L338","documentation":"Raised at the start of the update flow: the hermes CLI shim (venv hermes entry) was not found under the computed install root. The entire update — `hermes update` and the desktop rebuild — is driven through that CLI, so its absence means the install is broken or HERMES_HOME points somewhere else; the remedy is to re-run the installer to repair.","triggerScenarios":"HERMES_HOME env changed between install and update so the updater looks in an empty directory; the venv was deleted (partial uninstall, disk cleanup tool); the install never completed (no bootstrap marker/venv); a moved/cloned repo where the install root was never populated.","commonSituations":"User moved ~/.hermes or ran a cleaner app that wiped it; switching profiles so HERMES_HOME points at a fresh dir; a first-run update triggered before bootstrap ever finished; restoring from backup without the venv (venvs are not relocatable).","solutions":["Re-run the bootstrap installer to recreate the venv and CLI shim (the message's intended repair).","Verify the path in the message: does <install_root>/venv/.../hermes exist? If not, the venv is gone.","Make sure HERMES_HOME is the same value the installer used (check ~/.hermes/config.yaml and env).","If the venv exists but at a different location, fix the profile/HERMES_HOME mapping rather than reinstalling."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"use std::path::{Path, PathBuf};\n\nfn venv_hermes(install_root: &Path) -> PathBuf {\n    if cfg!(target_os = \"windows\") {\n        install_root.join(\"venv\").join(\"Scripts\").join(\"hermes.exe\")\n    } else {\n        install_root.join(\"venv\").join(\"bin\").join(\"hermes\")\n    }\n}\n\nfn install_repairable(install_root: &Path) -> bool {\n    let shim = venv_hermes(install_root);\n    shim.is_file() && shim.metadata().map(|m| m.is_file()).unwrap_or(false)\n}\n\nif !install_repairable(&install_root) {\n    eprintln!(\"hermes CLI missing under {} — re-run the installer to repair.\", install_root.display());\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Verify the hermes shim exists under the install root before invoking any update flow.","Keep HERMES_HOME stable between install and update (same profile, same env).","Exclude ~/.hermes from disk cleaners and partial backups that drop the venv."],"tags":["filesystem","update","venv","bootstrap-installer"],"backgroundTag":null,"analyzedSha":"c896c09c42910c584c4c7d2325b58c14713ea42c","analyzedAt":"2026-08-14T17:18:01.089Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}