Skip to content

fix(v0): backport Tao macOS lifecycle and shadow fixes - #93

Merged
twlite merged 2 commits into
v0from
fix/v0-tao-macos-backport
Nov 15, 2026
Merged

twlite merged 2 commits into
v0from
fix/v0-tao-macos-backport

Conversation

@twlite

@twlite twlite commented Nov 15, 2026

Copy link
Copy Markdown
Member

Backport #92 to the original root-layout v0 package. This branch starts at latest origin/v0 (bf9e854); no merge or rebase from main, architecture changes, package version bumps or publication.

Changes

  • Pin the root Cargo.toml Tao patch to 73ab3e94986f045ad379faee9b2560bffd84012c and include the resolved root Cargo.lock. v0 previously ignored/untracked this file; it is explicitly added so the dependency resolution is reviewable and reproducible.
  • Incorporate the upstream Tao synchronization, macOS redraw reentrancy/maximizable changes, run-loop observer lifetime fix, and explicit borderless shadow handling. Existing v0 pump/shadow forwarding remains compatible, with no integration source changes required. Generated JS/declarations are unchanged after regeneration and formatting.
  • Port the relevant native tests to v0's node:test / node:assert setup and load the actual root index.js public API and locally built N-API addon. No monorepo tools or workspace structure were copied.
  • Add an opt-in bun run test:native:macos command and a macOS native job in the existing validation workflow.

Related: github/copilot-cli#5398 and #91. Neither issue is automatically closed.

Reproductions

The parent Node test process hosts HTTP independently of native child execution. Fresh Node/Bun child processes own AppKit on the main thread, with a 25-second watchdog, explicit native disposal/pump shutdown, process reaping and HTTP server cleanup.

Loading tests use whenReady({interval:50,ref:false}), localhost, inline HTML and data URLs. Each DOM must load before another window is created or explicit focus is requested. They exercise JavaScript reads/mutation, timers, HTTP fetches, IPC, seven seconds without input, twenty manual pump iterations, multiple windows, resizing, focus and cleanup.

Latest final loading results: Node roots=1, HTTP ticks=89, IPC=175, data JS ticks=68; Bun roots=1, HTTP ticks=88, IPC=173, data JS ticks=68. All three pages passed DOM mutation and lifecycle checks.

Shadow tests cover all 16 combinations of decorations/resizable/minimizable/shadow after webview attachment, style mutations, explicit disabling and runtime shadow changes. Rebuilding v0 with the original 9bb2bdc pin fails under both Node and Bun for the exact all-false-style/true-shadow configuration in #91; restoring the updated pin passes.

Validation

Local host: macOS 27.0.1 (26A434), ARM64; Node 24.22.1, Bun 1.4.4, Rust 1.99.1.

Passed:

  • bun install --frozen-lockfile, release bun run build using the real root addon.
  • bun run test: 10 passed, including the native custom-protocol test and strict generated declaration/type fixture checks.
  • bun run test:native:macos: 4 passed, covering Node and Bun loading/shadows.
  • cargo check / cargo check --locked, cargo clippy -- -D warnings, cargo test --lib (17 passed).
  • bun run lint (two existing unused-variable warnings in examples), full Prettier check, cargo fmt -- --check, new JS syntax checks and git diff --check.
  • Cargo checks for macOS ARM64/x64, Windows x64 MSVC, and the FreeBSD stub. These establish compilation only; cross-target executables were not linked or run. FreeBSD retains its existing stub/dead-code warnings.
  • Native integration tests skip when not explicitly enabled; no GUI is added to the default test command.

Limits:

  • The macOS 26 blank-window stall did not reproduce on this macOS 27 host. The lifecycle fix is included, but affected macOS 26 behavior remains unverified. GitHub still needs to update Copilot CLI's bundled dependency.
  • Wry 0.55.1's separate data-URL IPC limitation remains: its macOS delegate discards messages because http::Uri rejects opaque data URLs. The port preserves fix: integrate Tao macOS lifecycle and borderless shadow fixes #92's explicit coverage boundary: data navigation/DOM/JS timers are checked, IPC is required for localhost and inline HTML. No workaround or unrelated Wry upgrade is included.
  • Shadow state is asserted with hasShadow(), not measured visually in the compositor. macOS 15/26 and Windows/Linux GUI behavior are untested.
  • Linux cross-check was attempted but blocked by missing target pkg-config/sysroot (wayland-sys). Hosted platform and new native macOS CI results are pending.

@vercel

vercel Bot commented Nov 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
webview Ignored Ignored Nov 15, 2026 11:20am UTC

@twlite
twlite merged commit d68d559 into v0 Nov 15, 2026
16 checks passed
@twlite
twlite deleted the fix/v0-tao-macos-backport branch November 15, 2026 11:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant