{"record":{"id":"901106e1acee6f33","repo":"jdx/mise","slug":"execute-external-command-not-implemented-for","errorCode":null,"errorMessage":"execute_external_command not implemented for {}","messagePattern":"execute_external_command not implemented for (.+?)","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/plugins/mod.rs","lineNumber":372,"sourceCode":"        _dry_run: bool,\n    ) -> eyre::Result<()> {\n        Ok(())\n    }\n    async fn update(&self, _pr: &dyn SingleReport, _gitref: Option<String>) -> eyre::Result<()> {\n        Ok(())\n    }\n    async fn uninstall(&self, _pr: &dyn SingleReport) -> eyre::Result<()> {\n        Ok(())\n    }\n    async fn install(&self, _config: &Arc<Config>, _pr: &dyn SingleReport) -> eyre::Result<()> {\n        Ok(())\n    }\n    fn external_commands(&self) -> eyre::Result<Vec<ExternalCommand>> {\n        Ok(vec![])\n    }\n    #[cfg_attr(coverage_nightly, coverage(off))]\n    fn execute_external_command(&self, _command: &str, _args: Vec<String>) -> eyre::Result<()> {\n        unimplemented!(\n            \"execute_external_command not implemented for {}\",\n            self.name()\n        )\n    }\n}\n\nimpl Ord for PluginEnum {\n    fn cmp(&self, other: &Self) -> std::cmp::Ordering {\n        self.name().cmp(other.name())\n    }\n}\n\nimpl PartialOrd for PluginEnum {\n    fn partial_cmp(&self, other: &Self) -> Option<std::cmp::Ordering> {\n        Some(self.cmp(other))\n    }\n}\n","sourceCodeStart":354,"sourceCodeEnd":390,"githubUrl":"https://github.com/jdx/mise/blob/afd2eddd3a50c16190efc1c7e94404b48f72af57/src/plugins/mod.rs#L354-L390","documentation":"mise plugins expose custom CLI subcommands via `external_commands`; the default trait implementation returns an empty command list but a non-default `execute_external_command` that always panics with `unimplemented!`. Hitting this means the plugin's `external_commands()` advertised a command (or a caller invoked it directly) without the plugin providing a real execution implementation. It is a plugin-implementation bug or a race where the command list and dispatcher disagree.","triggerScenarios":"Invoking `mise <plugin> <command>` (e.g. `mise erlang something`) against a plugin whose backend trait impl does not override `execute_external_command`, or internal dispatch calling `execute_external_command` on a plugin that never advertised support.","commonSituations":"Running plugin-specific subcommands on core/builtin plugins that don't implement them, after a mise upgrade changed the plugin API surface, or with third-party plugins that advertise commands but inherit the default executor.","solutions":["Use a supported command: run `mise <plugin> --help` or check the plugin's listed external commands before invoking.","Update mise (`mise self-update`) — the plugin may have gained an implementation.","Reinstall/update the plugin itself (e.g. `mise plugin update <name>`) so its command advertisement matches its executor.","If it's your own plugin, override `execute_external_command` (and keep `external_commands()` in sync) in the trait impl."],"exampleFix":"// before\nfn external_commands(&self) -> eyre::Result<Vec<ExternalCommand>> {\n    Ok(vec![ExternalCommand { name: \"foo\", .. }])\n}\n// execute_external_command left as default unimplemented!()\n\n// after\nfn execute_external_command(&self, command: &str, args: Vec<String>) -> eyre::Result<()> {\n    match command {\n        \"foo\" => self.run_foo(args),\n        _ => unreachable!(\"only advertised commands reach here\"),\n    }\n}","handlingStrategy":"validation","validationCode":"# Shell: verify the command is advertised before invoking\nmise <plugin> --help 2>/dev/null | grep -q \"<command>\" || { echo \"command not supported by plugin\"; exit 1; }","typeGuard":null,"tryCatchPattern":"// Rust: guard against plugins without external command support\nmatch plugin.external_commands() {\n    Ok(cmds) if cmds.iter().any(|c| c.name == command) => plugin.execute_external_command(command, args)?,\n    _ => eyre::bail!(\"plugin {} does not support command {}\", plugin.name(), command),\n}","preventionTips":["Check `mise <plugin> --help` for supported subcommands before running them.","Keep mise and plugins updated so implementations match advertised commands.","Plugin authors: only list commands in external_commands() that execute_external_command actually handles.","Report third-party plugins that advertise unimplemented commands upstream."],"tags":["mise","plugins","unimplemented","cli"],"backgroundTag":"method-not-implemented","analyzedSha":"afd2eddd3a50c16190efc1c7e94404b48f72af57","analyzedAt":"2026-09-09T01:38:25.179Z","contentChangedAt":"2026-09-09T01:38:25.179Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}