Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
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
undicias 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.OptionsHTTP/2 is now enabled by default (
allowH2default changedfalse→true).If your code assumed HTTP/1.1 behavior unless you opted in, you now need to explicitly set
allowH2: falseinClient/dispatcher options to force HTTP/1.1. [2]Node.js 20 support was dropped (minimum Node is now 22).
Not a
Client.Optionsshape change, but it’s a breaking runtime constraint that can affect any code constructingnew Client(...)if you’re still on Node 20. [3]No other
v8.0.0items in the published release notes indicate a direct breaking change to theClientconstructor signature or a rename/removal ofClient.Optionsfields beyond theallowH2default 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.0declaresundici@>=7.0.0as a peer dependency, so it works with v8. TheClientconstructor signature andClient.OptionsAPI 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: falseto client options, or verify that the HTTP/2 upgrade doesn't break service interactions.🤖 Prompt for AI Agents