{"record":{"id":"8e676fd800515d29","repo":"jdx/mise","slug":"name-is-not-an-active-installed-tool-or-one-of","errorCode":null,"errorMessage":"{name} is not an active, installed tool or one of their executables","messagePattern":"(.+?) is not an active, installed tool or one of their executables","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/packslip.rs","lineNumber":1345,"sourceCode":"}\n\n/// The active, installed tool called `name`, or the one providing an\n/// executable called `name`.\nasync fn find_tool(\n    config: &Arc<Config>,\n    ts: &Toolset,\n    name: &str,\n) -> Result<(Arc<dyn Backend>, ToolVersion)> {\n    if let Some(found) = ts.which(config, name).await {\n        return Ok(found);\n    }\n    let by_name = ts\n        .list_current_installed_versions(config)\n        .into_iter()\n        .find(|(b, _)| b.ba().short == name || b.tool_name() == name || b.id() == name);\n    match by_name {\n        Some(found) => Ok(found),\n        None => bail!(\"{name} is not an active, installed tool or one of their executables\"),\n    }\n}\n\n/// Run one of the tool's own executables and return what it printed.\nasync fn run_tool(\n    config: &Arc<Config>,\n    backend: &Arc<dyn Backend>,\n    tv: &ToolVersion,\n    argv: &[String],\n    env: &BTreeMap<String, String>,\n) -> Result<String> {\n    let Some((program, args)) = argv.split_first() else {\n        bail!(\"an exec entry with no command\");\n    };\n    let Some(path) = backend.which(config, tv, program).await? else {\n        bail!(\"{} has no executable called {program}\", tv.style());\n    };\n    run_resource_command(","sourceCodeStart":1327,"sourceCodeEnd":1363,"githubUrl":"https://github.com/jdx/mise/blob/533346cc374382b41ec5ff70536252b2e96e725c/src/packslip.rs#L1327-L1363","documentation":"find_tool looks up a backend/version pair among the currently active, installed tool versions by short name, tool name, or id. When nothing matches, it bails with this error, since completion_script needs an installed tool to run its own executables.","triggerScenarios":"completion_script is asked to derive completions from a tool whose name does not match any entry returned by list_current_installed_versions — the tool is not installed, not active in this toolset, or the name given is an executable alias rather than a known tool id.","commonSituations":"Running completion generation before `mise install`, referencing a tool only present in another environment, misspelling the tool name, using a binary name that does not equal the tool's short name or id.","solutions":["Install the tool first (mise install <name>) and ensure it is active in the current toolset","Use the exact tool name or id as shown by `mise ls --current`","Check spelling/case of the tool name","Verify you are in a project whose mise.toml includes the tool"],"exampleFix":"// before\n// mise packslip completions unknowncli\n// after\n// mise install usage && mise packslip completions usage  # or the correct installed tool name","handlingStrategy":"type-guard","validationCode":"const installed = ts.listCurrentInstalledVersions(config).map(([b]) => b.toolName());\nif (!installed.includes(name)) throw new Error(`install ${name} first`);","typeGuard":"const isInstalledTool = (name: string) => ts.listCurrentInstalledVersions(config).some(([b]) => b.ba().short === name || b.toolName() === name || b.id() === name);","tryCatchPattern":"try { const found = await findTool(config, ts, name) } catch (e) { if (/is not an active, installed tool/.test(e.message)) { await installTool(name); } else { throw e; } }","preventionTips":["Run `mise install` before generating completions","Match the tool name/id exactly as listed by `mise ls --current`","Keep the tool in the active toolset of your project","Don't assume executable names equal tool names"],"tags":["packslip","toolset","completion","tool-not-installed"],"backgroundTag":"resource-not-found","analyzedSha":"533346cc374382b41ec5ff70536252b2e96e725c","analyzedAt":"2026-09-17T13:35:38.149Z","contentChangedAt":"2026-09-17T13:35:38.149Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}