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 d69398a commit fd2e330Copy full SHA for fd2e330
lib/internal/modules/run_main.js
@@ -174,7 +174,8 @@ function executeUserEntryPoint(main = process.argv[1]) {
174
const source = cjsLoader.entryPointSource;
175
const { shouldRetryAsESM } = require('internal/modules/helpers');
176
retryAsESM = shouldRetryAsESM(error.message, source);
177
- // In case the entry point is a large file, such as a bundle, release it from memory since we're done with it.
+ // In case the entry point is a large file, such as a bundle,
178
+ // ensure no further references can prevent it being garbage-collected.
179
cjsLoader.entryPointSource = undefined;
180
if (!retryAsESM) {
181
const { enrichCJSError } = require('internal/modules/esm/translators');
0 commit comments