Unify project update invalidation events - #349
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: 43 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 (3)
📝 WalkthroughWalkthroughAdds a "plans" project API view with a shared invalidation-group contract, updates metadata-server mutation handlers to emit route-scoped project_update views/reasons via new helpers, adjusts alert-driven invalidation to use the shared groups, and wires the app's plans registry and screen to the new refresh nonce. ChangesProject-service events parity (plans view invalidation)
Estimated code review effort: 4 (Complex) | ~60 minutes Sequence Diagram(s)sequenceDiagram
participant Client
participant handleRoute
participant notifyCurrentRouteChange
participant projectApiViewsForMutationRoute
participant notifyProjectChanged
Client->>handleRoute: HTTP mutation (e.g. PUT /plans/:sessionId)
handleRoute->>notifyCurrentRouteChange: invoke after mutation succeeds
notifyCurrentRouteChange->>projectApiViewsForMutationRoute: derive views/reason from method + pathname
projectApiViewsForMutationRoute-->>notifyCurrentRouteChange: views (e.g. ["plans"]), reason
notifyCurrentRouteChange->>notifyProjectChanged: publish project_update(views, reason, sessionId)
notifyProjectChanged-->>Client: SSE project_update event
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.
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 `@src/project-api-contract.ts`:
- Around line 228-341: `projectApiViewsForMutationRoute` is missing
`PROJECT_API_ROUTES.livePane.interrupt` from the `agentLifecycle` invalidation
set, so live-pane interrupts only hit the default merge and don’t refresh the
right views. Update the `switch` in `projectApiViewsForMutationRoute` to include
`PROJECT_API_ROUTES.livePane.interrupt` alongside the other agent lifecycle
routes and return `PROJECT_API_VIEW_INVALIDATIONS.agentLifecycle` for it.
🪄 Autofix (Beta)
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: defaults
Review profile: CHILL
Plan: Pro
Run ID: 97ed277c-d270-4789-90a8-379049cc8b25
📒 Files selected for processing (9)
app/app/(main)/(tabs)/(dashboard)/plans/[sessionId].tsxapp/stores/projectViews.test.tsapp/stores/projectViews.tsdocs/north-star-completion-tracker.mdsrc/metadata-server.test.tssrc/metadata-server.tssrc/project-api-contract.test.tssrc/project-api-contract.tssrc/project-events.ts
|
Deployment failed with the following error: Learn More: https://vercel.com/sams-projects-de5e5436?upgradeToPro=build-rate-limit |
Summary
Verification
Summary by CodeRabbit
New Features
Bug Fixes
Documentation