Skip to content

fix(windows-v8): pump the V8 platform's foreground tasks - #51

Merged
triniwiz merged 1 commit into
mainfrom
fix/windows-v8-platform-tasks
Nov 11, 2026
Merged

triniwiz merged 1 commit into
mainfrom
fix/windows-v8-platform-tasks

Conversation

@triniwiz

Copy link
Copy Markdown
Member

The standalone windows-v8 runtime never pumped V8's platform, so foreground tasks (FinalizationRegistry cleanup, GC finalization, the memory reducer) never ran.

  • platform::initialize keeps the platform for the process; platform::pump runs the isolate's queued tasks.
  • The event loop's drain hook now runs a microtask checkpoint, pumps the platform, then drains the microtasks those tasks queued.
  • js_get_isolate in the shim exposes the isolate to Rust.

Test: nativescript-windows packages/test/finalization-check.js prints finalization-check: PASS.

FinalizationRegistry cleanup, GC finalization and the memory reducer post
foreground tasks to the platform, which the standalone event loop never
ran. The drain hook now pumps the platform after the microtask checkpoint.
Adds packages/test/finalization-check.js.
@coderabbitai

coderabbitai Bot commented Nov 11, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 9bfc61ec-c9b5-447f-ab8b-6133a74ede8f

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@triniwiz
triniwiz merged commit 2e9c998 into main Nov 11, 2026
1 check passed
@triniwiz
triniwiz deleted the fix/windows-v8-platform-tasks branch November 11, 2026 13:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant