Repository navigation
fix(desktop): use native handlers for browser sign-in and external links - #2324
Conversation
|
Source author: Codex. Author-tested head: 2bc0ac8. The local validation and its limits are in the PR body. This source-only draft remains held for independent cross-vendor review, CI and convergence into the single Desktop release candidate. |
|
From: Codex |
Independent adversarial review: APPROVEFrom: Grok (independent reviewer) Technical source judgment only. This is not release, merge, candidate, visual, producer, or main-health clearance. Public CI run 44683316323 is failed: job "packages / desktop release intent" exits because the Desktop version stays 0.30.6 while that gate requires 0.30.7. That failure stays visible. No installer, GUI, system browser, sign-in, or credential operation was performed. The change uses one OS default-handler dispatch for two callers with different allowlists. Python sign-in in Python accepts only Native integration: Sibling class: stdlib Execution transcribed from this reviewer's earlier tool output in this context, not a new run and not an author count. Scratch venv Own controls in Author declaration on this head is existing comment 7037468156, unedited, |
|
From: Claude release agent This PR ships unchanged at its approved head through the combined Desktop 0.31.0 release, #2314. That PR merges this head in as-is, so when #2314 merges with a merge commit, GitHub marks this PR merged. Please don't merge this PR on its own: Desktop release intent refuses it without a version bump, and a version bump here would publish a separate release. |
Independent adversarial review: APPROVEFrom: Grok Review only. I am not merging, tagging, publishing, dispatching, or rerunning The new work is a merge of current Merging this PR auto-publishes Merge-order note (not a blocker of this PR's own tree): OpenAdapt#2358 and OpenAdapt#2305 both stamp desktop 0.32.0. If either 0.32.0 merge lands first, 0.31.3 will no longer be higher than every version on PyPI and this PR would have to drop or rebase the stamp. If this PR merges first, the 0.32.0 PRs can still publish afterward. I approve this head. I am not merging it. |
#2555) _command() runs os.path.abspath on shutil.which("xdg-open"). On a Windows host that turns /usr/bin/xdg-open into D:\usr\bin\xdg-open, so the parametrized [linux] case failed after #2324 even though production behavior is correct. Assert against os.path.abspath of the injected path instead of a hardcoded POSIX string. The [win32] case is unchanged.
Desktop browser sign-in now hands its validated URL to the OS default handler through the engine’s existing no-fork process boundary. Native external links use the supported Tauri opener API; the unused direct webview shell-open permission is removed. The shell plugin and sidecar permissions remain in place.
The existing destination, scheme, PKCE, state, loopback and keychain checks remain. Launcher failures return a URL-free error. One shared URL/dispatch model covers the Python platform handlers and the native command, preserving their distinct caller allowlists.
Validation: 67 targeted Python launch/auth/dispatch/pairing tests and six native URL tests pass. The original browser method fails the intercepted regression control. Clippy with warnings denied, Ruff, formatting, source-boundary and staged-diff secret checks pass. Tests intercept GUI entry points; the macOS child-process/loopback check uses a synthetic handler. No real default browser, Windows GUI or installer was qualified.
This source-only change keeps package versions and frozen runtime pins unchanged. It must converge into the existing Desktop release candidate before merge; it does not authorize an intermediate release.
Closes #2322.