abhigyanpatwari/GitNexus · error · SandboxError
results directory is unavailable: {root}: {exc}
Error message
results directory is unavailable: {root}: {exc} What it means
_real_results_root lstat's the results directory; an OSError (ENOENT, EACCES, ELOOP, stale NFS handle) becomes SandboxError. The harness will not fall back to a default results dir — a missing root means there is no evidence to read, and silently skipping it would let the proposer run without ground truth.
Source
Thrown at eval/workflow_bench/evolve.py:293
# ─── Proposer session ────────────────────────────────────────────────────────
def _bounded_regular_text(path: Path, limit: int = MAX_EVIDENCE_FILE_BYTES) -> str:
mode = path.lstat().st_mode
if path.is_symlink() or not stat.S_ISREG(mode):
raise SandboxError(f"evidence source must be a regular non-symlink file: {path}")
with path.open("rb") as handle:
if path.stat().st_size > limit:
handle.seek(-limit, os.SEEK_END)
return handle.read(limit).decode(errors="replace")
def _real_results_root(results_dir: Path) -> Path:
root = results_dir.expanduser().absolute()
try:
metadata = root.lstat()
except OSError as exc:
raise SandboxError(f"results directory is unavailable: {root}: {exc}") from exc
if stat.S_ISLNK(metadata.st_mode) or not stat.S_ISDIR(metadata.st_mode):
raise SandboxError(f"results directory must be a real non-symlink directory: {root}")
if root.resolve(strict=True) != root:
raise SandboxError(f"results directory must not traverse symlinks: {root}")
return root
def _results_artifact_path(root: Path, relative_value: str, *, transcript: bool) -> Path:
relative = PurePosixPath(relative_value)
expected_parts = 2 if transcript else 1
if (
relative.is_absolute()
or len(relative.parts) != expected_parts
or any(part in {"", ".", ".."} for part in relative.parts)
or (transcript and relative.parts[0] != "transcripts")
):
raise SandboxError(f"unsafe results artifact path: {relative_value!r}")
current = rootView on GitHub (pinned to d540b00184)
Solutions
- Confirm the path exists and is stat-able: `ls -ld <results_dir>` as the same user the harness runs as.
- Pass an absolute path; relative paths are resolved against the harness cwd, which may surprise you.
- If this is genuinely the first generation, pass results_dir=None instead of a non-existent path.
Example fix
# before
proposer_evidence_entries(results_dir=Path("results/"), ...) # does not exist yet
# after: first generation has no prior results
proposer_evidence_entries(results_dir=None, ...)
# or, for a real dir
results_dir = Path("/abs/path/to/results").resolve()
assert results_dir.is_dir(), results_dir Defensive patterns
Strategy: validation
Validate before calling
from pathlib import Path
def results_dir_available(path: Path) -> bool:
try:
path.expanduser().absolute().lstat()
return True
except OSError:
return False
# pass None for first generation, else a stat-able dir
if results_dir is not None and not results_dir_available(results_dir):
raise FileNotFoundError(f"results dir missing/inaccessible: {results_dir}") Prevention
- Pass results_dir=None on the first generation instead of a non-existent path.
- Always pass an absolute path; relative paths resolve against the harness cwd.
- Verify `ls -ld <dir>` as the harness user before starting a generation.
When it happens
Trigger: --results-dir points at a path that does not exist; the harness lacks read/execute permission on a parent; an NFS/FUSE mount is hung or stale; a typo in the path.
Common situations: First run before any results exist; results dir on an unmounted volume; CI running as a user without access to the results path; relative path resolved from the wrong cwd.
Related errors
- evidence source must be a regular non-symlink file: {path}
- results directory must be a real non-symlink directory: {roo
- results directory must not traverse symlinks: {root}
- results artifact parent is unavailable: {current}: {exc}
- transcript artifact is unavailable: {path}: {exc}
AI-assisted analysis of abhigyanpatwari/GitNexus@d540b00184 (2026-08-12).
Data as JSON: /api/errors/3a4b0e4823d7ce42.
Report an issue: GitHub.