Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/app/backend-http-client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"postversion": "biome check --write package.json"
},
"dependencies": {
"undici": "^7.20.0",
"undici": "^8.0.2",
"undici-retry": "^7.0.0"
Comment on lines +41 to 42
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify undici-retry v7.0.0 compatibility with undici v8.x

echo "=== Checking undici-retry package metadata ==="
curl -s https://registry.npmjs.org/undici-retry | jq -r '.versions["7.0.0"] | {
  peerDependencies,
  dependencies,
  description
}'

echo -e "\n=== Checking for undici v8 compatibility mentions in undici-retry ==="
gh api repos/kibertoad/undici-retry/issues --jq '.[] | select(.title | test("undici.*8|v8"; "i")) | {number, title, state, created_at}'

echo -e "\n=== Checking undici-retry latest version ==="
curl -s https://registry.npmjs.org/undici-retry/latest | jq -r '{version, peerDependencies, dependencies}'

Repository: lokalise/shared-ts-libs

Length of output: 645


🌐 Web query:

Does undici-retry v7.0.0 support undici v8? What are the breaking changes in undici v8.0.0 that might affect Client.Options or Client constructor?

💡 Result:

Yes. undici-retry v7.0.0 declares undici as a peer dependency >=7.0.0, so it will accept/install alongside undici v8 as well. [1]

undici v8.0.0 breaking changes that could affect Client / Client.Options

  1. HTTP/2 is now enabled by default (allowH2 default changed falsetrue).
    If your code assumed HTTP/1.1 behavior unless you opted in, you now need to explicitly set allowH2: false in Client/dispatcher options to force HTTP/1.1. [2]

  2. Node.js 20 support was dropped (minimum Node is now 22).
    Not a Client.Options shape change, but it’s a breaking runtime constraint that can affect any code constructing new Client(...) if you’re still on Node 20. [3]

No other v8.0.0 items in the published release notes indicate a direct breaking change to the Client constructor signature or a rename/removal of Client.Options fields beyond the allowH2 default flip. [4]

Sources:
[1] https://cdn.jsdelivr.net/npm/undici-retry@7.0.0/package.json
[2] nodejs/undici#4828
[3] nodejs/undici#4786
[4] https://github.com/nodejs/undici/releases/tag/v8.0.0


Test HTTP/2 default behavior change in undici v8.

The upgrade is compatible: undici-retry@^7.0.0 declares undici@>=7.0.0 as a peer dependency, so it works with v8. The Client constructor signature and Client.Options API are stable.

However, undici v8 enables HTTP/2 by default (previously disabled). If your target servers or proxies don't support HTTP/2, add allowH2: false to client options, or verify that the HTTP/2 upgrade doesn't break service interactions.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@packages/app/backend-http-client/package.json` around lines 41 - 42, Undici
v8 enables HTTP/2 by default which may break servers/proxies; find where the
undici Client is constructed in this package (look for new Client(...) or any
createClient/initializeHttpClient function in packages/app/backend-http-client)
and add allowH2: false to the Client options object passed to undici.Client (or
set allowH2: false in the options returned by the init/configure method) so
HTTP/2 is disabled by default; also run/update any integration tests that
exercise HTTP calls to verify behavior remains correct.

},
"peerDependencies": {
Expand Down
Loading