fix(syncdeck): redirect instructors when sessions end - #321
Conversation
|
Warning Review limit reached
Next review available in: 37 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: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
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.
Pull request overview
Ensures SyncDeck’s instructor/manager view responds to authoritative session termination by redirecting to the shared /session-ended route, and adds Playwright coverage to prevent regressions.
Changes:
- Attach the shared
useSessionEndedHandlerto SyncDeck’s instructor/manager resilient WebSocket connection. - Add a Playwright spec that ends a SyncDeck session and asserts the instructor manager redirects to
/session-ended. - Record the lifecycle discovery in
.agent/knowledge/repo_discoveries.mdfor future refactors.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| activities/syncdeck/client/manager/SyncDeckManager.tsx | Wires attachSessionEndedHandler into the instructor manager’s useResilientWebSocket so session-ended broadcasts redirect the manager. |
| activities/syncdeck/playwright/instructor-session-ended.spec.ts | Adds browser coverage verifying the instructor manager redirects when the session is deleted/ended. |
| .agent/knowledge/repo_discoveries.md | Captures the rationale/expectation that instructors must also attach the shared session-ended handler. |
Suppressed comments (1)
activities/syncdeck/playwright/instructor-session-ended.spec.ts:60
- This test forwards
instructorPasscodefrom anunknownJSON payload into the DELETE call without validating it, and it returns onlyresponse.okon failure. Add a runtime type check + throw with HTTP status to make failures actionable and avoid sending an invalid body.
const { instructorPasscode } = await passcodeResponse.json() as { instructorPasscode?: unknown }
const response = await fetch(`/api/syncdeck/${encodeURIComponent(id)}`, {
method: 'DELETE',
credentials: 'include',
headers: { 'Content-Type': 'application/json' },
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
No description provided.