Skip to content

test(v8): expand granular Node parity coverage#6485

Open
TheHypnoo wants to merge 3 commits into
mainfrom
test/expand-node-v8-parity
Open

test(v8): expand granular Node parity coverage#6485
TheHypnoo wants to merge 3 commits into
mainfrom
test/expand-node-v8-parity

Conversation

@TheHypnoo

@TheHypnoo TheHypnoo commented Jul 16, 2026

Copy link
Copy Markdown
Member

Summary

  • expand the granular node:v8 parity suite from 4 to 46 deterministic fixtures
  • cover exports/classes, structured clone semantics, serializer lifecycle, heap diagnostics and snapshots, promise hooks, GC profiling, version flags, string representation, and startup snapshot boundaries
  • pin Node 26.5.0, Deno, and Bun primary-source evidence and document meaningful engine divergences and exclusions
  • move v8 into the sequential runner lane and ratchet the measured baseline from 4/4 to 14/46

Coverage

  • exports and classes: 8
  • structured clone helpers: 12
  • Serializer/Deserializer lifecycle: 8
  • heap diagnostics and snapshots: 7
  • promise hooks: 5
  • GCProfiler: 2
  • version flags: 2
  • string representation: 1
  • startup snapshots: 1

Verification

  • Node 26.5.0 syntax checks pass for all 46 fixtures
  • repeated Node oracle runs are byte-identical (bfff20a44ab6c45f283841fbdc092aca7a096eb031c2fe31525129d046f95c76)
  • repeated focused Perry runs are identical: 14/46, with 31 diffs and 1 runtime timeout bucket
  • detailed classification: 14 passes, 30 output mismatches, one stable serialize/builtins SIGSEGV, one stable serialize/references-cycles timeout, zero compile failures
  • deno fmt --check test-parity/node-suite/v8
  • cargo fmt --all -- --check
  • release compiler/runtime package build
  • JSON and baseline/count invariants
  • Rust file-size gate and git diff --check
  • no generated heap snapshots or temporary artifacts

Intentional boundaries

Exact serialized bytes, volatile heap sizes, GC/finalization timing, retention counts, raw profiler/coverage payloads, near-OOM behavior, stress/concurrency, private host-object hooks, and startup snapshot building remain outside this deterministic lane. Heap snapshot resources and temporary files are cleaned up through failure-safe paths.

Summary by CodeRabbit

  • Tests

    • Expanded Node.js V8 compatibility coverage across serialization, heap statistics, heap snapshots, promise hooks, startup snapshots, strings, version tags, and runtime classes.
    • Added validation for supported inputs, error handling, object identity, lifecycle behavior, and data-shape consistency.
    • Updated parity tracking to include 46 V8 fixtures with improved baseline results.
  • Documentation

    • Added guidance on suite scope, supported compatibility targets, intentional differences, and validation practices.
  • Refactor

    • V8 parity checks now run sequentially for more deterministic results and safer handling of process-wide runtime state.

@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@TheHypnoo, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 7 seconds

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

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 configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 75249986-37f1-488c-9a49-0df7603894e7

📥 Commits

Reviewing files that changed from the base of the PR and between 1d506a3 and 9b8f5a7.

📒 Files selected for processing (3)
  • test-parity/node-suite/v8/serializer/release-reuse.ts
  • test-parity/node-suite/v8/serializer/validation.ts
  • test-parity/node_suite_baseline.json
📝 Walkthrough

Walkthrough

The PR adds 46 node:v8 parity fixtures covering exports, classes, serialization, heap diagnostics, promise hooks, strings, version tags, and startup snapshots. It documents the suite, moves it to sequential execution, and updates the baseline from 4 to 46 fixtures.

Changes

node:v8 parity suite

