Repository navigation
Fix the desktop clean-machine CI: asset patterns and the retired #7547 pins - #8026
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 473196df23
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| # are gone. This extra assertion is still Windows-only because the app reads the | ||
| # same default root it wrote there |
There was a problem hiding this comment.
Require a ready disposition on macOS and Linux
When a post-#7547 bundle installs a working Python/torch environment but the desktop preflight regresses to NotInstalled, both POSIX jobs still pass: the app remains alive waiting on the Install screen, and their log checks accept any desktop_preflight completed disposition= value. Keeping the ready assertion Windows-only is not justified by the install root—the cross-platform preflight explicitly removes UNSLOTH_STUDIO_HOME and uses the legacy root (studio/src-tauri/src/preflight/managed.rs:317-320). Now that this commit removes the early pin exits, apply the same ready-disposition criterion to macOS and Linux so these jobs cannot go green without recognizing the environment they just built.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Correct, and the source citation is the part that settles it. Fixed in 60a7061.
I checked preflight/managed.rs rather than taking it on trust:
// Tauri uses the legacy root regardless of UNSLOTH_STUDIO_HOME / STUDIO_HOME;
// probe subprocesses must follow the same isolation as process.rs.
cmd.env_remove("UNSLOTH_STUDIO_HOME");
cmd.env_remove("STUDIO_HOME");Unconditional, not under a cfg(windows). So all three platforms read the same root and the install-root rationale for keeping the assertion Windows-only does not hold. Worse, I restated that rationale in this PR's own comment edit while it was already wrong.
The hole you describe is the real cost: a post-#7547 bundle can install a working venv and still have preflight regress to NotInstalled, and the app then sits on the Install screen -- alive, log written, disposition recorded, nothing it just built recognised. macOS and Linux accepted exactly that, and it matters more now that the installer step no longer stops short of the launch.
Both POSIX legs now collect every recorded disposition and require one of ManagedReady / OwnedReady / AttachedReady, matching Windows.
Checked this does not turn a green leg red before pushing -- all four staging legs record ManagedReady today:
desktop-linux-appimage disposition=ManagedReady
desktop-linux-deb disposition=ManagedReady
desktop-macos-macos-26 disposition=ManagedReady
desktop-windows disposition=ManagedReady
So this tightens the bar without changing any current outcome, which is the right time to tighten it.
| echo "::notice::known pre-#7547 outcome: the shipped bundle's install.sh stopped on the Xcode CLT gate and exited 1. Not a regression here; the next desktop release retires this pin." | ||
| exit 0 | ||
| fi | ||
| [ "$rc" -eq 0 ] || { |
There was a problem hiding this comment.
Update the dispatch default when retiring the pins
When this workflow is manually dispatched without overriding release_tag, it still selects desktop-v0.1.50-beta at line 35. The removed pin documents that this bundle predates #7547 and therefore exits 1 at the macOS CLT gate (and 2 at the Linux optional-package handshake), so this new unconditional zero-exit requirement makes all four POSIX jobs fail for the workflow's default input. Clear the default so dispatches resolve the newest release, or advance it to a post-#7547 tag when retiring these expected outcomes.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Genuine. Fixed in 60a7061.
desktop-v0.1.50-beta is precisely the bundle the retired pins were written for, so with them gone a dispatch that took the default would fail all four POSIX legs at the installer step -- on a bundle nobody meant to test, and with an error that looks like a product regression.
Cleared the default rather than advancing it to a post-#7547 tag. Any pinned tag is an immutable fixture that goes stale the moment the next release is cut, and the workflow already documents that reasoning for the schedule:
Empty unless dispatched: a pinned tag is an immutable fixture, so a nightly against it could never catch a newly published broken bundle.
That argument does not stop being true for a manual dispatch. Empty falls through to the same newest-desktop-v* resolution, and release_tag is still there for anyone who wants to aim at a specific bundle deliberately.
Staging resultsValidated on
Both fixes do what they were meant to. The downloads succeed on macOS and Windows, which were the two legs dying at What this exposesThe Linux legs now reach the launch step for the first time, and fail there. That step was unreachable before, because the pin failed the job several steps earlier. This is not a CI configuration problem, so I have not touched the assertion. macOS, working, relays the backend's output and stays up for the full 90 seconds: Linux, both bundle formats, stops dead on the same line and the process is gone about a second later: Not one Why this should still mergeBefore: six legs red, all six for reasons that had nothing to do with the shipped bundle. That is the workflow doing its job. Merging it turns a nightly that reports nothing into one that reports a real defect, and the Linux failure needs fixing in the desktop app rather than here. The last commit is part of that: the early-exit branch runs under |
|
@codex review |
1 similar comment
|
@codex review |
|
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
…pins The nightly has been red on main since 2026-08-05, all six legs, for two unrelated reasons. macOS and Windows died at the download with 'no assets match the file pattern'. The patterns were Tauri's default bundle names, '*aarch64.dmg' and '*setup.exe'. The release pipeline moved to its own scheme at desktop-v0.1.512-beta, so the assets are now Unsloth-Desktop-<ver>-MacOS.dmg and Unsloth-Desktop-<ver>-Windows.exe. The last green run, on 2026-08-04, resolved desktop-v0.1.50-beta and downloaded Unsloth.Studio.Desktop._0.1.50-beta_aarch64.dmg, which is the last release that carried the old names. Matching on the extension instead removes the coupling to a naming scheme; a release ships exactly one .dmg and one .exe, and the arm64 assertion further down is what actually checks the architecture. Linux died on its own tripwire, which fired exactly as designed: the bundled install.sh now carries #7547; delete this pin block and let the venv + torch assertions below run unconditionally Both outcome pins are gone. macOS no longer accepts exit 1 plus the Xcode CLT gate line, Linux no longer accepts exit 2 plus the NEED_SUDO optional set, and all three legs now require the installer to exit 0, leave a venv and import torch -- the assertion Windows already made.
The launch steps run under `bash -e`, so `wait "$APP_PID"` returning non-zero aborted the step on that line and neither the ::error:: annotation nor the tail of app-stdout.log ever printed. The failure surfaced as a bare 'Process completed with exit code 1' with no annotation and no app output, which is precisely the information the branch exists to produce. Found while validating this PR on staging: with the download and pin fixes in place the Linux legs reach the launch step for the first time, it fails, and the log said nothing about why.
…h default Two things the pin retirement left behind. The dispatch default for release_tag was desktop-v0.1.50-beta, a bundle that predates #7547. With the outcome pins gone a manual dispatch that took the default would fail all four POSIX legs at the installer step, on a bundle nobody meant to test. Empty instead, which falls through to the same newest-desktop-v* resolution the schedule already uses. The ready-disposition assertion was Windows-only, and the reason given for that was the install root. The source says otherwise: preflight/managed.rs env_removes UNSLOTH_STUDIO_HOME and STUDIO_HOME unconditionally, not under a cfg(windows), with a comment saying Tauri uses the legacy root regardless. So all three platforms read the same root and the asymmetry was unjustified. It also mattered more once the pins went: a post-#7547 bundle can install a working venv and still have preflight regress to NotInstalled, and the app then sits on the Install screen -- alive, log written, a disposition recorded, and nothing it just built recognised. macOS and Linux accepted that. All four staging legs record ManagedReady today, so this tightens the bar without moving any leg from green to red.
60a7061 to
f2386b6
Compare
|
@codex review |
3 similar comments
|
@codex review |
|
@codex review |
|
@codex review |
|
Codex Review: Didn't find any major issues. Keep it up! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
The nightly has been red on
mainsince 2026-08-05, all six legs, for two unrelated reasons. Neither is a product regression.macOS and Windows: the download patterns went stale
Both legs died at
gh release downloadwithno assets match the file pattern. The patterns were Tauri's default bundle names, and the release pipeline moved to its own scheme atdesktop-v0.1.512-beta:desktop-v0.1.50-beta)desktop-v0.1.522-beta)*aarch64.dmgUnsloth.Studio.Desktop._0.1.50-beta_aarch64.dmgUnsloth-Desktop-0_1_522_beta-MacOS.dmg*setup.exeUnsloth-Desktop-0_1_522_beta-Windows.exe*.deb...-Linux.deb...-Ubuntu.deb*.AppImage...-Ubuntu.AppImage...-Linux.AppImageThe 2026-08-04 run was the last one to resolve a release built with the old names, which is exactly why it was the last green one. The two Linux patterns already matched on extension and kept working; the deb/AppImage OS labels swapped between the schemes, which a glob does not care about.
Matching on the extension drops the coupling to a naming scheme entirely. A release ships exactly one
.dmgand one.exe, and the arm64 check further down the macOS leg is what actually verifies the architecture, so theaarch64fragment was never load-bearing.Linux: its own tripwire fired
The deb and AppImage legs got past the download and stopped on the guard they were built with:
That is the pin doing its job. It was added when the shipped bundle predated #7547, it detects
_SMART_APT_OPTIONAL(Linux) and_check_macos_deps(macOS) as the marker that the shippedinstall.shcaught up, and it asks to be deleted at that point. Thedesktop-v0.1.522-betabundle carries the fix, so both pins are retired here.With them gone, all three platforms now hold the installer to the same bar Windows already did: exit 0, leave a venv at
~/.unsloth/studio/unsloth_studio/bin/python, and import torch. macOS no longer acceptsexit 1plus the Xcode CLT gate line, and Linux no longer acceptsexit 2plus the exact NEED_SUDO optional set.Validation
Validated on a staging repo rather than by merging and waiting for the next nightly: the release assets are mirrored into the staging repo so the workflow resolves and downloads them the same way, and the job is dispatched there against the current bundle.