feat(judge): load an authenticated session for browser review (storage_state)#273
Conversation
…e_state) Browser-judges on auth-gated apps only ever reached the login redirect — an unauthenticated headless browser has no session. Add an opt-in `verify.dev_server.storage_state` (repo-root-relative or absolute): a Playwright storageState file (cookies + localStorage) that the judge's @playwright/mcp loads via --storage-state, so it reviews the app logged-in. - DevServerConfig.storage_state + loader. - _augment_playwright_args injects --storage-state (idempotent; operator args win). - _populate_browser_context resolves the path and fails closed: configured-but- missing → [BROWSER UNAVAILABLE] with an actionable reason (generate the session, e.g. an e2e auth-setup task), rather than wasting the pass on login pages. Unset → logged-out browsing as before (fine for public apps). cube only consumes the file; generating it is out of band (reuse the e2e suite's auth setup). 5 new tests; automation+core suites green (499 passed). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Warning Review limit reached
More reviews will be available in 49 minutes and 25 seconds. Learn how PR review limits work. Your organization has run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (4)
Comment |
What
Browser-judges on auth-gated apps only ever reached the login redirect — an unauthenticated headless browser has no session. This adds opt-in
verify.dev_server.storage_state: a Playwright storageState file (cookies + localStorage) the judge's@playwright/mcploads via--storage-state, so it reviews the app logged-in.Changes
DevServerConfig.storage_state+ loader._augment_playwright_argsinjects--storage-state(idempotent; operator args win)._populate_browser_contextresolves the path (repo-root-relative or absolute) and fails closed: configured-but-missing →[BROWSER UNAVAILABLE]with an actionable reason (generate the session first) rather than wasting the pass on login pages. Unset → logged-out browsing as before (fine for public apps).cube only consumes the file; generating it is out of band (reuse the app's e2e auth setup).
Tests
5 new (
--storage-stateinject / omit / idempotent). Automation + core suites green (499 passed).🤖 Generated with Claude Code