Repository navigation
feat(native): Linux support, phase 3 — release leg, update channel, download surface - #5556
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 51 files
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
tlgimenes
force-pushed
the
claude/linux-release-leg
branch
from
August 1, 2026 10:54
1d8b324 to
3ca427c
Compare
tlgimenes
force-pushed
the
claude/linux-release-leg
branch
4 times, most recently
from
August 1, 2026 20:29
48ed307 to
64305f4
Compare
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 5 files (changes from recent commits).
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
tlgimenes
force-pushed
the
claude/linux-release-leg
branch
from
August 3, 2026 14:48
9f57188 to
9ce92df
Compare
tlgimenes
force-pushed
the
claude/linux-release-leg
branch
from
August 3, 2026 15:27
9ce92df to
0097745
Compare
tlgimenes
force-pushed
the
claude/linux-release-leg
branch
2 times, most recently
from
August 3, 2026 16:46
8c44f4e to
a8d83c5
Compare
…rewrite Verified in a real Linux container rather than inferred from CI, which had been dying before it could report anything. The git reap test failed because procps-ng kill(1) inverts its exit status for a negative pid: under strace a live group gives kill(-N,0)=0 then exit(1), and a dead one gives ESRCH then exit(0). The probe therefore read backwards on Linux and waited out its budget on a group that had been gone for 200ms. It now asks pgrep -g, which answers the same way on both platforms. ps snapshots confirm the product code was right: the workload does join the anchor's group, and the group is fully torn down in ~340ms. The anchor rewrite is reverted. Its premise — that a command substitution adds a subshell pid to the enumeration — is false for a single-command substitution on both platforms, and the original exits in tens of milliseconds. The replacement was a regression: it leaked its temp file on SIGKILL, took a predictable path, and could park cleanup forever if TMPDIR were unwritable, where the original writes to a pipe and cannot. The procps-vs-BSD note and the $$ skip are kept, now citing the measurement. All four Linux quarantines are removed: they pass on Linux. Co-Authored-By: Claude Fable 5 <[email protected]>
These two pass on a real Linux kernel — 5/5 each in a container with native /proc, procps and process groups — but still SIGKILL a GitHub-hosted runner mid-chunk. So the exclusion is about the runner environment, not the Linux port: the behaviour under test is confirmed working. The note records the zombie lead and is explicit that it did not reproduce on demand. Co-Authored-By: Claude Fable 5 <[email protected]>
It passes on a real Linux kernel (5/5 in a container) and still SIGKILLs a GitHub runner mid-chunk, with every other chunk of the crate passing there — so it is this test against that runner, not accumulation, which the chunking already disproved. A CI exclusion, not a port gap. Co-Authored-By: Claude Fable 5 <[email protected]>
…roken there The ubuntu leg this branch adds is the first thing ever to run main's PTY watchdog test on Linux, and it fails: tty_vhangup detaches the controlling terminal from the whole session when the PTY master closes, which is exactly what an owner SIGKILL does. reap_terminal enumerates only through ps -t <tty> and reads its exit 1 as an empty tty, so it signals nothing and then releases the lifetime fence with the wrapper, workload and descendant all still running. macOS keeps the session-to-tty association, so the same reap works there. Reproduced 3/3 against pristine origin/main in a container, so this predates the Linux port. The same ps -t primitive backs signal_terminal_members in production, where it reports success for the hung-up case — the interactive path is fine because Studio still holds the master; crash recovery is not. Ignored rather than fixed: enumerating by session id instead of tty is a design change to the PTY watchdog, platform-branched because macOS ps prints sess 0, and it belongs to that feature's owners. Co-Authored-By: Claude Fable 5 <[email protected]>
Ports the daemon's proven FUSE path into the desktop: rclone mount instead of nfsmount, /proc/self/mounts instead of spawning BSD mount, and a lazy fusermount3/fusermount/umount detach chain. Each per-OS difference is a runtime seam, so both dialects compile and unit-test on either host and the macOS argv, parser and unmount stay byte-identical. Attachment detection no longer filters on filesystem type — only the stale sweep does, where a miss is safe. Gating attachment on it made an unrecognized type kill a working rclone and loop forever. Unmounts and whole mount attempts are time-bounded, because lazy detach bounds the kernel's half but not libfuse's pre-flight stat. Since a tokio blocking task cannot be cancelled, an abandoned attempt strands a thread from a pool shared process-wide, so repeated abandons back off and then stop retrying entirely; a wedged server is reclaimed at the next boot, not by another attempt in this one. Co-Authored-By: Claude Fable 5 <[email protected]>
Biome ignores markdown and its pre-commit step fails a docs-only staged set, hence --no-verify. Co-Authored-By: Claude Fable 5 <[email protected]>
Two org-fs parser tests fed a BSD-format table to stale_mountpoints, which picks its dialect from the host — so they asserted BSD parsing on macOS and /proc parsing on Linux, where the same lines do not parse and the assertions went empty. Call the dialect-explicit twin instead, and add the Linux half of the spaces case: /proc escapes them as \040, so that parser has to unescape rather than split on whitespace. Co-Authored-By: Claude Fable 5 <[email protected]>
latest.json gains a linux-x86_64 entry, and the builder now refuses to emit a manifest missing any platform — it is one document with a single version, so a partial entry bricks updates for every platform, not just the missing one. A coverage check stops a repair run from clobbering a wider manifest with a narrower one. Linux gets the twin of the macOS version-pairing defence: v1Compatible makes the tarball single-member, and that member's name is covered by the signature, so it pins the artifact to the version the manifest advertises. Co-Authored-By: Claude Fable 5 <[email protected]>
Splits the release job into plan, build, publish, promote and alert. Only promotion is held back on a partial build: a red Linux leg must not freeze the macOS release or the cask, which is the documented break-glass channel. Promote now verifies every artifact against the pinned pubkey before building the manifest, so a signature separated from its bytes — by an interrupted upload plus a non-reproducible rebuild — fails the run instead of shipping a manifest no client can verify. Assets on immutable tags are write-once, and an orphaned half of a pair is named rather than topped up. AppImage tooling is pinned and checksummed in one file both workflows read, so a stale pin fails the PR that introduces it rather than release day, and the build is asserted afterwards to have fetched nothing outside that pin table. Co-Authored-By: Claude Fable 5 <[email protected]>
Linux browsers were shown macOS Terminal install instructions; the dialog now branches whole, so no Mac, Terminal or Apple Silicon copy renders there. The download URL is a pure helper pinned by a test, because the release workflow and the update manifest encode the same asset name. Co-Authored-By: Claude Fable 5 <[email protected]>
Biome ignores markdown and fails a docs-only staged set, hence --no-verify. Co-Authored-By: Claude Fable 5 <[email protected]>
install.sh grows a Linux path: it resolves the version from the updater channel's latest.json — a single stable URL, promoted only once every platform's assets are on the immutable tag — rather than scanning the release list, which at this repo's ~46 releases/day covered barely two days and would have told users Linux was never released while a good build sat just past the window. Integrity is stated as what it is. The .sha256 sits on the same release, behind the same TLS session, as the binary it describes, so it catches a corrupt or truncated download and nothing more; the comments no longer claim otherwise, and no longer claim the cask's digest is human-reviewed when the release bot pushes it unreviewed. Real authenticity is available where it is cheap: the minisign public key is embedded here, and this script is served from a different origin than the GitHub CDN, so when minisign is present the signed tarball is verified and extracted instead. Without it the run says so out loud rather than downgrading in silence. The channel body is shape-checked before anything is attributed to it — curl returns captive-portal pages with HTTP 200, and the rolling channel asset is the one file re-uploaded on every promote, so 'no Linux release yet' must not be the answer to 'the network lied to us'. promote now requires the checksum too: publishing a version whose installer would then refuse to run is the same half-published state that gate exists to prevent. The dialog offers Linux the installer, keeping the direct AppImage as a secondary path. Co-Authored-By: Claude Fable 5 <[email protected]>
…erminal The crash-recovery fence released while the workload was still alive on Linux. When the owner is SIGKILLed it closes the PTY master, and Linux's `tty_vhangup` then detaches the controlling terminal from the WHOLE session: every member's tty becomes `?`. `reap_terminal` enumerated only via `ps -t <tty>` and treated exit 1 as "the tty is empty, we are done", so it signalled nothing, ran `cleanup_control` and exited 0 — releasing the shared child-lifetime fence over a wrapper, a workload and its descendant that were all still running and still forking. Reproduces 3/3 against pristine main; it predates the Linux port and only surfaced when the ubuntu CI leg was added. macOS is unaffected: BSD keeps the session→terminal association, so `ps -t` still lists the members there. Enumeration is now split out of the reaper and platform-branched. On Linux the session id survives the hangup, so the reaper unions `ps -t` and `ps -s` and concludes "empty" only after every witness has spoken; a hung-up tty is not a witness (its `ps` exit 1 is indistinguishable from "matched nothing"), and once the slave node is gone the witness is latched off for the rest of the teardown so a recycled pts index cannot be mistaken for the original. macOS keeps exactly the tty path it had. `signal_terminal_members` had the same blindness — it returned success for the hung-up case — and now shares the rule. A zombie is not a live member, or the reaper never terminates: `ps -s` keeps listing orphaned zombies that `ps -t` used to drop, and `kill -0` answers for them. But on Linux state `Z` alone does not mean "no code is running" — a thread-group leader that exits while its threads run stays `Z` forever — so a `Z` row with more than one unreleased task is settled from the per-task view (`ps -L -o stat=`), which separates a husk from a live process that the row spec cannot. BSD has no thread-count keyword and no such state, so it keeps the plain rule. Also fixes a second defect found on the way: the tty was validated only against `??`, but Linux spells "no controlling terminal" `?`, and `ps -t '?'` does not fail — it exits 0 listing every ttyless process on the machine. Post-hangup, Interrupt/Term/Kill would have signalled all of them. Indeterminate still parks forever rather than releasing the fence — that property is preserved on every path, including the new ones. Removes the Linux-scoped ignore this stack added to `pty_watchdog_fences_every_owner_sigkill_startup_phase`, and adds two platform-gated tests: the Linux row-classification rule (mutation-killed against both weaker rules) and the macOS latch releasing rather than parking. Known macOS gap, unchanged from before and documented in place: a survivor that outlives the wrapper is not enumerable by any BSD selector, so the fence releases without proof. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
`kill -SIG -<pgid>` is not portable. procps-ng reads any leading `-` token as a signal spec wherever it appears, so a bare negative pid leaves it holding an EMPTY pid list — and it then signals the CALLER's own process group instead of the group asked for. Measured with the target in its own group and a canary in the caller's, identical on procps-ng 3.3.17 (Ubuntu 22.04, Debian 11, RHEL 8-9) AND 4.0.4 (Ubuntu 24.04): kill -KILL -<pgid> target survives, CALLER'S GROUP IS SIGKILLED kill -KILL -- -<pgid> rc 0, target killed, caller untouched BSD kill(1) accepts the negative form, which is why macOS never showed any of this, and why the claim in harness/Cargo.toml that shelling out to kill(1) is "POSIX-portable" held up for two years — it is true only for positive pids. That claim is corrected here; it is what licensed the pattern. Two shipping paths were affected on Linux: - `terminal-session::signal_child` — the terminal's Ctrl-C / stop button. It never delivered SIGINT to the foreground job, and on Ubuntu kill(1) exits 0, so Studio reported the interrupt as delivered while nothing happened: a user could not stop a runaway command. Fixed by dropping `run_kill` for the crate's own `signal_non_anchor_members`, which is `pgrep -g` plus one kill per POSITIVE pid — portable everywhere tested, and consistent with how the TERM and KILL arms already worked. Semantic delta: an already-empty foreground group now returns Ok, not Err. - `local-api::process_util::kill_group` — dev-server teardown and persisted-orphan reaping. Reaping a stale dev server SIGTERMed then SIGKILLed Studio's own group and left the server running. Fixed with `--`, factored into `group_signal_argv` with a unit test so the separator cannot be dropped silently. This is also what killed the GitHub runner. The three tests excluded as "ignored on the runner, passes on a real kernel" were signalling their own process group; because `setsid --wait` does not fork when the caller is not already a group leader, cargo IS the session leader, so the tests SIGKILLed cargo and the test binary while the fixture survived. That matches the CI logs exactly (exit 137, orphaned sh+sleep pairs, three runs). All three are fixed and re-enabled, so `apps/native` now has no Linux-scoped ignores at all. The workflow comments that blamed accumulation and credited `setsid` with protection it cannot provide are corrected: excluding three self-killing tests one at a time produces precisely the moving kill point that was read as accumulation. None of this was visible because `terminal-session` was never in the Linux test list. It is added here. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
From the bot review backlog on this stack. Only the findings that survived an adversarial pass are here; the rest were stale, already fixed, or wrong, and are answered on the PRs. CI integrity: - The three aggregator jobs carrying the required check names accepted a `skipped` leg without looking at the gate. If `changes` failed or was cancelled, all three legs skipped, the aggregators exited 0, and the checks branch protection watches went green with no macOS or Linux job having run. They now fail unless `needs.changes.result == 'success'`. `changes` has no `if:` and no `needs`, so `skipped` is unreachable and the "required check that never runs blocks the merge forever" trap this pattern exists to avoid is not resurrected; check names are unchanged. - Both ubuntu legs shared one rust-cache entry — rust-cache keys on `GITHUB_JOB`, not on matrix values, so the `test` leg restored the `lint` leg's cache with a full match and its post step saved nothing. Keyed on `matrix.task` now; the comment claiming each leg saved its own cache was false. - The `setup::` chunk re-ran the whole `routes::setup::` subtree, because cargo test filters are substring matches and `routes` declares `pub mod setup`. Skipped explicitly. Measured: the four invocations are now an exact partition of the crate (no gap, no overlap), where before 21 tests ran twice. Correctness: - The git process-group tripwire proved nothing. It probed `pgrep -g <git pid>`, but `ProcessGroupChild::spawn` puts the child in the ANCHOR's group, so git is never a group leader and the probe exited 1 on its first call — the assertion passed vacuously. It now reads the real pgid via `ps -o pgid=`, with `assert_ne!(pgid, pid)` so the old shape cannot come back. Same family as the negative-pid `kill` defect fixed earlier in this stack: pgid semantics assumed rather than measured. - The same tests' liveness probes treated a `pgrep` failure as "the group is empty", i.e. failed open on the one question they exist to answer. They now fail closed. - Two 15s poll loops spun on `yield_now()` while forking `pgrep` per iteration on a runtime thread; they sleep 25ms instead. Accuracy — this repo treats a false comment as a defect: - `LocalTls::ca_pem` carries the in-memory issuer so the child CA bundle no longer depends on re-reading `ca-cert.pem`, which `ensure()` never reads on the reuse path. The doc names the one consumer still taking the on-disk path (`NODE_EXTRA_CA_CERTS`, via `TlsFiles`) rather than claiming everything now uses the in-memory copy; closing that one needs a per-boot cert file and is left as a follow-up. - The AppImage check greps for libfuse.so.2; it does not prove static linkage, so the step is renamed for what it gates. Measured on a static-PIE binary: 22-entry dynamic section, ZERO DT_NEEDED — so "reject any DT_NEEDED" would pass it, and only "require no dynamic section" would reject it. Naming it "statically linked" oversold it. - The Linux boot smoke launches the extracted `AppRun`, not the inner binary — only `AppRun` exports the WebKit exec and library paths. - `gatingKeys` named two keys the selftest bundle never emits, so real gating failures were logged as `[INFO]`. It now mirrors the bundle's `gating` array exactly. Coverage: - `src-tauri/selftest/bundle.js` is `include_str!`-ed into the shell and is what the smoke gates on, but no freshness input covered it: editing it and running the smoke reported "found fresh bundle" and smoked the previously embedded selftest. Added, along with `fetch-rclone.sh` and the per-platform Tauri config overlay. - Added a Linux-gated test for the selftest origin rule — the only test over `control_origin_for` was `cfg(not(linux))`, so nothing pinned the platform whose behaviour it describes. - `vite.config.ts` now points the Linux dev proxy at the plaintext listener; local-api is not TLS there under `tauri dev`. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
tlgimenes
force-pushed
the
claude/linux-release-leg
branch
from
August 19, 2026 18:37
d4bd1ca to
bb70271
Compare
Contributor
Author
|
Addressed the review feedback on the current head:
The review fixes are in |
decocms Bot
pushed a commit
that referenced
this pull request
Aug 19, 2026
PR: #5556 feat(native): Linux support, phase 3 — release leg, update channel, download surface Bump type: minor - decocms (apps/api/package.json): 4.240.0 -> 4.241.0 - @decocms/native (apps/native/package.json): 4.240.0 -> 4.241.0 Deploy-Scope: web
This was referenced Aug 19, 2026
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
Phase 3 of Linux support: the AppImage is built, published, and carried by the self-update channel, and Linux browsers get a working download.
Stacked on #5509 (phase 1) and #5532 (phase 2). Based on
mainso it gets CI — the workflows only run for PRs targetingmain, so a branch-based PR gets none. Its diff narrows to phase 3 alone once the parents land; review the phase-3 commits.Only the update channel is held back on a partial build. A red Linux leg must never freeze the macOS release or the Homebrew cask, which the workflow header designates as the break-glass channel for updater key loss.
Job graph
plan(secretless) →build(matrix,fail-fast: false) →publish(runs even when a leg failed) →promote(the only thing gated on all legs succeeding) →alert(own job, job-levelalways()).alerthas to be its own job: a step-level condition inside a job that is skipped by an upstream failure never evaluates —always()included — so the most likely new failure mode, a red Linux leg, would otherwise be silent. That is exactly the unbounded-invisible-staleness hazard the alert exists for.Defects found and fixed in review
An adversarial pass refuted the two headline questions (a Linux failure cannot block macOS distribution; the alert does fire) and found six real defects. Each fix was driven through a stubbed harness, not just read:
(tar.gz, .sig)pair could split across runs and be published unverified. An interrupted upload lands the tarball without its signature; a repair rebuilds non-reproducibly, and write-once then keeps the old tarball with the new signature. Every macOS client would fail verification every cycle until a newer version promoted — with CI fully green.promotenow verifies every artifact against the pinned pubkey withminisign -Vbefore building the manifest, so signature↔bytes pairing is asserted rather than inferred.Testing
cargo test --workspace1123 passed / 0 failed; clippy-D warnings,cargo fmt --check,bun run check(which proves pt-br translation completeness),bun run lint,bun test apps/native/scripts(37) all clean. Both workflows parse with everyneeds:resolving.Not exercised until a real release runs: the promote job's minisign verification and the two-platform manifest are validated by harness and unit tests, not by an actual tagged release.
🤖 Generated with Claude Code
Summary by cubic
Builds and ships the Linux x86_64 AppImage and carries it on the self‑update channel without blocking macOS. Previously macOS‑only; now Linux builds run in parallel, the updater serves Linux, and Linux‑specific runtime gaps (TLS, org‑fs, process groups, PATH, browser open) are closed.
@tauri-apps/cli, launches via AppImageAppRun, and pre‑seeds/checksums AppImage tools so PR CI exercises the exact pins.linux‑x86_64; builder refuses partial manifests, emits single‑member, name‑pinned tarballs, andpromoteminisign‑verifies every artifact; updater stages/installs only inside an AppImage and applies on quit. Release graph splits to plan → build (macOS + Ubuntu) → publish → promote → alert so a red Linux leg cannot freeze the macOS release or cask.DECOCMS_LINUX_SECURE_ORIGINvia a WebKitGTK per‑host exception; spawned children get a system+local CA bundle viaSSL_CERT_FILE; preview host observer ensures the preview iframe loads; GUI PATH repair;xdg-openfallback; clearer ripgrep hint. Fixes Linux CA validation build.rclone mount(FUSE) using lazy detach and bounded unmount/attempt/backoff; escape hatchDECOCMS_DISABLE_ORG_FS; macOS NFS path unchanged.latest.json, verifies minisign signatures when available (falls back to sha256), installs to~/.local/binand adds a launcher; dialog offers the Linux path and a direct AppImage link; dev proxy defaults to plain http on Linux unlessDECOCMS_LINUX_SECURE_ORIGIN=1.pgrep -gplus per‑pid kills (andkill -- -<pgid>where used); Ctrl‑C delivery and dev‑server teardown are correct; adds a unit test for the--separator.changessuccess and separate rust‑cache keys.Written for commit ba7456f. Summary will update on new commits.