fix: harden macOS CLI detection candidates#472
Conversation
|
@Dimillian I'm still out of codex cloud review credits lol |
|
@codex review |
No, the cloud model really behaves differently for now, but it's a good first pass. I also do a lot of custom /review locally because, yeah, it's better for now. |
|
Codex Review: Didn't find any major issues. Hooray! ℹ️ 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". |
Summary
Follow-up to #466 (and referencing #406): fixes remaining macOS Tailscale detection edge cases where
Detect Tailscalecan select a non-usable candidate and then fail parsingstatus --jsonoutput.This change hardens candidate selection and validation so CLI wrapper paths are preferred, and unexpected
tailscale versionoutput is rejected before status parsing.Key Changes
/Applications/Tailscale.app/Contents/MacOS/Tailscale/Applications/Tailscale.app/Contents/MacOS/tailscaletailscale(PATH)/opt/homebrew/bin/tailscale/usr/local/bin/tailscale/usr/local/bin/Tailscalelooks_like_tailscale_version(...)guardtailscale versionsucceeds and stdout contains a plausible version token.Behavior Notes
Before Fix (macOS)
Observed on click Detect Tailscale:
Validation Run
pnpm run lint(passes; 1 pre-existing warning insrc/features/app/hooks/useRemoteThreadLiveConnection.ts)cd src-tauri && cargo test tailscale::cd src-tauri && cargo check