Repository navigation
fix: preserve profile scope when deleting sessions - #652
Conversation
|
@richardfogaca is attempting to deploy a commit to the Compozy Team on Vercel. A member of the Team first needs to authorize it. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: ⛔ Files ignored due to path filters (4)
📒 Files selected for processing (4)
🚧 Files skipped from review as they are similar to previous changes (2)
Included review availability: Your plan provides up to 8 included reviews per hour; 7 remain after this review. WalkthroughSession deletion now carries the session workspace and profile through the web mutation and DELETE request. The API specification adds profile selection. Lifecycle, route, adapter, and hook tests verify profile-scoped deletion and payload propagation. ChangesSession deletion
Priority: ➖ Normal Estimated code review effort: 3 (Moderate) | ~20 minutes Change: Bug fix · Severity of issue fixed: Medium Merge Risk: ⚪ Minimal · up to Profile-scoped session deletion is consistently propagated and reconciled across the reviewed paths, with no remaining merge-blocking risk identified. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
🧪 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 |
Greptile SummarySession deletion now keeps each session’s workspace and profile from confirmation through the final request. This fixes non-default profile deletions and refreshes the right catalogs after success.
Confidence Score: 5/5The PR appears safe to merge. Deletion keeps the target profile and refreshes each affected session view. No new issue remains. Both earlier threads were manually resolved without explanation, and the current changes address their reported cases. Important Files Changed
Sequence DiagramsequenceDiagram
actor User
participant Web
participant API
participant Store
participant Cache
User->>Web: Confirm session deletion
Web->>Web: Read target workspace and profile
Web->>Store: Pause live updates for session
Web->>API: "DELETE /workspaces/{workspace}/sessions/{id}?profile={profile}"
API-->>Web: 204 No Content
Web->>Store: Remove session and resume live updates
Web->>Cache: Remove detail and ID queries
Web->>Cache: Refresh owner workspace lists
Web->>Cache: Refresh global lists and attention count
Web-->>User: Remove row and show success
Reviews (2): Last reviewed commit: "fix: reconcile session deletion views an..." | Re-trigger Greptile |
What & why
Fixes #651. Deleting a session owned by a non-default profile returned “Session not found” because Web omitted the profile and the API resolved the request to
default.Single and bulk deletion now carry the target session’s profile and workspace through confirmation, mutation, and cache reconciliation. The API contract declares the already-supported optional profile query; generated OpenAPI and Web types are included. Backend authorization remains unchanged. Successful deletion also refreshes global catalogs and attention counts without relying on the catalog stream. QA screenshots have distinct profile names, and the lifecycle E2E matcher checks the DELETE pathname and profile separately.
Implemented and validated by Richard’s agent; no human verification is claimed.
How you verified it
make gateunder Node 22: code generation consistency, scoped Go lint/race tests, Web lint/typecheck/tests.Follow-up validation:
make gatepassed under Node 22 (7,316 Web tests, lint/typecheck, codegen and scoped Go checks). Regression coverage verifies cache invalidation and leaves unrelated workspace catalogs untouched. The Web CI timeout came from matching a DELETE URL without its new profile query. The Desktop bootstrap-quit failure is separate: the identical base passed that job, but a targeted rerun was rejected with HTTP 403 (repository admin rights required). Its outcome remains unverified pending the next PR run. Vercel deployment requires team authorization.Impact
Web deletion and its declared API query parameter. Existing HTTP/UDS behavior and profile authorization remain intact; no migration, configuration, hook, CLI, SDK implementation, or official skill syntax change. The affected QA scenario and cross-surface audit are updated. Other session lifecycle actions are outside this fix.
Risk is limited to deletion target propagation and reconciliation. Existing failure/retry and observer-suppression coverage is retained. Reverting this change restores the previous Web request behavior without changing stored data.
make gatepasses locally; this PR is delivered only after its required CI checks are green — local gate passes; current-head CI remains pending and is not claimed green.Summary by CodeRabbit