Skip to content
This repository was archived by the owner on Aug 3, 2026. It is now read-only.

Fix HOSB execution-sandbox end-to-end + rejected-queue GC - #80

Merged
bitzic merged 1 commit into
RalphLabsAI:mainfrom
karpabot:fix/hosb-sandbox-e2e
Jun 29, 2026
Merged

Fix HOSB execution-sandbox end-to-end + rejected-queue GC#80
bitzic merged 1 commit into
RalphLabsAI:mainfrom
karpabot:fix/hosb-sandbox-e2e

Conversation

@karpabot

Copy link
Copy Markdown

What

Makes the HOSB execution-sandbox (op4 RALPH_HOSB=shadow/enforce) run end-to-end, and stops queue/rejected/ from filling the disk.

The sandbox path had never run e2e; under the required userns-remap it failed at every step. Each fix was found bringing it up on the live validator box.

Fixes

  • Dockerfile.sandbox: COPY miner/validator/__init__ imports miner.submit, so the build-time import verify failed.
  • container_argv (_hosb_sandbox_nlls + _sandboxed_hidden_eval): drop the duplicated python -m validator.sandbox_eval prefix; the image ENTRYPOINT already runs it, so args were doubled and argv[1] became "python" (rc=3).
  • userns tempdir perms: chmod the grid/out mkdtemp dirs (0700 root) so the remapped non-root container can read /grid + write /out.
  • TMPDIR: point at /scratch (the tmpfs root); /scratch/tmp is never created → "no usable temporary directory" (rc=2).
  • queue GC: archive_bundle removes a rejected bundle's training/ checkpoint on archive (terminal + recorded in hf_state; manifests kept). RALPH_QUEUE_GC_REJECTED=0 to opt out. The queue had grown to 51G (100% full).

Verification

End-to-end on the live king bundle through the hardened container: val_bpb 1.2112, benchmark 0.975 (30s). Validator now runs RALPH_HOSB=shadow cleanly.

🤖 Generated with Claude Code

- Dockerfile.sandbox: COPY miner/ (validator/__init__ imports miner.submit)
- container_argv: drop dup ENTRYPOINT prefix in both sandbox callers
- _hosb_sandbox_nlls: chmod grid/out tempdirs for the userns-remap container
- build_container_env: TMPDIR=/scratch (tmpfs root; /scratch/tmp absent)
- archive_bundle: GC rejected checkpoints (RALPH_QUEUE_GC_REJECTED), keep manifests

Verified e2e on the live king bundle: val_bpb 1.2112, benchmark 0.975.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@bitzic
bitzic merged commit 71c2d8e into RalphLabsAI:main Jun 29, 2026
4 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants