Skip to content

Process exits on VS Code download failure, subverting retry logic #200

@minestarks

Description

@minestarks

Backgroud: #175, #175 (comment) , and #176

@aeschli I'm not sure this bug was entirely fixed, since we started hitting download issues again. I think the retry logic is not kicking in because the process itself crashes due to an uncaught error.

I suspect the same issue was already fixed in vscode-test by @connor4312 : microsoft/vscode-test#152 . I'm hoping it's just a matter of applying the same fix here

Logs from an example failure in our build (source here):

    at process.processTimers (node:internal/timers:523:7)
Emitted 'error' event on ClientRequest instance at:
    at emitErrorEvent (node:_http_client:107:11)
    at TLSSocket.socketErrorListener (node:_http_client:574:5)
    at TLSSocket.emit (node:events:519:28)
    at emitErrorNT (node:internal/streams/destroy:170:8)
    at emitErrorCloseNT (node:internal/streams/destroy:129:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:90:21) {
  code: 'ETIMEDOUT',
  [errors]: [
    Error: connect ETIMEDOUT 150.171.109.149:443
        at createConnectionError (node:net:1678:14)
        at Timeout.internalConnectMultipleTimeout (node:net:1737:38)
        at listOnTimeout (node:internal/timers:590:11)
        at process.processTimers (node:internal/timers:523:7) {
      errno: -110,
      code: 'ETIMEDOUT',
      syscall: 'connect',
      address: '150.171.109.149',
      port: 443
    },
    Error: connect ENETUNREACH 2603:1061:14:94::1:443 - Local (:::0)
        at internalConnectMultiple (node:net:1206:16)
        at Timeout.internalConnectMultipleTimeout (node:net:1742:5)
        at listOnTimeout (node:internal/timers:590:11)
        at process.processTimers (node:internal/timers:523:7) {
      errno: -101,
      code: 'ENETUNREACH',
      syscall: 'connect',
      address: '2603:1061:14:94::1',
      port: 443
    }
  ]
}

Node.js v22.21.1
npm error Lifecycle script `test` failed with error:
npm error code 1
npm error path /mnt/vss/_work/1/s/source/vscode
npm error workspace qsharp-lang-vscode-dev@1.26.42
npm error location /mnt/vss/_work/1/s/source/vscode
npm error command failed
npm error command sh -c node ./test/runTests.mjs -- 
Traceback (most recent call last):
  File "/mnt/vss/_work/1/s/build.py", line 668, in <module>
    subprocess.run(vscode_args, check=True, text=True, cwd=vscode_src)
  File "/opt/hostedtoolcache/Python/3.11.14/x64/lib/python3.11/subprocess.py", line 571, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['npm', 'test']' returned non-zero exit status 1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions