Version
v23.10.0
Platform
Microsoft Windows NT 10.0.26100.0 x64
Subsystem
No response
What steps will reproduce the bug?
mod.js
testcase.js
import { createRequire } from 'module'
const require = createRequire(import.meta.url)
require('./mod.js?1')
const key = Object.keys(require.cache)[0]
delete require.cache[key]
require('./mod.js?2')
How often does it reproduce? Is there a required condition?
Every time.
What is the expected behavior? Why is that the expected behavior?
What do you see instead?
Additional information
I traced it to this line, which just fully ignores source.
|
if (status === kEvaluated) { |
|
return { wrap: job.module, namespace: job.module.getNamespaceSync(filename, parentFilename) }; |
Version
v23.10.0
Platform
Subsystem
No response
What steps will reproduce the bug?
mod.jstestcase.jsHow often does it reproduce? Is there a required condition?
Every time.
What is the expected behavior? Why is that the expected behavior?
What do you see instead?
Additional information
I traced it to this line, which just fully ignores
source.node/lib/internal/modules/esm/loader.js
Lines 390 to 391 in eab0fe2