You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Using experimental ESM HTTPS imports inside experimental vm.Module crashes #43288
How often does it reproduce? Is there a required condition?
Always
What is the expected behavior?
esm https imports work within vm module
What do you see instead?
crashes
node:internal/vm/module:313
if (module[kWrap] === undefined) {
^
TypeError: Cannot read properties of undefined (reading 'Symbol(kWrap)')
at ModuleWrap.<anonymous> (node:internal/vm/module:313:19)
at async Promise.all (index 0)
at async SourceTextModule.<computed> (node:internal/vm/module:330:11)
at async SourceTextModule.link (node:internal/vm/module:197:5)
at async file:///Users/rchen/dev/projects/github.com/Pyrolistical/vm-modules-plus-network-imports/vm-module-network-imports.js:13:1
I see the problem. Its because my linker is returning undefined when the specifier is the https url. The vm module could offer a better error message in that case.
It would be nice there was a default linker we could use that already implements normal esm file/https resolutions and the linker steps simply allows us to override the default.
Activity
Pyrolistical commentedon Jun 1, 2022
I see the problem. Its because my linker is returning
undefinedwhen thespecifieris the https url. The vm module could offer a better error message in that case.It would be nice there was a default linker we could use that already implements normal esm file/https resolutions and the linker steps simply allows us to override the default.