fix(visibility): keep debug library identities out of normal state - #7112
Conversation
|
Warning Review limit reached
Next review available in: 47 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. 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: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughThe engine now exposes authorized debug library-card identities through derived views. Normal library objects remain redacted. WASM initializes permissions by game mode, and the client viewer renders the projection directly. ChangesDebug library projection
Estimated code review effort: 3 (Moderate) | ~25 minutes Sequence Diagram(s)sequenceDiagram
participant Viewer
participant WASM
participant DerivedViews
participant Client
Viewer->>WASM: open debug library
WASM->>DerivedViews: build filtered viewer snapshot
DerivedViews-->>WASM: debug_library_cards projection
WASM-->>Client: ClientGameStateRef
Client->>Client: shuffle and render projected cards
Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 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 |
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 `@crates/engine-wasm/src/lib.rs`:
- Around line 1875-1880: Update the restore logic around the legacy permission
backfill to distinguish saves that predate debug_permitted from current saves
with an intentionally empty set. Use the save-version or presence metadata
required by CLAUDE.md to backfill sandbox seats only for legacy payloads, while
preserving current sandbox permissions unchanged.
🪄 Autofix
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: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 5e5b75d0-3be4-4adf-a73f-ce5a72d1b53a
📒 Files selected for processing (6)
client/src/adapter/types.tsclient/src/components/chrome/DebugLibraryViewer.tsxclient/src/components/chrome/DebugPlayerActions.tsxcrates/engine-wasm/src/lib.rscrates/engine/src/game/derived_views.rscrates/engine/src/game/visibility.rs
|
Generated for head Parse changes introduced by this PR✓ No card-parse changes detected. |
Summary by CodeRabbit