Skip to content

bootstrap-node.js should check check for Array.isArray in removeGlobalNodeModuleLookupPaths #165288

@MarkZuber

Description

@MarkZuber

Does this issue occur when all extensions are disabled?: Yes/No

  • VS Code Version: 1.72 (latest main)
  • OS Version: macOS 12.6.1

Steps to Reproduce:

  1. yarn && yarn watch
  2. ./scripts/code.sh

In the console output logs, we've been seeing failures at startup like this:

[85180:1102/151514.317775:INFO:CONSOLE(231)] "%c  ERR color: #f33 [Extension Host] TypeError: Cannot read properties of null (reading 'length')
	at Module._resolveLookupPaths (/Users/zube/vscode-distro/out/bootstrap-node.js:83:38)
	at Module._resolveLookupPaths (/Users/zube/vscode-distro/out/bootstrap.js:84:18)
	at node_module._resolveLookupPaths (/Users/zube/vscode-distro/out/vs/workbench/api/node/extHostExtensionService.js:23:39)
	at Module._resolveFilename (node:internal/modules/cjs/loader:941:20)
	at o._resolveFilename (node:electron/js2c/utility_process_init:17:848)
	at Module._load (node:internal/modules/cjs/loader:832:27)

It appears that bootstrap.js makes this check on line 85 and when making this change in our fork this fixes bootstrap-node.js from exhibiting this issue as well.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions