test(inspector): expand promise session parity coverage#6491
Conversation
|
Warning Review limit reached
Next review available in: 9 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 Plus Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughThe PR adds a deterministic ChangesInspector Promises parity
Estimated code review effort: 4 (Complex) | ~45 minutes 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 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 `@test-parity/node-suite/inspector-promises/post/argument-validation.ts`:
- Around line 17-36: Preserve synchronous errors in the shared promise
error-capture pattern by rethrowing the caught error so the outer catch logs its
properties instead of awaiting undefined. Apply this change at
test-parity/node-suite/inspector-promises/post/argument-validation.ts:17-36,
test-parity/node-suite/inspector-promises/post/circular-params.ts:8-27, and
test-parity/node-suite/inspector-promises/lifecycle/disconnected.ts:9-28,
wrapping each synchronous call as needed while retaining the existing
asynchronous rejection handling.
🪄 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 Plus
Run ID: e76565e0-189c-466e-87c7-f858c26fe3c1
📒 Files selected for processing (34)
test-parity/node-suite/inspector-promises/EVIDENCE.mdtest-parity/node-suite/inspector-promises/README.mdtest-parity/node-suite/inspector-promises/events/notification-settlement.tstest-parity/node-suite/inspector-promises/lifecycle/disconnected.tstest-parity/node-suite/inspector-promises/lifecycle/pending-disconnect.tstest-parity/node-suite/inspector-promises/lifecycle/reconnect.tstest-parity/node-suite/inspector-promises/lifecycle/repeated-sessions.tstest-parity/node-suite/inspector-promises/lifecycle/sync-control.tstest-parity/node-suite/inspector-promises/post/argument-validation.tstest-parity/node-suite/inspector-promises/post/circular-params.tstest-parity/node-suite/inspector-promises/post/concurrent-order.tstest-parity/node-suite/inspector-promises/post/concurrent-rejection.tstest-parity/node-suite/inspector-promises/post/invalid-protocol-params.tstest-parity/node-suite/inspector-promises/post/optional-params.tstest-parity/node-suite/inspector-promises/post/rejection-identity.tstest-parity/node-suite/inspector-promises/post/settlement-async.tstest-parity/node-suite/inspector-promises/post/unknown-command.tstest-parity/node-suite/inspector-promises/protocol/enable-disable.tstest-parity/node-suite/inspector-promises/protocol/schema-domains.tstest-parity/node-suite/inspector-promises/runtime/await-promise.tstest-parity/node-suite/inspector-promises/runtime/await-rejection.tstest-parity/node-suite/inspector-promises/runtime/exception-details.tstest-parity/node-suite/inspector-promises/runtime/get-properties-release.tstest-parity/node-suite/inspector-promises/runtime/numeric-specials.tstest-parity/node-suite/inspector-promises/runtime/primitives.tstest-parity/node-suite/inspector-promises/runtime/return-by-value.tstest-parity/node-suite/inspector-promises/session/runtime.tstest-parity/node-suite/inspector-promises/surface/constructor.tstest-parity/node-suite/inspector-promises/surface/exports.tstest-parity/node-suite/inspector-promises/surface/inherited-receivers.tstest-parity/node-suite/inspector-promises/surface/post-descriptor.tstest-parity/node-suite/inspector-promises/surface/post-receiver.tstest-parity/node-suite/inspector-promises/surface/session-class.tstest-parity/node_suite_baseline.json
💤 Files with no reviewable changes (1)
- test-parity/node-suite/inspector-promises/session/runtime.ts
Address CodeRabbit: a synchronous throw from session.post() set synchronous=true but discarded the error, leaving pending undefined so 'await pending' resolved and the case logged 'unexpected', losing the asserted name/code. Nest the sync-detection try inside the outer try and re-throw so the real error reaches the logging catch, while pending/synchronous still reflect sync-vs-async accurately.
Summary
node:inspector/promisessmoke case with 30 granular Promise-specific fixturesValidation
994cab8da5deb3aa67bb505560eae5f6d7ee0754dfdd0aad92f4c95266688d49cargo build --releasecargo fmt --all -- --checkdeno fmt --check test-parity/node-suite/inspector-promises test-parity/node_suite_baseline.jsonscripts/check_file_size.shScope
Tests and evidence only. No runtime, compiler, transport, linker, or build behavior changes. Callback-style contracts remain in #6490; profiling, heap/coverage payloads, active debugger waits, external frontends, worker races, and timing-sensitive probes remain excluded.
Summary by CodeRabbit
Tests
Documentation