Sync Work model picker after Cursor auth - #1078
Conversation
AgentChatPane kept a stale local auth map that locked the picker Off until remount; listen for shared cache update/invalidate events without force getStatus probes. Co-authored-by: Cursor <cursoragent@cursor.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
|
Warning Review limit reached
Next review available in: 46 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughChangesAI status cache synchronization
Estimated code review effort: 3 (Moderate) | ~20 minutes Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@apps/desktop/src/renderer/components/chat/AgentChatPane.tsx`:
- Around line 5887-5893: Update the fallback getAiStatusCached call in
AgentChatPane to pass refreshOpenCodeInventory: true when the active session
uses OpenCode, matching the normal refresh path while preserving false for other
sessions. Add a named regression test covering an active OpenCode session that
invalidates the cache and verifies the status request includes
refreshOpenCodeInventory: true.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: d64ad6f1-a0e6-4a08-bd6b-53a384f82457
⛔ Files ignored due to path filters (1)
docs/features/chat/composer-and-ui.mdis excluded by!docs/**
📒 Files selected for processing (2)
apps/desktop/src/renderer/components/chat/AgentChatPane.test.tsxapps/desktop/src/renderer/components/chat/AgentChatPane.tsx
Keep the Work pane settle refill aligned with refreshAvailableModels so an active OpenCode session does not re-apply a stale inventory snapshot. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Addressed CodeRabbit: invalidate settle now passes |
Summary
AgentChatPanenow listens for AI status cache update/invalidate events and applies the shared cache (peek on update; one non-force settle refill if still stale on an active tile).providerAuthStatusin sync after Settings Cursor auth without remounting the desktop app or issuing per-tile forcegetStatusprobes.composer-and-ui.mdand adds regression coverage for the unlock path and invalidate settle.Test plan
AgentChatPaneregression: shared cache update unlocks Cursor without remount / without extra forcegetStatusAgentChatPaneregression: invalidate settle uses non-force refill onlyaiDiscoveryCache,useProviderAuthStatus) + desktop typecheckSummary by CodeRabbit