fix(launcher): install via explicit --python, skipping uv's managed-Python junction (Windows/OneDrive 448)#326
Merged
Conversation
…ython junction The Windows/OneDrive first-run failure (os error 448, "untrusted mount point") comes from uv creating the managed-Python *minor-version directory junction*. OneDrive's cloud-filter driver (cldflt) blocks that junction creation on a freshly-created folder tree; it is deterministic on a clean machine, so the retry added in #325 cannot help (every attempt hits the same blocked junction). uv has no flag to skip the junction. Fix: don't let uv do a managed-Python *install* for the tool venv at all. We still run `uv python install` to download+extract the interpreter, but we treat a nonzero exit as success as long as the interpreter landed on disk (the junction is the only thing that fails, and we don't need it). We then point `uv tool install` at that interpreter via an explicit `--python <path>` — with UV_PYTHON_INSTALL_DIR unset, so uv treats it as an external interpreter and never attempts the junction. No junction is created, so the 448 cannot occur, regardless of timing or OneDrive state. Verified by hand on the affected machine. - uvEnv() no longer sets UV_PYTHON_INSTALL_DIR; ensurePython sets it only for the download step. uv's python-install output is captured and surfaced only if no usable interpreter is found, so the harmless 448 isn't shown. - Removes the now-ineffective retry machinery (withRetry/runUVRetry) from #325. - Keeps --no-bin (no python shim in ~/.local/bin) and #324's macOS Xcode warning. - Adds a unit test for findExtractedPython; updates the uvEnv test for the new contract. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
lstein
added a commit
that referenced
this pull request
Jun 9, 2026
…rive, macOS) Add a 1.1.0 release-note bullet for the launcher install-reliability work landed after the notes were first drafted: the Windows/OneDrive 'untrusted mount point' first-run fix (#326) and the macOS Xcode Command Line Tools prompt guidance (#324). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
lstein
added a commit
that referenced
this pull request
Jun 9, 2026
) * chore(release): bump version to 1.1.0 Go directly to 1.1.0 (skipping 1.0.6 and 1.1.0rc1). Since 1.0.5 there have been 22 features and no breaking changes, including the signed uv-bootstrap desktop launcher (#300), UMAP cluster auto-labeling (#234), per-device UI preferences (#284), Move-to-Trash deletion (#273), and Python 3.14 support (#258) — a minor bump, not a patch. Version is single-sourced here (get_version() in args.py reads importlib.metadata). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * docs(release): add 1.1.0 release notes Add docs/release-notes.md (changelog-style, newest version first) summarizing the 1.1.0 changes since 1.0.5, grouped by theme. Wire it into the mkdocs nav. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * docs(release): note first-run install reliability fixes (Windows/OneDrive, macOS) Add a 1.1.0 release-note bullet for the launcher install-reliability work landed after the notes were first drafted: the Windows/OneDrive 'untrusted mount point' first-run fix (#326) and the macOS Xcode Command Line Tools prompt guidance (#324). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> * docs: remove extraneous claude brags --------- Co-authored-by: Claude Opus 4.8 (1M context) <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
On Windows with OneDrive Files-On-Demand, the launcher's first-run install aborts with:
After extensive isolation on the affected machine, this is deterministic on a clean machine (not the transient race #325 assumed): OneDrive's cloud-filter driver
cldfltblocks uv's creation of the managed-Python minor-version directory junction on a freshly-created folder tree. The retry from #325 can't help — every attempt hits the same blocked junction — and uv has no flag to skip it (ensure_minor_version_linkis unconditional/fatal in uv's source).Fix
Stop letting uv do a managed-Python install for the tool venv. We still run
uv python installto download + extract the interpreter, but treat a nonzero exit as success as long as a usable interpreter landed on disk — the junction is the only thing that fails, and we don't need it. We then pointuv tool installat that interpreter via an explicit--python <path>, withUV_PYTHON_INSTALL_DIRunset, so uv treats it as an external interpreter and never attempts the junction. No junction is created → the 448 cannot occur, regardless of timing or OneDrive state.This is exactly the sequence I verified by hand on the affected machine (
uv tool install photomapai --python <extracted python.exe> --torch-backend auto, noUV_PYTHON_INSTALL_DIR) — it installed the full GPU build cleanly.Details
uvEnv()no longer setsUV_PYTHON_INSTALL_DIR;ensurePython()sets it only for the download step. uv's python-install output is captured and surfaced only if no usable interpreter is found, so the harmless 448 isn't shown to the user.withRetry/runUVRetry) added in fix(launcher): retry uv install steps to survive transient first-run 448 (Windows/OneDrive) #325.--no-bin(nopython3.12shim in~/.local/bin) and fix(launcher): warn about macOS Xcode CLT prompt instead of forcing managed Python #324's macOS Xcode-CLT warning.findExtractedPython;uvEnvtest updated for the new contract (assertsUV_PYTHON_INSTALL_DIRis not set).Tests
go build,go vet,go test,gofmt -lall clean.Validation plan
Deploy this branch's launcher and run it on a virgin Windows + OneDrive machine (the exact first-run condition that triggered the 448). Expected: installs cleanly with no 448, no retry pauses.
🤖 Generated with Claude Code