Bump Refit and Refit.HttpClientFactory#32
Conversation
Bumps Refit from 10.1.6 to 11.0.0 Bumps Refit.HttpClientFactory from 10.1.6 to 11.0.0 --- updated-dependencies: - dependency-name: Refit dependency-version: 11.0.0 dependency-type: direct:production update-type: version-update:semver-major - dependency-name: Refit.HttpClientFactory dependency-version: 11.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Complexity | 0 |
| Duplication | 0 |
AI Reviewer: first review requested successfully. AI can make mistakes. Always validate suggestions.
TIP This summary will be updated as you push new changes.
There was a problem hiding this comment.
Pull Request Overview
This PR updates Refit and its associated factory to version 11.0.0. While the automated quality analysis reports the changes as being up to standards, this is a major breaking release that requires significant manual intervention in the consuming code.
The current implementation only updates the dependency versions in the central package management file but does not include the necessary updates for response status code nullability or the redesigned exception hierarchy. These omissions are expected to cause compilation failures and runtime regressions in any code interacting with Refit clients.
About this PR
- This upgrade to Refit 11.0.0 is a breaking change. The PR currently only updates 'Directory.Packages.props'. Consuming code must also be updated to handle nullable HttpStatusCode in ApiResponse and the new ApiExceptionBase/ApiRequestException types to avoid compilation and runtime errors.
Test suggestions
- Verify application compilation against nullable ApiResponse.StatusCode
- Verify error handling logic correctly processes the new ApiExceptionBase and ApiRequestException types
- Ensure generated Refit clients still initialize correctly with the stricter interface validation
Prompt proposal for missing tests
Consider implementing these tests if applicable:
1. Verify application compilation against nullable ApiResponse.StatusCode
2. Verify error handling logic correctly processes the new ApiExceptionBase and ApiRequestException types
3. Ensure generated Refit clients still initialize correctly with the stricter interface validation
TIP Improve review quality by adding custom instructions
TIP How was this review? Give us feedback
| <PackageVersion Include="Refit" Version="11.0.0" /> | ||
| <PackageVersion Include="Refit.HttpClientFactory" Version="11.0.0" /> |
There was a problem hiding this comment.
🔴 HIGH RISK
This is a breaking major version release. The release notes indicate that code inspecting ApiResponse.Error, reading StatusCode, or catching transport exceptions will need changes. Please ensure these migrations are performed across the codebase as part of this upgrade.
|
Looks like these dependencies are no longer updatable, so this is no longer needed. |
Updated Refit from 10.1.6 to 11.0.0.
Release notes
Sourced from Refit's releases.
11.0.0
11.0.0 reworks Refit's error/exception model and tightens interface validation. Most apps will compile, but code that inspects
ApiResponse.Error, readsStatusCode, or catches transport exceptions around Refit calls will need changes. These are the same breaking changes that briefly shipped in the now‑delisted10.1.7and were reported by the community in #2114.💥 What changed & how to migrate
1.
ApiResponse<T>.Erroris nowApiExceptionBase?(wasApiException?) (#2052)A new abstract base
ApiExceptionBasenow sits under bothApiExceptionand the newApiRequestException.ApiExceptionBasedoes not exposeContent/HasContent— those still live onApiException.2. New
ApiRequestExceptionwraps transport/connection failures (#2052)Exceptions thrown by
HttpClient.SendAsyncbefore a response arrives —HttpRequestException(DNS/host unreachable),TaskCanceledException(timeouts), etc. — are now wrapped inApiRequestException : ApiExceptionBase, carrying the full request context. ForApiResponse<T>return types these are now surfaced via.Errorinstead of only being thrown, so you no longer need a separatetry/catchandIsSuccessfulcheck.3.
ApiResponse<T>.StatusCodeis now nullable (HttpStatusCode?) (#2052)When the request never reached the server there is no status code. Code that assumed a non‑null value must handle
null:4. Stricter interface validation + enum name handling (#2068)
Synchronous return types are now only permitted for generated/non‑public interface members (
RestMethodInfoenforces the rule), and the System.Text.Json enum converter now maps serialized names both ways (includingJsonStringEnumMemberNameon .NET 9+). Interfaces that previously relied on unsupported sync members may now fail generation.🗞️ What's Changed
✨ Features & Enhancements
ApiRequestExceptionfor wrappingSendAsyncexceptions (new error model) by @PressXtoChris in #2052AddRefitClientoverloads and tests by @ChrisPulman in #2084... (truncated)
10.2.0
NOTE
This is a re-release of v10.1.6 which had a certificate revoked.
🗞️ What's Changed
🐛 Fixes
🧹 General Changes
📦 Dependencies
📌 Other
🔗 Full Changelog: reactiveui/refit@10.0.1...10.1.6
🙌 Contributions
💖 Thanks to all the contributors: @ChrisPulman
🤖 Automated services that contributed: @renovate[bot]
Commits viewable in compare view.
Updated Refit.HttpClientFactory from 10.1.6 to 11.0.0.
Release notes
Sourced from Refit.HttpClientFactory's releases.
11.0.0
11.0.0 reworks Refit's error/exception model and tightens interface validation. Most apps will compile, but code that inspects
ApiResponse.Error, readsStatusCode, or catches transport exceptions around Refit calls will need changes. These are the same breaking changes that briefly shipped in the now‑delisted10.1.7and were reported by the community in #2114.💥 What changed & how to migrate
1.
ApiResponse<T>.Erroris nowApiExceptionBase?(wasApiException?) (#2052)A new abstract base
ApiExceptionBasenow sits under bothApiExceptionand the newApiRequestException.ApiExceptionBasedoes not exposeContent/HasContent— those still live onApiException.2. New
ApiRequestExceptionwraps transport/connection failures (#2052)Exceptions thrown by
HttpClient.SendAsyncbefore a response arrives —HttpRequestException(DNS/host unreachable),TaskCanceledException(timeouts), etc. — are now wrapped inApiRequestException : ApiExceptionBase, carrying the full request context. ForApiResponse<T>return types these are now surfaced via.Errorinstead of only being thrown, so you no longer need a separatetry/catchandIsSuccessfulcheck.3.
ApiResponse<T>.StatusCodeis now nullable (HttpStatusCode?) (#2052)When the request never reached the server there is no status code. Code that assumed a non‑null value must handle
null:4. Stricter interface validation + enum name handling (#2068)
Synchronous return types are now only permitted for generated/non‑public interface members (
RestMethodInfoenforces the rule), and the System.Text.Json enum converter now maps serialized names both ways (includingJsonStringEnumMemberNameon .NET 9+). Interfaces that previously relied on unsupported sync members may now fail generation.🗞️ What's Changed
✨ Features & Enhancements
ApiRequestExceptionfor wrappingSendAsyncexceptions (new error model) by @PressXtoChris in #2052AddRefitClientoverloads and tests by @ChrisPulman in #2084... (truncated)
10.2.0
NOTE
This is a re-release of v10.1.6 which had a certificate revoked.
🗞️ What's Changed
🐛 Fixes
🧹 General Changes
📦 Dependencies
📌 Other
🔗 Full Changelog: reactiveui/refit@10.0.1...10.1.6
🙌 Contributions
💖 Thanks to all the contributors: @ChrisPulman
🤖 Automated services that contributed: @renovate[bot]
Commits viewable in compare view.
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
@dependabot rebasewill rebase this PR@dependabot recreatewill recreate this PR, overwriting any edits that have been made to it@dependabot show <dependency name> ignore conditionswill show all of the ignore conditions of the specified dependency@dependabot ignore this major versionwill close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this minor versionwill close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this dependencywill close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)