Scope app project view refreshes - #328
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 27 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. 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: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThe project view refresh mechanism moves from a single global nonce atom to a per-view atomFamily, allowing refresh triggers to target specific views. Screens now read view-scoped nonces, and action handlers across agent, service, teammate, workflow, and worktree components pass explicit view lists to refresh functions instead of refreshing all views. ChangesView-scoped project refresh nonces
Estimated code review effort: 3 (Moderate) | ~25 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
@coderabbitai review |
✅ Action performedReview finished.
|
There was a problem hiding this comment.
🧹 Nitpick comments (1)
app/components/agent-actions.tsx (1)
59-67: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win
graveyardis refreshed even for non-kill actions.The same view list is used for stop/resume/fork/kill, but only kill semantically affects
graveyard. This mirrors magic-string duplication also present inagent-create-panel.tsxandagent-management-panel.tsx. Consider centralizing action→views mappings (e.g. inprojectViews.ts) so each call site references a shared constant instead of repeating similar literal arrays, and vary the list byopts?.isKillifgraveyardshould only apply there.♻️ Example scoping by action
- kickProjectViewRefresh([ - "agents", - "project-observability", - "topology", - "coordination-worklist", - "graveyard", - "team", - "worktrees", - ]); + kickProjectViewRefresh( + opts?.isKill + ? AGENT_ACTION_REFRESH_VIEWS_WITH_GRAVEYARD + : AGENT_ACTION_REFRESH_VIEWS, + );🤖 Prompt for 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. In `@app/components/agent-actions.tsx` around lines 59 - 67, The shared view refresh list in agent-actions.tsx is incorrectly including graveyard for every action, even when the action is not a kill. Update the logic around the action handler in agent-actions.tsx so the views passed to kickProjectViewRefresh vary by opts?.isKill, and only include graveyard for kill actions. If possible, centralize the action-to-views mapping in a shared constant or helper such as projectViews.ts, then update the similar literal arrays in agent-create-panel.tsx and agent-management-panel.tsx to use that shared source instead of duplicating the list.
🤖 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.
Nitpick comments:
In `@app/components/agent-actions.tsx`:
- Around line 59-67: The shared view refresh list in agent-actions.tsx is
incorrectly including graveyard for every action, even when the action is not a
kill. Update the logic around the action handler in agent-actions.tsx so the
views passed to kickProjectViewRefresh vary by opts?.isKill, and only include
graveyard for kill actions. If possible, centralize the action-to-views mapping
in a shared constant or helper such as projectViews.ts, then update the similar
literal arrays in agent-create-panel.tsx and agent-management-panel.tsx to use
that shared source instead of duplicating the list.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: a2adf771-47be-49fa-97ee-b3a0c47325e0
📒 Files selected for processing (15)
app/app/(main)/(tabs)/(threads)/threads.tsxapp/app/(main)/(tabs)/coordination/index.tsxapp/app/(main)/(tabs)/library/index.tsxapp/app/(main)/(tabs)/project/index.tsxapp/app/(main)/(tabs)/topology/index.tsxapp/app/(main)/_layout.tsxapp/components/agent-actions.tsxapp/components/agent-create-panel.tsxapp/components/agent-management-panel.tsxapp/components/service-actions.tsxapp/components/teammate-panel.tsxapp/components/workflow-actions.tsxapp/components/worktree-management-panel.tsxapp/stores/projectViews.test.tsapp/stores/projectViews.ts
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
Summary
Verification
Summary by CodeRabbit
New Features
Bug Fixes