HKUDS/nanobot · error · CliAppError

this CLI app uses an unsupported install strategy

Error message

this CLI app uses an unsupported install strategy

What it means

Fallback guard at the end of CliAppService._argv_for_action: the app's strategy field (pip/npm/brew/uv/bundled) matched none of the known values, so no argv builder exists for it. Usually means a malformed or newer-strategy registry entry; raised as CliAppError.

Solutions

  1. Use an app whose registry entry declares a supported strategy (pip, npm, brew, or bundled)
  2. Install the app manually with its documented instructions
Defensive patterns

Strategy: fallback

When it happens

Trigger: Thrown at nanobot/apps/cli/service.py:991 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/5f2d3fd5c3f66379. Report an issue: GitHub.

Appendix: source

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

    ) -> list[str] | None:
        strategy = self._strategy(app)
        if strategy == "pip":
            if action == "install":
                return self._pip_install_argv(app)
            if action == "update":
                return self._pip_install_argv(app, update=True)
            return self._pip_uninstall_argv(app, installed_entry=installed_entry)
        if strategy == "npm":
            return self._npm_argv(app, action)
        if strategy == "brew":
            key = {"install": "install_cmd", "update": "update_cmd", "uninstall": "uninstall_cmd"}[action]
            return self._split_safe_command(app, key, "brew")
        if strategy == "uv":
            key = {"install": "install_cmd", "update": "update_cmd", "uninstall": "uninstall_cmd"}[action]
            return self._split_safe_command(app, key, "uv")
        if strategy == "bundled":
            return None
        raise CliAppError("this CLI app uses an unsupported install strategy")

    def _subprocess_env(self) -> dict[str, str]:
        """Minimal env for CLI app subprocesses — no API keys or secrets.

        Mirrors the shell tool's allowlist so installed apps cannot read
        provider credentials from the parent process environment.
        """
        if sys.platform == "win32":
            sr = os.environ.get("SYSTEMROOT", r"C:\Windows")
            env = {
                "SYSTEMROOT": sr,
                "COMSPEC": os.environ.get("COMSPEC", f"{sr}\\system32\\cmd.exe"),
                "USERPROFILE": os.environ.get("USERPROFILE", ""),
                "HOMEDRIVE": os.environ.get("HOMEDRIVE", "C:"),
                "HOMEPATH": os.environ.get("HOMEPATH", "\\"),
                "TEMP": os.environ.get("TEMP", f"{sr}\\Temp"),
                "TMP": os.environ.get("TMP", f"{sr}\\Temp"),
                "PATHEXT": os.environ.get("PATHEXT", ".COM;.EXE;.BAT;.CMD"),

View on GitHub (pinned to 42f37dc4c0)