Agent Sandbox Registry

agent-sandbox

Decision: Open-source hygiene sweep and check-no-local-paths guard

无中文版

.agents/notes/implemented/process/2026-10-12-open-source-hygiene.md

Decision: Open-source hygiene sweep and check-no-local-paths guard

Status: implemented

Problem

Before the cli repository is published, files inherited from the original single repository still carried developer-machine specifics: an absolute home-directory path used as a working directory, .venv/bin/python assumptions, a personal ACR namespace and fixed e2e tags in deploy scripts and .env.example, agent scratch locations under the system temp directory in docs/PORTING.md, a personal home directory in sample command output, and real sandbox / template identifiers captured in the e2e workflow guide.

Decision

  1. Fix each finding the way a public-repo maintainer would:
  2. Scripts and benchmarks resolve the repo root from their own location ($(dirname "${BASH_SOURCE[0]}")/.., import.meta.url), never from a fixed path.
  3. The abx executable comes from PATH, overridable with ABX_BIN (benchmarks/bench_cli_startup.mjs, scripts/*.sh).
  4. scripts/build_hermes.sh, deploy_all_templates.sh, deploy_remaining.sh: ACR_NAMESPACE is required (no personal default), TAG defaults to dev, REGION defaults to cn-hangzhou, DOCKER_PLATFORM defaults to linux/amd64 (sandbox runtime architecture), result summaries go to a mktemp file (RESULTS_FILE overrides) instead of fixed temp-directory file names, the wheel is the newest python-sdk/dist/agent_sandbox-*.whl (WHEEL overrides).
  5. .env.example: ACR_NAMESPACE=<your-namespace>.
  6. docs/PORTING.md: scratch paths replaced by $ORIG_REPO / $ORACLE_VENV.
  7. Docs: user-home absolute paths to .abx/ and .cursor/mcp.json became ~/...; real sandbox UUID and template IDs in e2e-template-workflow.md (en/zh) became placeholders.
  8. Ignored .agents/evidence logs scrubbed of local file URLs under user homes and agent-cache paths (they are gitignored today but would leak if un-ignored).
  9. Add a regression guard: scripts/check-no-local-paths.sh (bash + grep only, no rg) scans every tracked or untracked-but-not-ignored file for user-home paths, Windows user paths, Documents/Qoder / chat-N project directories, .venv/bin|Scripts/, agent scratch locations, the personal ACR namespace / fixed e2e tag, and AccessKey / API-key / token / private-key shaped strings (values are never echoed). Legitimate matches go into scripts/local-paths.allowlist (<path-glob>[|<regex>], narrow entries with a justification).
  10. Wire it in: npm run check:hygiene, make hygiene (also part of make ci), and a step in the lint job of .github/workflows/ci.yml.

Rationale

Known gaps