Repository navigation
fix(linux): restore the macOS build of the Tauri companion - #114243
Conversation
Tauri gates `WebviewWindowBuilder::transparent` behind its `macos-private-api` feature on macOS, so the companion stopped compiling for macOS when Quick Chat landed in #109947: `no method named 'transparent' found for struct 'WebviewWindowBuilder'`. Enable that feature together with the matching `app.macOSPrivateApi` config flag, which Tauri requires to agree with it or tauri-build fails the allowlist check. Quick Chat is built for a transparent window - quickchat.css makes html and body transparent behind a 16px-radius translucent card with a drop shadow - so compiling macOS by dropping `.transparent(true)` would ship an opaque rectangle instead of the floating composer. Also add a per-PR macOS `cargo check`. The only job that compiled the macOS target sits behind a manual dispatch input in linux-app-release.yml, which is why a broken macOS build survived for nine days.
tauri-plugin-notifications' Swift sources use typed throws (`throws(FFIResult)`), which requires Swift 6. The macos-14 runner image still ships Swift 5.x and cannot parse them, so the plugin's build script panics with "Swift build failed for target: arm64-apple-macosx13.0". This hit the new per-PR check immediately, and it means the release workflow's `build_macos` job could not have produced a macOS bundle either - it compiles the same crate on the same image, but only runs behind a manual dispatch input so nothing surfaced it. Move both to macos-15.
|
Codex review: needs maintainer review before merge. Reviewed July 26, 2026, 10:50 PM ET / July 27, 2026, 02:50 UTC. ClawSweeper reviewWhat this changesEnables Tauri’s macOS private API for the Linux companion’s transparent Quick Chat window and adds macOS compilation coverage to the companion workflows. Merge readinessKeep open for maintainer review. The patch directly restores a macOS compile path broken by the merged Quick Chat feature and adds a per-PR macOS compile guard; the remaining question is the intentional distribution tradeoff of enabling Tauri’s macOS private API. Priority: P2 Review scores
Verification
How this fits togetherThe Tauri companion packages OpenClaw’s local desktop UI for Linux and macOS test bundles. Quick Chat creates a transparent floating webview, while GitHub Actions compiles the native crate before release bundles can be produced. flowchart LR
A[Quick Chat window request] --> B[Tauri window builder]
B --> C[macOS transparent-window API]
C --> D[Companion native crate]
D --> E[macOS CI compile check]
E --> F[Release test bundles]
Decision needed
Why: The code repair follows Tauri’s paired feature/config contract, but the repository evidence available here does not independently establish the intended macOS distribution policy. Before merge
Agent review detailsSecurityNone. PR surfaceConfig +43, Other +10. Total +53 across 4 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Confirm the companion is intentionally distributed outside the Mac App Store, then retain the paired Tauri feature/config setting and the macOS-15 compile guard so future platform-gated APIs fail in CI. Do we have a high-confidence way to reproduce the issue? Yes. The PR supplies a concrete current-base macOS reproduction: Is this the best way to solve the issue? Unclear pending product confirmation. The paired Cargo feature and Tauri config are the narrowest technical repair and preserve the existing floating composer, but maintainers must confirm that losing Mac App Store eligibility is intentional. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 570eab59e7c7. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
|
Merged via squash.
|
…114243) * fix(linux): restore the macOS build of the Tauri companion Tauri gates `WebviewWindowBuilder::transparent` behind its `macos-private-api` feature on macOS, so the companion stopped compiling for macOS when Quick Chat landed in openclaw#109947: `no method named 'transparent' found for struct 'WebviewWindowBuilder'`. Enable that feature together with the matching `app.macOSPrivateApi` config flag, which Tauri requires to agree with it or tauri-build fails the allowlist check. Quick Chat is built for a transparent window - quickchat.css makes html and body transparent behind a 16px-radius translucent card with a drop shadow - so compiling macOS by dropping `.transparent(true)` would ship an opaque rectangle instead of the floating composer. Also add a per-PR macOS `cargo check`. The only job that compiled the macOS target sits behind a manual dispatch input in linux-app-release.yml, which is why a broken macOS build survived for nine days. * ci(linux): build the macOS companion on macos-15 tauri-plugin-notifications' Swift sources use typed throws (`throws(FFIResult)`), which requires Swift 6. The macos-14 runner image still ships Swift 5.x and cannot parse them, so the plugin's build script panics with "Swift build failed for target: arm64-apple-macosx13.0". This hit the new per-PR check immediately, and it means the release workflow's `build_macos` job could not have produced a macOS bundle either - it compiles the same crate on the same image, but only runs behind a manual dispatch input so nothing surfaced it. Move both to macos-15.
Problem
apps/linux/src-taurihas not compiled for macOS since 2026-07-17:Tauri v2 gates
WebviewWindowBuilder::transparentbehind#[cfg(any(not(target_os = "macos"), feature = "macos-private-api"))]. Quick Chat calls it unconditionally, so the macOS target broke the moment the floating composer landed in 277f009 (#109947).It went unnoticed for nine days because nothing compiles the macOS target per PR.
linux-app.ymlbuilds deb/appimage on Linux only, and the one job that does build macOS —build_macosinlinux-app-release.yml— sits behind the manualdesktop-test-bundlesdispatch input.Fix
Enable the
macos-private-apicargo feature on thetauridependency, plus theapp.macOSPrivateApiconfig flag. Tauri requires the two to agree; with only the feature set,tauri-buildfails the allowlist check:The feature is inert on Linux and Windows, and
Cargo.lockis unchanged — it pulls in no new dependencies.Dropping
.transparent(true)on macOS would have compiled too, but it would ship something visibly wrong.quickchat.csssetshtmlandbodytobackground: transparentand paints the composer as a 16px-radius card atrgb(28 28 30 / 94%)with a0 10px 36pxdrop shadow. Without an transparent window, macOS would draw an opaque rectangle around that rounded card and clip its shadow. Keeping the intended floating look is the reason the private API is worth it here.Tradeoff, confirmed with the maintainer: Tauri documents that apps using the private API cannot ship through the Mac App Store. That costs this app nothing — it bundles and executes
install-cli.sh, manages a local Gateway system service, and does mDNS discovery, none of which survive App Store sandboxing, and it already distributes through GitHub releases and a self-update channel.Regression guard
Adds a
check-macosjob tolinux-app.ymlrunningcargo check --locked --all-targetson macOS, so the target that ships as a desktop-test bundle is compiled on every PR touchingapps/linux/**.The guard immediately found a second, unrelated break
On its first run the job failed — not on this change, but in
tauri-plugin-notifications:Those sources use typed throws (
throws(FFIResult)), a Swift 6 feature. Themacos-14runner image still ships Swift 5.x and cannot parse them. It builds locally only because current macOS dev machines have Swift 6 (verified: Swift 6.4 here).The important consequence:
build_macosinlinux-app-release.ymlcompiles the same crate on the samemacos-14image, so it could not have produced a macOS bundle either — invisible because that job only runs behind the manualdesktop-test-bundlesdispatch input. Both jobs move tomacos-15.Proof
Local, on macOS 27.0 (Apple silicon), after touching
src/quickchat.rsto force a real recompile rather than a cache hit:The same tree without these two settings still reproduces the
E0599above, so the new job would have caught the original break.The
macos-15runner change is proven forcheck-macosby this PR's own CI. Forbuild_macosit is unproven by design — that job is part of the release workflow and dispatching it is not something to do casually — but it compiles the same crate on the same image, so the same Swift 6 requirement applies.Proof gap
Compilation and configuration are verified; Quick Chat's transparency was not visually confirmed at runtime on macOS. Doing so needs a bundle built under a throwaway identifier (a stale companion instance holds the single-instance lock) plus synthetic global-shortcut input. The transparency behavior itself is Tauri's documented contract for these two settings.