{"record":{"id":"1d9ca55f872dab29","repo":"HKUDS/nanobot","slug":"unsupported-expected-command","errorCode":null,"errorMessage":"unsupported {expected} command","messagePattern":"unsupported (.+?) command","errorType":"exception","errorClass":"CliAppError","httpStatus":null,"severity":"error","filePath":"nanobot/apps/cli/service.py","lineNumber":965,"sourceCode":"        output = f\"{result.stderr}\\n{result.stdout}\"\n        if \"ENOTEMPTY\" not in output or \"rename\" not in output:\n            return result\n        if not self._cleanup_stale_npm_install(app):\n            return result\n        return self._run_argv(argv, timeout=self.runtime.install_timeout)\n\n    def _split_safe_command(self, app: dict[str, Any], key: str, expected: str) -> list[str]:\n        command = str(app.get(key) or \"\")\n        if not command:\n            raise CliAppError(f\"no {key} is defined for {app['name']}\")\n        if _has_shell_meta(command):\n            raise CliAppError(\"script-style install commands are disabled in this MVP\")\n        try:\n            argv = shlex.split(command)\n        except ValueError as exc:\n            raise CliAppError(f\"invalid command: {exc}\") from exc\n        if not argv or argv[0] != expected:\n            raise CliAppError(f\"unsupported {expected} command\")\n        return argv\n\n    def _argv_for_action(\n        self,\n        app: dict[str, Any],\n        action: str,\n        installed_entry: dict[str, Any] | None = None,\n    ) -> list[str] | None:\n        strategy = self._strategy(app)\n        if strategy == \"pip\":\n            if action == \"install\":\n                return self._pip_install_argv(app)\n            if action == \"update\":\n                return self._pip_install_argv(app, update=True)\n            return self._pip_uninstall_argv(app, installed_entry=installed_entry)\n        if strategy == \"npm\":\n            return self._npm_argv(app, action)\n        if strategy == \"brew\":","sourceCodeStart":947,"sourceCodeEnd":983,"githubUrl":"https://github.com/HKUDS/nanobot/blob/42f37dc4c0e409eac7818a82d165c5f2757bc075/nanobot/apps/cli/service.py#L947-L983","documentation":"Error \"unsupported {expected} command\" thrown in HKUDS/nanobot.","triggerScenarios":"Thrown at nanobot/apps/cli/service.py:965 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"42f37dc4c0e409eac7818a82d165c5f2757bc075","analyzedAt":"2026-08-26T00:18:52.276Z","schemaVersion":2},"datasetVersion":"2026-08-26T04:18:47.238Z"}