Skip to content

sdk-toolchain: SDK-IN-USE check, and SHARE-HELD below the top - #6451

Merged
gafferongames merged 3 commits into
mainfrom
fix/sdk-in-use-and-deeper-share-held
Nov 17, 2026
Merged

gafferongames merged 3 commits into
mainfrom
fix/sdk-in-use-and-deeper-share-held

Conversation

@rowan-claude

Copy link
Copy Markdown
Collaborator

On amd-1 (2026-11-13), the shared-SDK switch deleted the old ~/sdk while TLC's java was running from it. The stable toolchain that only the old rustup held was also lost, because SHARE-HELD compared the top level only.

  • in-use.yml: before the move and again before the delete, the run scans /proc. For each process it checks the executable, working directory, open files and mapped files under the directory. If any match, the run fails with SDK-TOOLCHAIN SDK-IN-USE and names the processes. It never stops them.
  • SHARE-HELD: now compares two levels down, plus rustup-/toolchains, rustup-/cargo/bin, opam//lib and opam//bin. Each path is named once, at its highest missing level, and dl/ is skipped.
  • Tests and README are updated.

Testing:

  • I ran the SHARE-HELD loop on a fake tree. It named handmade, .hidden, a toolchain, a cargo tool and an opam package, and exited 0.
  • I ran the in-use scan read-only on amd-1 against /opt/nova/sdk. It listed the java and dotnet processes and exited 0.

This PR is not to be run on any host until it is released.

🤖 Generated with Claude Code

rowan-claude added a commit that referenced this pull request Nov 13, 2026
… top-level links, climbs past dangling ones; functional tests run both scripts

Cold reader findings on #6451: /proc names resolved paths, so a home under a
linked /home was missed; a top-level link pulled another version's tree into the
comparison; a dangling link in the shared SDK hid what was below it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
rowan-claude added a commit that referenced this pull request Nov 13, 2026
…n themselves, skips a top-level dl, and takes names starting with a dash

Second cold reader on #6451: a shared switch without lib hid every package
below it, since the climb stopped there and the directory itself was never
listed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
rowan-claude and others added 3 commits November 17, 2026 08:21
…re SHARE-HELD below the top

amd-1, 2026-11-13: the old ~/sdk was deleted while TLC's java ran from it, and
a stable toolchain only the old rustup held was lost because SHARE-HELD compared
the top level only. Now the run fails naming the processes (SDK-IN-USE) before
the move and before the delete, and never stops them; SHARE-HELD compares two
levels down and into rustup toolchains, cargo tools and opam packages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… top-level links, climbs past dangling ones; functional tests run both scripts

Cold reader findings on #6451: /proc names resolved paths, so a home under a
linked /home was missed; a top-level link pulled another version's tree into the
comparison; a dangling link in the shared SDK hid what was below it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…n themselves, skips a top-level dl, and takes names starting with a dash

Second cold reader on #6451: a shared switch without lib hid every package
below it, since the climb stopped there and the directory itself was never
listed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@gafferongames
gafferongames force-pushed the fix/sdk-in-use-and-deeper-share-held branch from d83863b to ed68fc7 Compare November 17, 2026 13:29
@gafferongames
gafferongames merged commit fb748cc into main Nov 17, 2026
13 checks passed
gafferongames added a commit that referenced this pull request Nov 17, 2026
Forward-merge stable v2.0.74 (#6483, #6451, #6455, #6481, and docs pin)
onto v3/main, retaining both tcp:2222 (Windows out-of-band OpenSSH) and
tcp:7680 (nova-reserve server) in tailscale-acl.json.

Author: Emma Antigravity
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants