HKUDS/nanobot · error · CliAppError

install failed

Error message

install failed

What it means

Raised by update when the install subprocess returns non-zero (after any npm ENOTEMPTY retry) — the captured stderr/stdout was empty, so only the generic 'install failed' marker remains. The package was not (re)installed.

Solutions

  1. Run the printed install command manually to see the full error
  2. Check network access and package-manager credentials
  3. Retry after resolving the underlying tool failure
Defensive patterns

Strategy: retry

When it happens

Trigger: Thrown at nanobot/apps/cli/service.py:1212 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of HKUDS/nanobot@42f37dc4c0 (2026-08-26). Data as JSON: /api/errors/2697db4256cc605b. Report an issue: GitHub.

Appendix: source

Thrown at nanobot/apps/cli/service.py:1212

            if detect_cmd and _command_exists(detect_cmd):
                self._record_installed(app)
                return self.payload() | {
                    "last_action": {
                        "ok": True,
                        "message": f"CLI for {app['display_name']} is available.",
                        "installed": True,
                        "verification": ["entry_point_available", "state_recorded"],
                    }
                }
            note = app.get("install_notes") or f"{app['display_name']} is bundled with its parent app."
            raise CliAppError(str(note))
        argv = self._argv_for_action(app, "install")
        assert argv is not None
        result = self._run_argv(argv, timeout=self.runtime.install_timeout)
        if strategy == "npm" and result.returncode != 0:
            result = self._retry_stale_npm_install(app, argv, result)
        if result.returncode != 0:
            raise CliAppError(_truncate(result.stderr or result.stdout or "install failed"), status=500)
        self._record_installed(app)
        return self.payload() | {
            "last_action": {
                "ok": True,
                "message": f"Installed CLI for {app['display_name']}.",
                "installed": True,
                "verification": ["package_manager_ok", "state_recorded", "managed_paths_present"],
            }
        }

    def update(self, name: str) -> dict[str, Any]:
        app = self.get_app(name, force_refresh=True)
        if str(app["name"]) not in self._load_installed():
            raise CliAppError("CLI app is not installed")
        if self._strategy(app) == "bundled":
            self._record_installed(app)
            return self.payload() | {
                "last_action": {

View on GitHub (pinned to 42f37dc4c0)