Layer / File(s) Summary
Suite contract and execution baseline
test-parity/node-suite/v8/README.md, scripts/node_suite_run.py, test-parity/node_suite_baseline.json
Documents the oracle, coverage, exclusions, validation results, and cleanup rules; runs v8 sequentially and records 46 fixtures.
Module, class, and profiler surfaces
test-parity/node-suite/v8/exports/*, test-parity/node-suite/v8/classes/*, test-parity/node-suite/v8/gc-profiler/*
Adds checks for exports, descriptors, import identity, constructors, prototypes, receiver validation, inheritance, and GCProfiler lifecycle behavior.
Value serialization and deserialization
test-parity/node-suite/v8/serialize/*
Adds round-trip and error fixtures for primitives, built-ins, collections, buffers, typed arrays, errors, shared references, cycles, and invalid inputs.
Serializer stream APIs
test-parity/node-suite/v8/serializer/*
Adds coverage for headers, wire versions, raw values and views, input views, buffer transfer, release reuse, and validation errors.
Heap snapshots and statistics
test-parity/node-suite/v8/heap-snapshot/*, test-parity/node-suite/v8/heap-statistics/*
Adds heap snapshot schema, stream lifecycle, cleanup, statistics shape, numeric invariants, supported modes, and invalid-input checks.
Promise hooks and runtime utilities
test-parity/node-suite/v8/promise-hooks/*, test-parity/node-suite/v8/strings/*, test-parity/node-suite/v8/version-tag/*, test-parity/node-suite/v8/startup-snapshot/*
Adds promise hook surface, validation, parent tracking, lifecycle ordering, string representation, version-tag, and startup-snapshot checks.

Estimated code review effort: 4 (Complex) | ~60 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: expanding granular Node v8 parity coverage.
Description check ✅ Passed The description covers summary, coverage, verification, and boundaries, but it omits the template's Changes, Related issue, Test plan, and Checklist sections.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch test/expand-node-v8-parity

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
test-parity/node_suite_baseline.json (1)

7-11: 🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win

Update the overall baseline totals to reflect the v8 module changes.

The v8 module's metrics were updated, adding 10 to pass and 42 to total, but the overall metrics were not updated to match. The overall metrics should be updated to maintain data consistency.

📝 Proposed fix to update overall metrics
   "overall": {
-    "pass": 2810,
-    "total": 2863,
-    "pct": 98.1
+    "pass": 2820,
+    "total": 2905,
+    "pct": 97.1
   },
🤖 Prompt for 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.

In `@test-parity/node_suite_baseline.json` around lines 7 - 11, Update the overall
metrics object in node_suite_baseline.json to incorporate the v8 module changes:
increase pass by 10 and total by 42, then recalculate pct from those updated
totals so the aggregate remains consistent.
🤖 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/v8/serializer/release-reuse.ts`:
- Line 1: Explicitly import Buffer from node:buffer in
test-parity/node-suite/v8/serializer/release-reuse.ts at lines 1-1 for the
Buffer.isBuffer call, and in test-parity/node-suite/v8/serializer/validation.ts
at lines 1-1 for the Buffer.alloc call; no other changes are needed.

---

Outside diff comments:
In `@test-parity/node_suite_baseline.json`:
- Around line 7-11: Update the overall metrics object in
node_suite_baseline.json to incorporate the v8 module changes: increase pass by
10 and total by 42, then recalculate pct from those updated totals so the
aggregate remains consistent.
🪄 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: ed1c261d-0c87-495c-b5a9-ad44cf2476cf

📥 Commits

Reviewing files that changed from the base of the PR and between 77def53 and 1d506a3.

📒 Files selected for processing (48)
  • scripts/node_suite_run.py
  • test-parity/node-suite/v8/README.md
  • test-parity/node-suite/v8/classes/constructor-validation.ts
  • test-parity/node-suite/v8/classes/instances-inheritance.ts
  • test-parity/node-suite/v8/classes/prototypes.ts
  • test-parity/node-suite/v8/classes/receiver-validation.ts
  • test-parity/node-suite/v8/exports/descriptors.ts
  • test-parity/node-suite/v8/exports/diagnostics-surface.ts
  • test-parity/node-suite/v8/exports/import-identity.ts
  • test-parity/node-suite/v8/exports/public-surface.ts
  • test-parity/node-suite/v8/gc-profiler/dispose.ts
  • test-parity/node-suite/v8/heap-snapshot/output.ts
  • test-parity/node-suite/v8/heap-snapshot/semantic-schema.ts
  • test-parity/node-suite/v8/heap-snapshot/twice.ts
  • test-parity/node-suite/v8/heap-statistics/code-shape.ts
  • test-parity/node-suite/v8/heap-statistics/cpp-shape.ts
  • test-parity/node-suite/v8/heap-statistics/general-shape.ts
  • test-parity/node-suite/v8/heap-statistics/spaces-shape.ts
  • test-parity/node-suite/v8/promise-hooks/completion-order.ts
  • test-parity/node-suite/v8/promise-hooks/init-parent.ts
  • test-parity/node-suite/v8/promise-hooks/lifecycle-order.ts
  • test-parity/node-suite/v8/promise-hooks/surface.ts
  • test-parity/node-suite/v8/promise-hooks/validation.ts
  • test-parity/node-suite/v8/serialize/buffers-views.ts
  • test-parity/node-suite/v8/serialize/builtins.ts
  • test-parity/node-suite/v8/serialize/corrupt-input.ts
  • test-parity/node-suite/v8/serialize/error-like.ts
  • test-parity/node-suite/v8/serialize/float16-array.ts
  • test-parity/node-suite/v8/serialize/invalid-input.ts
  • test-parity/node-suite/v8/serialize/invalid-values.ts
  • test-parity/node-suite/v8/serialize/map-set.ts
  • test-parity/node-suite/v8/serialize/objects-collections.ts
  • test-parity/node-suite/v8/serialize/primitives.ts
  • test-parity/node-suite/v8/serialize/references-cycles.ts
  • test-parity/node-suite/v8/serialize/typed-arrays.ts
  • test-parity/node-suite/v8/serializer/header-values.ts
  • test-parity/node-suite/v8/serializer/input-view-family.ts
  • test-parity/node-suite/v8/serializer/raw-primitives.ts
  • test-parity/node-suite/v8/serializer/raw-views.ts
  • test-parity/node-suite/v8/serializer/release-reuse.ts
  • test-parity/node-suite/v8/serializer/transfer-array-buffer.ts
  • test-parity/node-suite/v8/serializer/validation.ts
  • test-parity/node-suite/v8/serializer/wire-version.ts
  • test-parity/node-suite/v8/startup-snapshot/shape.ts
  • test-parity/node-suite/v8/strings/one-byte.ts
  • test-parity/node-suite/v8/version-tag/flags-isolated.ts
  • test-parity/node-suite/v8/version-tag/stability.ts
  • test-parity/node_suite_baseline.json

Comment thread test-parity/node-suite/v8/serializer/release-reuse.ts
@proggeramlug proggeramlug added the ready PR triaged: CodeRabbit feedback + conflicts addressed label Jul 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready PR triaged: CodeRabbit feedback + conflicts addressed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants