abhigyanpatwari/GitNexus · error · SandboxError

pinned GitNexus runtime version drifted: expected {PINNED_GI

Error message

pinned GitNexus runtime version drifted: expected {PINNED_GITNEXUS_VERSION}, got {package.get('version')!r}

What it means

The harness pins benchmark reproducibility to PINNED_GITNEXUS_VERSION (currently "1.6.9"). It reads gitnexus/package.json and compares the version field; any mismatch aborts the run. This guarantees every operator is benchmarking exactly the same runtime.

Source

Thrown at eval/workflow_bench/runtime_mounts.py:237

        ),
        _validated_runtime_component(
            runtime,
            "hooks/claude",
            f"{SANDBOX_GITNEXUS}/hooks/claude",
            directory=True,
        ),
    )

    entrypoint = mounts[0].source / "cli" / "index.js"
    try:
        entrypoint_mode = entrypoint.lstat().st_mode
        package = json.loads(mounts[1].source.read_text())
    except (OSError, json.JSONDecodeError) as exc:
        raise SandboxError(f"pinned GitNexus runtime metadata is invalid: {exc}") from exc
    if stat.S_ISLNK(entrypoint_mode) or not stat.S_ISREG(entrypoint_mode):
        raise SandboxError(f"pinned GitNexus runtime entrypoint must be regular and non-symlink: {entrypoint}")
    if package.get("version") != PINNED_GITNEXUS_VERSION:
        raise SandboxError(
            "pinned GitNexus runtime version drifted: "
            f"expected {PINNED_GITNEXUS_VERSION}, got {package.get('version')!r}"
        )

    linked_shared = mounts[2].source / "gitnexus-shared"
    if not linked_shared.is_symlink() or linked_shared.resolve(strict=True) != shared:
        raise SandboxError("pinned GitNexus runtime has an unexpected gitnexus-shared dependency")
    try:
        shared_package = json.loads(mounts[5].source.read_text())
    except (OSError, json.JSONDecodeError) as exc:
        raise SandboxError(f"pinned GitNexus shared runtime metadata is invalid: {exc}") from exc
    if shared_package.get("name") != "gitnexus-shared":
        raise SandboxError("pinned GitNexus shared runtime has an unexpected package identity")
    return mounts


def validate_ce_plugin_inputs(
    arms: Sequence[str],

View on GitHub (pinned to d540b00184)

Solutions

  1. Check out the tag or commit whose gitnexus/package.json version equals PINNED_GITNEXUS_VERSION.
  2. If you are intentionally rebaselining, update PINNED_GITNEXUS_VERSION in eval/workflow_bench/runtime_mounts.py to match package.json and re-run.

Example fix

// before
PINNED_GITNEXUS_VERSION = "1.6.9"
// after (only when rebaselining the harness)
PINNED_GITNEXUS_VERSION = "1.7.0"
Defensive patterns

Strategy: validation

Validate before calling

import json
from pathlib import Path
from eval.workflow_bench.runtime_mounts import PINNED_GITNEXUS_VERSION

def runtime_version_matches(root: Path) -> bool:
    try:
        return json.loads((root / "package.json").read_text()).get("version") == PINNED_GITNEXUS_VERSION
    except (OSError, json.JSONDecodeError):
        return False

Try / catch

try:
    mounts = trusted_gitnexus_runtime_mounts()
except SandboxError as exc:
    if "version drifted" in str(exc):
        # either checkout the pinned tag or update PINNED_GITNEXUS_VERSION intentionally
        ...
    raise

Prevention

When it happens

Trigger: The local gitnexus/package.json reports a different version than PINNED_GITNEXUS_VERSION — e.g., after `npm version patch`, switching to a release branch, or pulling a newer main.

Common situations: Operator bumped the package version locally; the constant was not updated after a release; running the benchmark against an unreleased checkout.

Related errors


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