Skip to content

Commit ea2dc60

Browse files
committed
webpackIgnore?
1 parent ffc8f61 commit ea2dc60

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

packages/node/src/integrations/localvariables/localvariables-async.ts

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,6 @@ import type { NodeClientOptions } from '../../types';
88
import type { FrameVariables, Options, PausedExceptionEvent, RateLimitIncrement, Variables } from './common';
99
import { createRateLimiter, functionNamesMatch, hashFrames, hashFromStack } from './common';
1010

11-
/**
12-
* When targeting older versions of node, webpack will throw an error if we try to import libraries that are not available
13-
*/
14-
function dynamicImport<T>(module: string): Promise<T> {
15-
return import(module);
16-
}
17-
1811
async function unrollArray(session: Session, objectId: string, name: string, vars: Variables): Promise<void> {
1912
const properties: Runtime.GetPropertiesReturnType = await session.post('Runtime.getProperties', {
2013
objectId,
@@ -102,7 +95,7 @@ export class LocalVariablesAsync implements Integration {
10295
return;
10396
}
10497

105-
dynamicImport<{ Session: typeof Session }>('node:inspector/promises')
98+
import(/* webpackIgnore: true */ 'node:inspector/promises')
10699
.then(({ Session }) => this._startDebugger(new Session(), clientOptions))
107100
.catch(e => logger.error('Failed to load inspector API', e));
108101
}

0 commit comments

Comments
 (0)