abhigyanpatwari/GitNexus · error · SandboxError

{label} is unavailable: {root}: {exc}

Error message

{label} is unavailable: {root}: {exc}

What it means

Raised by _validated_runtime_root (runtime_mounts.py:140-144) when lstat() or resolve(strict=True) raises OSError on the candidate path. The label is contextual (e.g. 'pinned GitNexus runtime', 'Compound Engineering plugin source', 'CE plugin snapshot parent'). SandboxError signals containment cannot be established.

Source

Thrown at eval/workflow_bench/runtime_mounts.py:144

    return (snapshot.mount,)


def ce_plugin_dir_for_arm(arm: str, snapshot: CePluginSnapshot | None) -> str | None:
    """Return Claude's fixed in-sandbox plugin path only for CE arms."""

    ce_plugin_mounts_for_arm(arm, snapshot)
    return SANDBOX_CE_PLUGIN if arm in CE_ARMS else None


def _validated_runtime_root(path: Path, *, label: str) -> Path:
    """Return one real directory without accepting any symlink hop."""

    root = path.expanduser().absolute()
    try:
        mode = root.lstat().st_mode
        resolved = root.resolve(strict=True)
    except OSError as exc:
        raise SandboxError(f"{label} is unavailable: {root}: {exc}") from exc
    if stat.S_ISLNK(mode) or not stat.S_ISDIR(mode) or resolved != root:
        raise SandboxError(f"{label} must be a real directory: {root}")
    return root


def _validated_runtime_component(
    root: Path,
    relative: str,
    target: str,
    *,
    directory: bool,
) -> ReadOnlyMount:
    """Validate one direct runtime component before exposing only that path."""

    source = root / relative
    try:
        mode = source.lstat().st_mode
        resolved = source.resolve(strict=True)

View on GitHub (pinned to d540b00184)

Solutions

  1. Confirm the path exists and is readable: `ls -ld <path>`.
  2. Build the runtime: run `npm install && npm run build` in gitnexus/ and gitnexus-shared/.
  3. Fix permissions or re-clone the repo so the component is present.
  4. For CE plugin, point --ce-plugin-dir at the real plugin checkout.
Defensive patterns

Strategy: validation

Validate before calling

from pathlib import Path
p = Path(path).expanduser()
if not p.exists() or not p.is_dir():
    raise SystemExit(f"{label} unavailable or not a directory: {p}")

Type guard

def runtime_root_exists(path: str) -> bool:
    from pathlib import Path
    p = Path(path).expanduser().absolute()
    return p.exists() and p.is_dir()

Prevention

When it happens

Trigger: The gitnexus/, gitnexus-shared/, or plugin dir does not exist; permission denied (EACCES); a broken path component (ENOENT); I/O error reading the inode. Used for the GitNexus runtime roots, the CE plugin source, and the snapshot parent directory.

Common situations: Running the harness from a checkout that lacks gitnexus/dist or gitnexus-shared; pointing --ce-plugin-dir at a missing path; permissions on a shared CI runner; a repo not fully cloned.

Related errors


AI-assisted analysis of abhigyanpatwari/GitNexus@d540b00184 (2026-08-12). Data as JSON: /api/errors/d5e24d0eb64e3800. Report an issue: GitHub.