test(cli): reproduce updater executable orphaning - #39482
Open
opencode-agent[bot] wants to merge 1 commit into
Open
test(cli): reproduce updater executable orphaning#39482opencode-agent[bot] wants to merge 1 commit into
opencode-agent[bot] wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a deterministic subprocess regression reproducer for the executable-lifetime precondition behind #32002 and #32464.
The test installs a native executable through the same global Bun package-manager layout used by OpenCode, leaves it running, replaces the installed package, and verifies that:
(deleted)Current V2 calls global npm/pnpm/Bun/Yarn installation from its long-running background service updater every ten minutes, so this is the same inode-orphaning operation performed while OpenCode remains active.
On macOS 26, independent controlled reproductions correlate this orphaned mapping with repeated
vn_getpath failedevents and one unreclaimed 1 KiBdata.kalloc.1024allocation per failure. The exact OpenCode upgrade-under-load reproducer is https://gist.github.com/markjaquith/b6915a8f1b35939af04c166cd01b3b41.Local proof
Checks
bun test test/updater-orphan.test.tsbun typecheckRequested by: @kommander (Sebastian via Slack)