langchain-ai/langgraph · error · FileNotFoundError

Could not find ui

Error message

Could not find ui '{ui_name}': {resolved}

What it means

Raised while preparing ui entries for a uv-lock deployment: the ui path resolved relative to the config file does not exist on disk. The UI asset or module file referenced in langgraph.json's 'ui' section is missing or misnamed relative to the config directory.

Solutions

  1. Fix the ui.<name> path in langgraph.json to point at an existing file relative to the config.
  2. Build the UI asset first if it is generated (e.g. dist/index.js).
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at libs/cli/langgraph_cli/uv_lock.py:845 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of langchain-ai/langgraph@38031739e5 (2026-08-26). Data as JSON: /api/errors/52fa4f7d112f9b46. Report an issue: GitHub.

Appendix: source

Thrown at libs/cli/langgraph_cli/uv_lock.py:845

        plan,
        label=label,
    )


def _update_uv_lock_ui_paths(
    config_path: pathlib.Path, config: Config, plan: UvLockPlan
) -> None:
    ui = config.get("ui")
    if not isinstance(ui, dict):
        return

    for ui_name, path_str in ui.items():
        if not isinstance(path_str, str):
            continue

        resolved = (config_path.parent / path_str).resolve()
        if not resolved.exists():
            raise FileNotFoundError(f"Could not find ui '{ui_name}': {resolved}")
        if not resolved.is_file():
            raise IsADirectoryError(f"Ui '{ui_name}' must be a file: {resolved}")

        container_path = _resolve_uv_lock_container_path(resolved, plan)
        if container_path is None:
            copied_dirs = ", ".join(
                package.root.relative_to(plan.project_root).as_posix() or "."
                for package in plan.install_order
            )
            raise click.UsageError(
                f"Ui '{ui_name}' resolves to {resolved}, which is not inside the "
                f"target package '{plan.target.name}' or any of its workspace "
                f"dependencies. Only these directories are copied into the "
                f"container: {copied_dirs}. If this file lives in another "
                f"workspace package, add it as a dependency of "
                f"'{plan.target.name}' with `{{ workspace = true }}` in "
                "[tool.uv.sources]."
            )

View on GitHub (pinned to 38031739e5)