Closed theguy147 closed 5 years ago
Hi @yakamoz147, thank you for the comment. The Electron in your computer seems to be having a problem. Try this:
/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5
npm uninstall -g electron
npm uninstall -g electron-prebuilt
npm cache clean
npm cache ls
~/.electron
.node -e "console.log(require('electron-prebuilt'))"
Error: Cannot find module 'electron-prebuilt'
should occur (this is correct result).Thank you but unfortunately after performing all of the steps you mentioned the same error still persists...
EDIT:
Here are the new Logs:
extensionHost.ts:293 [Extension Host] debugger listening on port 15813
TMScopeRegistry.ts:45 Overwriting grammar scope name to file mapping for scope source.ruby.
Old grammar file: file:///usr/lib/code/extensions/ruby/syntaxes/ruby.tmLanguage.json.
New grammar file: file:///home/anonymized_user/.vscode-oss/extensions/rebornix.ruby-0.25.3/syntaxes/ruby.cson.json
register @ TMScopeRegistry.ts:45
TMScopeRegistry.ts:45 Overwriting grammar scope name to file mapping for scope source.yaml.
Old grammar file: file:///usr/lib/code/extensions/yaml/syntaxes/yaml.tmLanguage.json.
New grammar file: file:///home/anonymized_user/.vscode-oss/extensions/redhat.vscode-yaml-0.5.3/syntaxes/yaml.tmLanguage.json
register @ TMScopeRegistry.ts:45
console.ts:137 [Extension Host] Starting express server on port: 46219
webviewElement.ts:342 [Embedded Page] %cElectron Security Warning (Insecure Content-Security-Policy)
console.ts:137 [Extension Host] Start child process...
console.ts:137 [Extension Host] Start initializing module...
t.log @ console.ts:137
console.ts:137 [Extension Host] Node.js@10.11.0
console.ts:137 [Extension Host] Error: Cannot find module 'npm' at Function.Module._resolveFilename (internal/modules/cjs/loader.js:584:15) at Function.Module._load (internal/modules/cjs/loader.js:510:25) at Function.define._installInterceptor.i._load (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:508:859) at Function.t._load (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:777:268) at Function.t.getExtensionPathIndex.then.i._load (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:700:176) at Module.require (internal/modules/cjs/loader.js:640:17) at Module.patchedRequire [as require] (/home/anonymized_user/.vscode-oss/extensions/vsciot-vscode.vscode-arduino-0.2.27/node_modules/diagnostic-channel/dist/src/patchRequire.js:14:46) at require (internal/modules/cjs/helpers.js:20:18) at getNpm (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:139:15) at initModule (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:220:10) at getHostCmd (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:331:9) at /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:394:19 at Object.exports.sendRequest (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:468:34) at pickConvert (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/lib/color-helper.js:187:15) at exports.pick (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/lib/color-helper.js:229:24) at p._executeContributedCommand (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:522:163) at p.$executeContributedCommand (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:522:538) at d._doInvokeHandler (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:668:1006) at d._invokeHandler (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:668:698) at d._receiveRequest (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:667:346) at d._receiveOneMessage (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:666:141) at define.constructor._protocol.onMessage.e (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:664:400) at u.fire (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:50:207) at a (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:179:815) at e (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:179:861) at u.fire (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:50:207) at n.constructor.e.onMessage.e (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:775:104) at u.fire (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:50:207) at a (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:179:815) at e (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:179:861) at u.fire (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:50:207) at y._receiveMessage (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:188:834) at define.constructor._socketDisposables.push._socketReader.onMessage.e (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:186:116) at u.fire (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:50:207) at f.acceptChunk (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:182:588) at define.constructor._register._socket.onData.e (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:181:919) at Socket.t (/usr/lib/code/out/vs/workbench/services/extensions/node/extensionHostProcess.js:190:329) at Socket.emit (events.js:182:13) at addChunk (_stream_readable.js:283:12) at readableAddChunk (_stream_readable.js:264:11) at Socket.Readable.push (_stream_readable.js:219:10) at Pipe.onStreamRead [as onread] (internal/stream_base_commons.js:94:17)
console.ts:137 [Extension Host] Continue trying to get NPM...
t.log @ console.ts:137
console.ts:137 [Extension Host] Try to get NPM via usage info.
t.log @ console.ts:137
console.ts:137 [Extension Host] NPM@6.11.3
console.ts:137 [Extension Host] NPM directory path: /usr/lib/node_modules/npm
console.ts:137 [Extension Host] NPM resolved path: /usr/lib/node_modules/npm/lib/npm.js
console.ts:137 [Extension Host] Base directory path: /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5
console.ts:137 [Extension Host] Retry (Error: Cannot find module 'electron-prebuilt')
t.log @ console.ts:137
console.ts:137 [Extension Host] Try to load: /usr/lib/node_modules/npm/lib/utils/spawn.js
t.log @ console.ts:137
extensionHost.ts:201 Extension Host
extensionHost.ts:202 Downloading electron-v0.37.3-linux-x64.zip[> Downloading electron-v0.37.3-linux-x64.zip[> ] 0.0%Downloading electron-v0.37.3-linux-x64.zip[> ] 0.3%Downloading electron-v0.37.3-linux-x64.zip[> ] 1.8%Downloading electron-v0.37.3-linux-x64.zip[=> ] 5.2%Downloading electron-v0.37.3-linux-x64.zip[==> ] 7.7%Downloading electron-v0.37.3-linux-x64.zip[=====> ] 15.0Downloading electron-v0.37.3-linux-x64.zip[=======> ] 19.1Downloading electron-v0.37.3-linux-x64.zip[=========> ] 22.9Downloading electron-v0.37.3-linux-x64.zip[==========> ] 26.6Downloading electron-v0.37.3-linux-x64.zip[============> ] 30.4Downloading electron-v0.37.3-linux-x64.zip[==============> ] 34.1Downloading electron-v0.37.3-linux-x64.zip[================> ] 37.9Downloading electron-v0.37.3-linux-x64.zip[=================> ] 40.8Downloading electron-v0.37.3-linux-x64.zip[==================> ] 44.2Downloading electron-v0.37.3-linux-x64.zip[=====================> ] 50.6Downloading electron-v0.37.3-linux-x64.zip[=======================> ] 54.4Downloading electron-v0.37.3-linux-x64.zip[=========================> ] 58.1Downloading electron-v0.37.3-linux-x64.zip[==========================> ] 61.9Downloading electron-v0.37.3-linux-x64.zip[============================> ] 65.6Downloading electron-v0.37.3-linux-x64.zip[==============================> ] 69.4Downloading electron-v0.37.3-linux-x64.zip[===============================> ] 73.1Downloading electron-v0.37.3-linux-x64.zip[=================================> ] 76.8Downloading electron-v0.37.3-linux-x64.zip[===================================> ] 80.6Downloading electron-v0.37.3-linux-x64.zip[====================================> ] 84.3Downloading electron-v0.37.3-linux-x64.zip[============================================>] 100.0% of 39.86 MB (4.98 MB/s)
console.ts:137 [Extension Host] added 147 packages from 115 contributors and audited 1039 packages in 22.348s
console.ts:137 [Extension Host] found 32 vulnerabilities (8 low, 7 moderate, 16 high, 1 critical) run `npm audit fix` to fix them, or `npm audit` for details
console.ts:137 [Extension Host] Check version of: electron-prebuilt
console.ts:137 [Extension Host] Check version of: comma-separated-values
console.ts:137 [Extension Host] Check version of: js-yaml
console.ts:137 [Extension Host] Check version of: process-bridge
console.ts:137 [Extension Host] Try to send IPC message: 1
console.ts:137 [Extension Host] Child process disconnected
console.ts:137 [Extension Host] Child process exited with code: null
console.ts:137 [Extension Host] Error: Child process exited with code: null at /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:478:19 at ChildProcess.<anonymous> (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:394:19) at ChildProcess.emit (events.js:182:13) at Process.ChildProcess._handle.onexit (internal/child_process.js:240:12)
t.log @ console.ts:137
notificationsAlerts.ts:40 [processBridge]: Error: Child process exited with code: null
onDidNotificationChange @ notificationsAlerts.ts:40
console.ts:137 [Extension Host] Error: Child process already exited. at sendIpc (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:415:31) at Timeout.<anonymous> (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:394:19) at ontimeout (timers.js:425:11) at tryOnTimeout (timers.js:289:5) at listOnTimeout (timers.js:252:5) at Timer.processTimers (timers.js:212:10)
t.log @ console.ts:137
notificationsAlerts.ts:40 [processBridge]: Error: Child process already exited.
onDidNotificationChange @ notificationsAlerts.ts:40
Try this in terminal app (not "TERMINAL" panel in VS Code):
cd /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5
npm uninstall electron-prebuilt
npm i electron-prebuilt@0.37.3 --no-audit
I'm still having the same issue... no changes
Could you show me the result of the commands above?
Also, show me each result of these:
node -e "console.log(require('electron-prebuilt'))"
cd /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5
node -e "console.log(require('electron-prebuilt'))"
That's the command and their outputs from above:
$ pwd
/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5
$ npm uninstall electron-prebuilt
removed 69 packages and audited 834 packages in 2.258s
found 32 vulnerabilities (8 low, 7 moderate, 16 high, 1 critical)
run `npm audit fix` to fix them, or `npm audit` for details
$ npm i electron-prebuilt@0.37.3 --no-audit
> electron-prebuilt@0.37.3 postinstall /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/electron-prebuilt
> node install.js
+ electron-prebuilt@0.37.3
added 69 packages from 47 contributors in 8.449s
That's the new commands output after executing the above and without reinstalling the extension within vscode:
From VSCode: (while not in ~/.vscode-oss/extensions/anseki.vscode-color-0.4.5/
dir)
internal/modules/cjs/loader.js:775
throw err;
^
Error: Cannot find module 'electron-prebuilt'
Require stack:
- /home/anonymized_user/Desktop/some_folder/[eval]
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:772:15)
at Function.Module._load (internal/modules/cjs/loader.js:677:27)
at Module.require (internal/modules/cjs/loader.js:830:19)
at require (internal/modules/cjs/helpers.js:68:18)
at [eval]:1:13
at Script.runInThisContext (vm.js:126:20)
at Object.runInThisContext (vm.js:316:38)
at Object.<anonymous> ([eval]-wrapper:9:26)
at Module._compile (internal/modules/cjs/loader.js:936:30)
at evalScript (internal/process/execution.js:80:25) {
code: 'MODULE_NOT_FOUND',
requireStack: [ '/home/anonymized_user/Desktop/some_folder/[eval]' ]
}
From VSCode: (now in ~/.vscode-oss/extensions/anseki.vscode-color-0.4.5/
dir)
/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/electron-prebuilt/dist/electronv
From terminal:
/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/electron-prebuilt/dist/electron
Save this test script to /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/test.js
file.
process.stdin.on('error', error => { throw error; });
process.stdin.on('close', () => { process.exit(); });
require('process-bridge').sendRequest({command: 'pick'},
[require('path').join(__dirname, 'lib/app.asar')], error => {
if (error) {
if (error.isRetried) { return; }
throw error;
}
process.exit();
});
And, execute these in terminal app:
cd /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5
node test
This is the output of that script:
Start child process...
Check version of: electron-prebuilt
Check version of: comma-separated-values
Check version of: js-yaml
Check version of: process-bridge
Try to send IPC message: 1
Child process disconnected
Child process exited with code: null
/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/test.js:7
throw error;
^
Error: Child process exited with code: null
at /home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:478:19
at ChildProcess.<anonymous> (/home/anonymized_user/.vscode-oss/extensions/anseki.vscode-color-0.4.5/node_modules/process-bridge/process-bridge.js:394:19)
at ChildProcess.emit (events.js:209:13)
at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12) {
code: null,
signal: 'SIGSEGV'
}
Ah... I see.
It is SIGSEGV
...
The Arch (Manjaro) Linux seems to be having a problem about the Electron and "glibc". https://github.com/electron/electron/issues/13972 The problem might be solved by downgrading the glibc, but I don't know whether this is best solution or not.
Sorry, I can't help you about this... If you report about the downgrading the glibc, that should help other users. Or, you can close this issue and choose another extension.
Hmm, ok, very strange. All other electron apps I have installed work without a problem and don't cause a segmentation fault. I will look into this issue some more and report if I find a solution.
I close this issue.
Hmm, ok, very strange. All other electron apps I have installed work without a problem and don't cause a segmentation fault.
Nothing strange here really. This otherwise nice and useful vscode extension I used to use daily unfortunately relies on 4 years old prebuilt version of Electron.
This isn't Arch Linux problem. Eventually all Linux distribution will not be able to run old binary.
Telling people to try downgrade their system's glibc
and apologizing that you can't do nothing about this is ridiculous.
Hi @AloisJanicek, thank you for the information. :smile:
Hello,
as asked by you in issue #89 I opened a new issue for this.
I am not able to use the vscode extension and I am getting the following Error messages:
Error: Child process exited with code: null Error: Child process already exited.
Steps to Reproduce:
System Details:
Here are the Logs: