[GH-ISSUE #23] Windows support? #10

Closed
opened 2026-05-06 12:36:27 +02:00 by BreizhHardware · 2 comments

Originally created by @ArjandenHartog on GitHub (Feb 24, 2026).
Original GitHub issue: https://github.com/cloudflare/vinext/issues/23

$ NODE_OPTIONS='--max-old-space-size=8192 --no-deprecation --no-warnings' vinext dev -p 4000
Error [ERR_UNSUPPORTED_ESM_URL_SCHEME]: Only URLs with a scheme in: file, data, and node are supported by the default ESM loader. On Windows, absolute paths must be valid file:// URLs. Received protocol 'c:'
at throwIfUnsupportedURLScheme (node:internal/modules/esm/load:195:11)
at defaultLoadSync (node:internal/modules/esm/load:142:3)
at #loadAndMaybeBlockOnLoaderThread (node:internal/modules/esm/loader:795:12)
at #loadSync (node:internal/modules/esm/loader:815:49)
at ModuleLoader.load (node:internal/modules/esm/loader:780:26)
at ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:526:31)
at #getOrCreateModuleJobAfterResolve (node:internal/modules/esm/loader:571:36)
at afterResolve (node:internal/modules/esm/loader:624:52)
at ModuleLoader.getOrCreateModuleJob (node:internal/modules/esm/loader:630:12)
at onImport.tracePromise.proto (node:internal/modules/esm/loader:649:32) {
code: 'ERR_UNSUPPORTED_ESM_URL_SCHEME'
}
error: script "dev" exited with code 1

Originally created by @ArjandenHartog on GitHub (Feb 24, 2026). Original GitHub issue: https://github.com/cloudflare/vinext/issues/23 $ NODE_OPTIONS='--max-old-space-size=8192 --no-deprecation --no-warnings' vinext dev -p 4000 Error [ERR_UNSUPPORTED_ESM_URL_SCHEME]: Only URLs with a scheme in: file, data, and node are supported by the default ESM loader. On Windows, absolute paths must be valid file:// URLs. Received protocol 'c:' at throwIfUnsupportedURLScheme (node:internal/modules/esm/load:195:11) at defaultLoadSync (node:internal/modules/esm/load:142:3) at #loadAndMaybeBlockOnLoaderThread (node:internal/modules/esm/loader:795:12) at #loadSync (node:internal/modules/esm/loader:815:49) at ModuleLoader.load (node:internal/modules/esm/loader:780:26) at ModuleLoader.loadAndTranslate (node:internal/modules/esm/loader:526:31) at #getOrCreateModuleJobAfterResolve (node:internal/modules/esm/loader:571:36) at afterResolve (node:internal/modules/esm/loader:624:52) at ModuleLoader.getOrCreateModuleJob (node:internal/modules/esm/loader:630:12) at onImport.tracePromise.__proto__ (node:internal/modules/esm/loader:649:32) { code: 'ERR_UNSUPPORTED_ESM_URL_SCHEME' } error: script "dev" exited with code 1
Author
Owner

@niicojs commented on GitHub (Feb 24, 2026):

https://github.com/cloudflare/vinext/pull/27

<!-- gh-comment-id:3954995526 --> @niicojs commented on GitHub (Feb 24, 2026): https://github.com/cloudflare/vinext/pull/27
Author
Owner

@southpolesteve commented on GitHub (Feb 25, 2026):

Fixed in #31 — the root cause was that all our dynamic import() calls were passing bare Windows absolute paths (C:...) instead of file:// URLs. Node's ESM loader requires file:// URLs on Windows. We wrapped every call site with pathToFileURL() and added a Windows runner to CI for an E2E test so this won't regress. Thanks for reporting this with the clear stack trace, that made it easy to confirm the fix!

<!-- gh-comment-id:3959736510 --> @southpolesteve commented on GitHub (Feb 25, 2026): Fixed in #31 — the root cause was that all our dynamic import() calls were passing bare Windows absolute paths (C:\...) instead of file:// URLs. Node's ESM loader requires file:// URLs on Windows. We wrapped every call site with pathToFileURL() and added a Windows runner to CI for an E2E test so this won't regress. Thanks for reporting this with the clear stack trace, that made it easy to confirm the fix!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/vinext#10
No description provided.