Title: Assertion failed: !(handle->flags & UV_HANDLE_CLOSING), file src\win\async.c, line 76 · Issue #64322 · nodejs/node · GitHub
Open Graph Title: Assertion failed: !(handle->flags & UV_HANDLE_CLOSING), file src\win\async.c, line 76 · Issue #64322 · nodejs/node
X Title: Assertion failed: !(handle->flags & UV_HANDLE_CLOSING), file src\win\async.c, line 76 · Issue #64322 · nodejs/node
Description: Version v24 LTS/default Platform Subsystem No response What steps will reproduce the bug? Node.js process crash on build exit: Assertion failed: !(handle->flags & UV_HANDLE_CLOSING) on Windows Environment Info OS: Windows 11 (build local...
Open Graph Description: Version v24 LTS/default Platform Subsystem No response What steps will reproduce the bug? Node.js process crash on build exit: Assertion failed: !(handle->flags & UV_HANDLE_CLOSING) on Windows Envi...
X Description: Version v24 LTS/default Platform Subsystem No response What steps will reproduce the bug? Node.js process crash on build exit: Assertion failed: !(handle->flags & UV_HANDLE_CLOSING) on Windo...
Opengraph URL: https://github.com/nodejs/node/issues/64322
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Assertion failed: !(handle->flags & UV_HANDLE_CLOSING), file src\\win\\async.c, line 76","articleBody":"### Version\n\nv24 LTS/default\n\n### Platform\n\n```text\n\n```\n\n### Subsystem\n\n_No response_\n\n### What steps will reproduce the bug?\n\n# Node.js process crash on build exit: `Assertion failed: !(handle->flags & UV_HANDLE_CLOSING)` on Windows\n\n## Environment Info\n\n- **OS**: Windows 11 (build local time check: 2026-07-06)\n- **Node.js Version**: v24.13.0\n- **npm Version**: 11.x (or matching Node v24 default)\n- **Framework/Tooling**: Astro `^7.0.6` with Svelte `^5.56.4` integration\n- **Libraries in play**: curtainsjs `^8.1.6`, gsap `^3.15.0`, lenis `^1.3.25`\n\n---\n\n## Description\n\nWhen running `npm run build` (which runs `astro check && astro build`), the static assets compile successfully with **0 errors and 0 warnings**. However, immediately after the compilation output shows `[build] Complete!`, the process crashes during termination with a low-level libuv assertion error.\n\n### Error Console Output\n\n```bash\ngenerating static routes \n14:11:19 ├─ /index.html (+38ms) \n14:11:19 ✓ Completed in 131ms.\n\n14:11:19 [build] ✓ Completed in 452ms.\n14:11:19 [build] 1 page(s) built in 531ms\n14:11:19 [build] Complete!\nAssertion failed: !(handle->flags & UV_HANDLE_CLOSING), file src\\win\\async.c, line 76\n```\n\n---\n\n## How to Recreate This Issue\n\nThis issue can be reproduced on any Windows system with Node.js `v24.x` using a fresh Astro template:\n\n1. **Initialize a fresh Astro project:**\n ```bash\n npm create astro@latest test-crash -- --template basics\n cd test-crash\n npm install\n ```\n\n2. **Run the build script:**\n ```bash\n npm run build\n ```\n\n3. **Verify the crash:**\n Once the build completes and attempts to exit the process, the console will print:\n `Assertion failed: !(handle->flags & UV_HANDLE_CLOSING), file src\\win\\async.c, line 76` and exit with code `1`.\n\n---\n\n## Additional Context\n\n- The issue appears to be a **use-after-close** race condition when Node.js tear-down steps close file-watchers or active handles created by Vite/Astro.\n- Since the build completes successfully, all output artifacts are generated correctly. The crash only occurs on process exit.\n- This is a known OS-specific issue for Windows runtimes inside libuv.\n\n\n### How often does it reproduce? Is there a required condition?\n\nEvery build\n\n### What is the expected behavior? Why is that the expected behavior?\n\nNo errors.\n\n### What do you see instead?\n\n`Assertion failed: !(handle->flags & UV_HANDLE_CLOSING), file src\\win\\async.c, line 76` and exit with code `1`.\n\n### Additional information\n\n**What steps will reproduce the bug?** section include the output of an agent, every reference/explanation is there.\n\n\u003cimg width=\"628\" height=\"140\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/6d705461-bcf1-4b82-97e8-dcbabf567898\" />\n","author":{"url":"https://github.com/ostarev","@type":"Person","name":"ostarev"},"datePublished":"2026-07-06T12:38:07Z","url":"https://github.com/nodejs/node/issues/64322"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b8b54f26-e8c3-ba6f-edf2-cef92adc601f |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9AFE:3EED53:64B703:86590B:6AED1F69 |
| html-safe-nonce | 4c043d225c2a15bda1fdb222b84c16634e56a96eaebce8b577427ab80e574166 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5QUZFOjNFRUQ1Mzo2NEI3MDM6ODY1OTBCOjZBRUQxRjY5IiwidmlzaXRvcl9pZCI6Ijk5NDgzNTkwNTM2Nzk4MDU3IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 10946a46d6c1f26a380118d1a4f1e2524f0a9edf0a002b90c6bc66c5582537e9 |
| hovercard-subject-tag | issue:4819195619 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nodejs/node/64322/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e753bae66231dd314f41857295c99f78aee0da5b849dcff8a3afca05c489512f/nodejs/node/issues/64322 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e753bae66231dd314f41857295c99f78aee0da5b849dcff8a3afca05c489512f/nodejs/node/issues/64322 |
| og:image:alt | Version v24 LTS/default Platform Subsystem No response What steps will reproduce the bug? Node.js process crash on build exit: Assertion failed: !(handle->flags & UV_HANDLE_CLOSING) on Windows Envi... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ostarev |
| hostname | github.com |
| expected-hostname | github.com |
| None | e3e0f7f63e50c6fe879198a93a0a023a648ecc0a5e9bc3b5e033ac57172237e6 |
| turbo-cache-control | no-preview |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 707a24b346ac8a82878b9c084efaa38a997660cb |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width