We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e2c9cab commit 9e1fbb6Copy full SHA for 9e1fbb6
lib/internal/modules/esm/loader.js
@@ -462,6 +462,10 @@ class ModuleLoader {
462
const resolvedImportAttributes = resolveResult.importAttributes ?? importAttributes;
463
let job = this.loadCache.get(url, resolvedImportAttributes.type);
464
if (job !== undefined) {
465
+ // TODO(node:55782): this race may stop happening when the ESM resolution and loading become synchronous.
466
+ if (!job.module) {
467
+ assert.fail(getRaceMessage(url, parentURL));
468
+ }
469
// This module is being evaluated, which means it's imported in a previous link
470
// in a cycle.
471
if (job.module.getStatus() === kEvaluating) {
0 commit comments