Skip to content

deps: update undici to 7.21.0#61683

Open
nodejs-github-bot wants to merge 1 commit intomainfrom
actions/tools-update-undici
Open

deps: update undici to 7.21.0#61683
nodejs-github-bot wants to merge 1 commit intomainfrom
actions/tools-update-undici

Conversation

@nodejs-github-bot
Copy link
Collaborator

@nodejs-github-bot nodejs-github-bot commented Feb 4, 2026

This is an automated update of undici to 7.21.0.

@nodejs-github-bot nodejs-github-bot added the dependencies Pull requests that update a dependency file. label Feb 4, 2026
@nodejs-github-bot
Copy link
Collaborator Author

Review requested:

  • @nodejs/security-wg

@nodejs-github-bot nodejs-github-bot added lib / src Issues and PRs related to general changes in the lib or src directory. needs-ci PRs that need a full CI run. labels Feb 4, 2026
@codecov
Copy link

codecov bot commented Feb 4, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.76%. Comparing base (ae2ffce) to head (e7bce4b).
⚠️ Report is 4 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #61683      +/-   ##
==========================================
+ Coverage   89.75%   89.76%   +0.01%     
==========================================
  Files         674      674              
  Lines      204416   204416              
  Branches    39285    39282       -3     
==========================================
+ Hits       183472   183493      +21     
+ Misses      13227    13221       -6     
+ Partials     7717     7702      -15     

see 30 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@richardlau
Copy link
Member

@nodejs/undici

Test failures, e.g. https://github.com/nodejs/node/actions/runs/21682250788/job/62519692852?pr=61683#step:9:6017

=== release test-permission-net-fetch ===
Path: parallel/test-permission-net-fetch
Error: --- stderr ---
node:internal/assert/utils:146
  throw error;
  ^

AssertionError [ERR_ASSERTION]: /home/runner/work/node/node/node/test/fixtures/permission/net-fetch.js:8
  assert.strictEqual(err.cause.code, 'ERR_ACCESS_DENIED');
                               ^

TypeError: Cannot read properties of undefined (reading 'code')
    at /home/runner/work/node/node/node/test/fixtures/permission/net-fetch.js:8:32
    at /home/runner/work/node/node/node/test/common/index.js:507:15
    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)

Node.js v26.0.0-pre


1 !== 0

    at Server.<anonymous> (/home/runner/work/node/node/node/test/parallel/test-permission-net-fetch.js:41:10)
    at Server.<anonymous> (/home/runner/work/node/node/node/test/common/index.js:507:15)
    at Object.onceWrapper (node:events:622:28)
    at Server.emit (node:events:520:22)
    at emitListeningNT (node:net:2051:10)
    at process.processTicksAndRejections (node:internal/process/task_queues:89:21) {
  generatedMessage: false,
  code: 'ERR_ASSERTION',
  actual: 1,
  expected: 0,
  operator: 'strictEqual',
  diff: 'simple'
}

Node.js v26.0.0-pre
Command: out/Release/node /home/runner/work/node/node/node/test/parallel/test-permission-net-fetch.js
=== release test-tls-set-default-ca-certificates-append-fetch ===
Path: parallel/test-tls-set-default-ca-certificates-append-fetch
Error: --- stderr ---
file:///home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-append-fetch.mjs:40
    assert.strictEqual(err.cause.code, 'UNABLE_TO_VERIFY_LEAF_SIGNATURE');
                                 ^

TypeError: Cannot read properties of undefined (reading 'code')
    at Object.<anonymous> (file:///home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-append-fetch.mjs:40:34)
    at expectedException (node:assert:547:17)
    at expectsError (node:assert:672:21)
    at assert.rejects (node:assert:738:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
    at async file:///home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-append-fetch.mjs:37:1

Node.js v26.0.0-pre
Command: out/Release/node --no-use-system-ca /home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-append-fetch.mjs
=== release test-tls-set-default-ca-certificates-reset-fetch ===
Path: parallel/test-tls-set-default-ca-certificates-reset-fetch
Error: --- stderr ---
file:///home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-reset-fetch.mjs:42
    assert.strictEqual(err.cause.code, 'UNABLE_TO_VERIFY_LEAF_SIGNATURE');
                                 ^

TypeError: Cannot read properties of undefined (reading 'code')
    at Object.<anonymous> (file:///home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-reset-fetch.mjs:42:34)
    at expectedException (node:assert:547:17)
    at expectsError (node:assert:672:21)
    at assert.rejects (node:assert:738:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
    at async file:///home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-reset-fetch.mjs:39:1

Node.js v26.0.0-pre
Command: out/Release/node --no-use-system-ca /home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-reset-fetch.mjs

===
=== 3 tests failed
===

Failed tests:
out/Release/node /home/runner/work/node/node/node/test/parallel/test-permission-net-fetch.js
out/Release/node --no-use-system-ca /home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-append-fetch.mjs
out/Release/node --no-use-system-ca /home/runner/work/node/node/node/test/parallel/test-tls-set-default-ca-certificates-reset-fetch.mjs
make: *** [Makefile:612: test-ci] Error 1
make: Leaving directory '/home/runner/work/node/node/node'

@nodejs-github-bot nodejs-github-bot force-pushed the actions/tools-update-undici branch from e5e1cf5 to e7bce4b Compare February 6, 2026 12:38
@nodejs-github-bot nodejs-github-bot changed the title deps: update undici to 7.20.0 deps: update undici to 7.21.0 Feb 6, 2026
@mcollina
Copy link
Member

mcollina commented Feb 6, 2026

The CI failures are caused by a bug in undici 7.20.0 where __filename is not defined when undici is bundled inside Node.js as an internal module.

When fetch() fails, the code in index-fetch.js tries to access __filename to augment the stack trace, but this throws a ReferenceError that swallows the original error, making err.cause undefined.

Fix PR: nodejs/undici#4812

@mcollina
Copy link
Member

mcollina commented Feb 6, 2026

This is fixed in undici v7.21.0

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@mcollina mcollina added the request-ci Add this label to start a Jenkins CI on a PR. label Feb 6, 2026
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Feb 6, 2026
@nodejs-github-bot
Copy link
Collaborator Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file. lib / src Issues and PRs related to general changes in the lib or src directory. needs-ci PRs that need a full CI run.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants