HKUDS/nanobot · error · TuiUnavailableError

could not install TUI dependencies: {exc}

Error message

could not install TUI dependencies: {exc}

What it means

Error "could not install TUI dependencies: {exc}" thrown in HKUDS/nanobot.

Source

Thrown at nanobot/cli/tui_launcher.py:228

    project_root = project_root.resolve(strict=False)
    source_dir = project_root / "tui"
    if (project_root / "pyproject.toml").is_file() and (source_dir / "package.json").is_file():
        return source_dir
    return None


def _resolve_source_tui_command(source_dir: Path, bun: str) -> list[str]:
    dependency = source_dir / "node_modules" / "@opentui" / "core"
    try:
        install = subprocess.run(
            [bun, "install", "--frozen-lockfile"],
            cwd=source_dir,
            capture_output=True,
            text=True,
            check=False,
        )
    except OSError as exc:
        raise TuiUnavailableError(f"could not install TUI dependencies: {exc}") from exc
    if install.returncode != 0 or not dependency.is_dir():
        detail = (install.stderr or install.stdout).strip().splitlines()
        suffix = f": {detail[-1]}" if detail else ""
        raise TuiUnavailableError(f"could not install TUI dependencies{suffix}")
    executable = named_executable(
        bun,
        name="nanobot-tui",
        directory=get_data_dir() / "run" / "executables",
    )
    return [executable, str(source_dir / "src" / "index.ts")]


def _download_release_tui(asset: str) -> Path | None:
    """Install the complete, version-matched TUI release bundle."""
    if os.environ.get("NANOBOT_TUI_NO_DOWNLOAD") == "1":
        return None
    version = __version__.strip()
    if not version or version.endswith((".dev0", "+dev")):

View on GitHub (pinned to 42f37dc4c0)

When it happens

Trigger: Thrown at nanobot/cli/tui_launcher.py:228 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/9624df6130521d32. Report an issue: GitHub.