improve: make desktop picker startup faster and quieter - #2263
Merged
Conversation
Member
Author
|
hey @greptileai, please re-review the PR |
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.
Opening Cap with disconnected saved inputs triggered blocking microphone/camera dialogs. Opening the display/window picker also repeated native input setup, producing visible delays. Restore saved inputs quietly while preserving their selections, join matching in-flight setup, and reuse only matching idle feeds with recent frames/samples. GPUI startup now enumerates microphone names without opening every audio configuration; detailed lookup opens only the requested microphone.
Controlled local macOS measurements with the built-in camera and microphone selected:
All 24 measured openings reached readiness. An additional six-opening Tauri run with the unavailable Shure MV7+ and Logitech selections completed without blocking dialogs and retained both saved selections. Recording readiness, manual selection errors, stalled-feed recovery, and camera-only preview routing remain enforced. Debug-only UI timing hooks and an ignored native benchmark are documented in
apps/desktop/scripts/desktop-picker-performance.md.Validation: 79 frontend tests; targeted camera, microphone, requested-input, applied-microphone, GPUI discovery and camera-cache tests; scoped Rust checks; both native development builds; production frontend build; formatting and scoped Biome. Strict Tauri/shared-recording Clippy passed. GPUI Clippy on stable 1.98 reports existing errors in unchanged files; GPUI check/build and targeted tests passed.
The cold measurements are individual observations and reopening medians contain five samples. Windows hardware and packaged release behavior remain unverified.
Greptile Summary
This PR reduces desktop picker startup latency by quietly restoring saved inputs, joining matching in-flight setup, reusing healthy matching camera and microphone feeds, and avoiding unnecessary microphone configuration lookups. It also adds debug-only picker benchmarks and documents the measurement process.
Confidence Score: 5/5
The PR appears safe to merge; no new actionable issues or outstanding previous findings remain.
Both previous findings were manually resolved and their underlying issues are fixed in the current code: the narrating comment was removed, and the benchmark script was renamed with its include reference updated. The changes since the previous review introduce no additional behavioral or rule-compliance failures.
Important Files Changed
Reviews (2): Last reviewed commit: "chore: use kebab-case for picker benchma..." | Re-trigger Greptile