Refactor Bluetooth Auto-Connect and VRT stability constraints - #9656
Conversation
…lity - Simplifies `shouldAutoConnect` logic in ConnectPage to prevent manual `timeoutId` management while preventing SSR mismatch - Migrates module-scoped `connectionLock` to hook-scoped `useRef` to prevent application-wide lock conflicts - Updates `connectAndStream` to properly reject promises when a connection is actively locked - Replaces arbitrary 20-second Playwright timeouts with robust text locators in VRT tests - Removes redundant comments and unneeded variables in components testing Co-authored-by: arii <342438+arii@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
👋 Welcome to HRM!Thanks for your contribution. This repository uses Gemini AI for automated triage, code review, and generation. 🤖 Gemini Manual Trigger Quick Reference
For more details and GitHub CLI examples, see the Manual Trigger Guide. |
ℹ️ Gemini Review DisabledAutomatic review is currently disabled via Via Comment: Via GitHub Actions:
Via GitHub CLI: gh workflow run reusable-gemini-review.yml -f pr_number=9656🤖 Gemini Manual Trigger GuideTo re-enable: Set repository variable |
🤖 Gemini Review SkippedReview was skipped for the following reason: 🤖 Gemini Manual Trigger Guide |
🤖 AI Technical AuditPR Review: Bluetooth & VRT Stability Refactor (#9656)Architectural ImpactMoving Anti-AI-Slop
File-by-File Analysis
|
- Runs prettier to fix the reported `Already connecting` line string spacing in `tests/unit/hooks/useBluetoothHRM.test.ts`. Co-authored-by: arii <342438+arii@users.noreply.github.com>
🤖 Gemini Review SkippedReview was skipped for the following reason: 🤖 Gemini Manual Trigger Guide |
b8237c2
into
fix-bluetooth-race-condition-17974409934683189531
This PR addresses the directives found in the principal engineer's audit of the Bluetooth race condition fix. It strips out over-engineered wrappers, refactors state hooks to prevent logic issues with
Promise.reject(), cleans up VRT tests for proper stability without relying on large timeouts, and removes overly verbose comments.PR created automatically by Jules for task 12746883362824899620 started by @arii