← ClaudeAtlas

sandbox-boundarylisted

Your execution sandbox and the user's machine are two different filesystems, and the same file has a different absolute path in each. Catch, mechanically, everything that breaks when an operation crosses that boundary — including when you add a new working directory. Use when: paths or file locations might disagree between environments. Do NOT use when: the question is how to test in their environment, or how to write the script you hand over.
RICK-ORPHEN/agent-discipline-skills · ★ 0 · AI & Automation · score 70
Install: claude install-skill RICK-ORPHEN/agent-discipline-skills
# sandbox-boundary — working across two filesystems ## 0. Why this exists — the damage `git worktree add` was run from the sandbox. Git bakes **the absolute path it can see at that moment** into two files. ``` <worktree>/.git → gitdir: /sessions/<session>/mnt/<folder>/<repo>/.git/worktrees/… <repo>/.git/worktrees/<worktree>/gitdir → /sessions/<session>/mnt/<folder>/<worktree>/.git ``` `/sessions/...` **does not exist on the user's machine.** Running git there gives: ``` fatal: not a git repository: /sessions/…/worktrees/<worktree> ``` Eight commits and 63 files were stacked there, every check went green, and the report said **"the code side is entirely done."** In reality it sat in a place from which not one command worked on the user's machine. The real damage came after. The inability to push was misdiagnosed as "no SSH key", the clipboard was rewritten four times, and several round trips passed before anyone noticed the terminal had no window open. **The cause was a worktree created by me, from the very start, and I kept suspecting the environment instead of my own output.** --- ## 1. Absolute rules ### R1 — Never `git worktree add` from the sandbox Branch inside the existing working tree instead. If you genuinely need a worktree, fix the paths per §2 and **pass the check in §3 before doing anything else.** The same applies to `git clone`, `git submodule`, absolute paths in `ln -s`, handed-over scripts, and paths inside `*.json` configuration. ### R2 — Wr