Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: fresh installation does not work, multiple modules missing #5992

Closed
CaledoniaProject opened this issue Jan 29, 2023 · 2 comments
Closed

Comments

@CaledoniaProject
Copy link

CaledoniaProject commented Jan 29, 2023

OS/Web Information

Web Browser: Chrome
Local OS: Windows Server 2016
Remote OS: Windows Server 2016
Remote Architecture: amd64

$ code-server --version
4.9.1 f7989a4dfcf21085e52157a01924d79d708bcc05 with Code 1.73.1

Steps to Reproduce

  1. Install node16 LTS https://nodejs.org/dist/v16.16.0/node-v16.16.0-x64.msi
  2. Install cygwin, select curl
  3. In cygwin install code-server with npm install --global code-server --unsafe-perm

Expected

code-server to work

Actual

The installer does not report any errors:

$ npm install --global code-server --unsafe-perm
npm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.
npm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.

changed 206 packages, and audited 207 packages in 39s

12 packages are looking for funding
  run `npm fund` for details

1 high severity vulnerability

To address all issues, run:
  npm audit fix

Run `npm audit` for details.

code-server could start but when I connect it via a browser it prints lots of error:

$ code-server
[2023-01-29T03:29:13.904Z] info  code-server 4.9.1 f7989a4dfcf21085e52157a01924d79d708bcc05
[2023-01-29T03:29:13.906Z] info  Using user-data-dir ~\AppData\Local\code-server\Data
[2023-01-29T03:29:13.924Z] info  Using config file ~\AppData\Roaming\code-server\Config\config.yaml
[2023-01-29T03:29:13.924Z] info  HTTP server listening on http://127.0.0.1:8080/
[2023-01-29T03:29:13.924Z] info    - Authentication is enabled
[2023-01-29T03:29:13.925Z] info      - Using password from ~\AppData\Roaming\code-server\Config\config.yaml
[2023-01-29T03:29:13.925Z] info    - Not serving HTTPS
Loading "minimist" failed
Error: Cannot find module 'minimist'
Require stack:
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\bootstrap-amd.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\util.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\cli.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\entry.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
    at Function.Module._load (node:internal/modules/cjs/loader:778:27)
    at Function.require._load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\plugin.js:54:74)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at r (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:101)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:1720)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10382)
    at a (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10224)
    at Object.errorback (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10345)
    at e.triggerErrorback (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10746)
    at C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10452
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:1737)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10382)
    at a (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10224)
    at s._loadModule (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10354)
    at s._resolve (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:6:452)
    at s.defineModule (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:6066)
    at y (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:6:1825)
    at h (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2554)
    at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\server\node\server.main.js:76:14732)
    at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\server\node\server.main.js:185:2106)
    at e._createAndEvalScript (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2598)
    at C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2237
    at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read_file_context:68:3) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\lib\\vscode\\out\\bootstrap-amd.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\util.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\cli.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\entry.js'
  ],
  phase: 'loading',
  moduleId: 'minimist',
  neededBy: [ 'vs/platform/environment/node/argv' ]
}
Here are the modules that depend on it:
[ 'vs/platform/environment/node/argv' ]
Loading "@microsoft/1ds-core-js" failed
Error: Cannot find module '@microsoft/1ds-core-js'
Require stack:
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\bootstrap-amd.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\util.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\cli.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\entry.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
    at Function.Module._load (node:internal/modules/cjs/loader:778:27)
    at Function.require._load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\plugin.js:54:74)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at r (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:101)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:1720)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10382)
    at a (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10224)
    at Object.errorback (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10345)
    at e.triggerErrorback (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10746)
    at C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10452
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:1737)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10382)
    at a (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10224)
    at s._loadModule (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10354)
    at s._resolve (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:6:452)
    at s.defineModule (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:6066)
    at y (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:6:1825)
    at h (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2554)
    at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\server\node\server.main.js:141:9340)
    at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\server\node\server.main.js:185:2106)
    at e._createAndEvalScript (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2598)
    at C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2237
    at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read_file_context:68:3) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\lib\\vscode\\out\\bootstrap-amd.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\util.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\cli.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\entry.js'
  ],
  phase: 'loading',
  moduleId: '@microsoft/1ds-core-js',
  neededBy: [ 'vs/server/node/telemetryClient' ]
}
Here are the modules that depend on it:
[ 'vs/server/node/telemetryClient' ]
Loading "yauzl" failed
Error: Cannot find module 'yauzl'
Require stack:
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\bootstrap-amd.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\util.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\cli.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\entry.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
    at Function.Module._load (node:internal/modules/cjs/loader:778:27)
    at Function.require._load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\plugin.js:54:74)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at r (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:101)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:1720)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10382)
    at a (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10224)
    at Object.errorback (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10345)
    at e.triggerErrorback (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10746)
    at C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10452
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:1737)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10382)
    at a (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10224)
    at s._loadModule (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10354)
    at s._resolve (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:6:452)
    at s.defineModule (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:6066)
    at y (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:6:1825)
    at h (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2554)
    at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\server\node\server.main.js:149:73445)
    at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\server\node\server.main.js:185:2106)
    at e._createAndEvalScript (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2598)
    at C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2237
    at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read_file_context:68:3) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\lib\\vscode\\out\\bootstrap-amd.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\util.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\cli.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\entry.js'
  ],
  phase: 'loading',
  moduleId: 'yauzl',
  neededBy: [ 'vs/base/node/zip' ]
}
Here are the modules that depend on it:
[ 'vs/base/node/zip' ]
Loading "yazl" failed
Error: Cannot find module 'yazl'
Require stack:
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\bootstrap-amd.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\util.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\cli.js
- C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\entry.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
    at Function.Module._load  (node:internal/modules/cjs/loader:778:27)
    at Function.require._load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\out\node\plugin.js:54:74)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at r (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:101)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:1720)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10382)
    at a (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10224)
    at Object.errorback (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10345)
    at e.triggerErrorback (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10746)
    at C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10452
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:1737)
    at e.load (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:3:10382)
    at a (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10224)
    at s._loadModule (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:10354)
    at s._resolve (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:6:452)
    at s.defineModule (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:5:6066)
    at y (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:6:1825)
    at h (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2554)
    at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\server\node\server.main.js:149:73445)
    at Object.<anonymous> (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\server\node\server.main.js:185:2106)
    at e._createAndEvalScript (C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2598)
    at C:\Users\Administrator\AppData\Roaming\npm\node_modules\code-server\lib\vscode\out\vs\loader.js:4:2237
    at FSReqCallback.readFileAfterClose [as oncomplete] (node:internal/fs/read_file_context:68:3) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\lib\\vscode\\out\\bootstrap-amd.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\util.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\cli.js',
    'C:\\Users\\Administrator\\AppData\\Roaming\\npm\\node_modules\\code-server\\out\\node\\entry.js'
  ],
  phase: 'loading',
  moduleId: 'yazl',
  neededBy: [ 'vs/base/node/zip' ]
}
Here are the modules that depend on it:
[ 'vs/base/node/zip' ]

Notes

I tried to install the missing modules with npm manually, but then lots more error occurs when I logged in. And I don't think I should be installing these missing modules manually. The installer must be broken somehow.

@CaledoniaProject CaledoniaProject added bug Something isn't working triage This issue needs to be triaged by a maintainer labels Jan 29, 2023
@code-asher
Copy link
Member

Interesting, looks somewhat similar to #5966

Maybe an npm bug?

@U5B
Copy link

U5B commented Feb 10, 2023

Same issue as this one: #5530
Seems like Raspberry PIs have an issue.

@code-asher code-asher closed this as not planned Won't fix, can't repro, duplicate, stale Feb 13, 2023
@code-asher code-asher added duplicate and removed bug Something isn't working triage This issue needs to be triaged by a maintainer labels Feb 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants