Repository navigation
fix(app): hide sandbox distros from the Add WSL server dialog - #327
Merged
Merged
Conversation
The dialog listed every installed distribution, including the codev-* distros the sandbox provider creates for itself (wslDistroName prefixes every sandbox distro with codev-), each marked "CoDev not installed" with an Install CoDev button. Installing into one would be wrong: a sandbox guest is a minimal image that gets the server bundle bind-mounted at boot and is owned by the sandbox lifecycle. Extend isHiddenDistro to hide the sandbox's reserved codev- namespace the same way it already hides docker-desktop's infrastructure distros. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Problem
The "Add WSL server" dialog (Settings → Servers → + → Add WSL server) lists every installed WSL distribution, including the
codev-*distros the sandbox provider creates for itself —codev-default-sandboxand any user-named sandbox, sincewslDistroNameincodev-sandboxprefixes every sandbox distro withcodev-. Each shows up as "CoDev not installed" with an Install CoDev button.Installing into one would be wrong: a sandbox guest is a minimal image that gets the server bundle bind-mounted at boot and is owned by the sandbox lifecycle — it is not a distro of the user's to run a standalone WSL server in.
Fix
Extend
isHiddenDistroinpackages/app/src/wsl/settings-model.tsto hide the sandbox's reservedcodev-namespace, the same way it already hides Docker Desktop'sdocker-desktop/docker-desktop-datainfrastructure distros. This filters both the installed-distros list and the catalog view (which could never contain one anyway).Validation
docker-desktop,docker-desktop-data,codev-default-sandbox,codev-my-project-1, andUbuntuyields onlyUbuntuas visible/addable/selected.bun test src/wsl/settings-model.test.ts(11 pass) andbun typecheckfrompackages/app.packages/app/src/wsl/is fork-only, so no DIVERGENCES.md row; CHANGELOG.md gets a Sandbox entry.🤖 Generated with Claude Code