-
Notifications
You must be signed in to change notification settings - Fork 39
XS✔ ◾ Added .NET 10 dual targeting #779
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
PR Metrics✔ Thanks for keeping your pull request small.
Metrics computed by PR Metrics. Add it to your Azure DevOps and GitHub PRs! |
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.
Pull request overview
This PR adds .NET 10 as a target framework alongside the existing .NET 9 support, enabling multi-targeting compilation and testing. The changes address framework-specific compatibility issues including namespace conflicts and built-in functionality that replaces external packages in .NET 10.
- Updates the latest supported .NET version from 9.0 to 10.0 in build configuration
- Adds package references for older framework support (Microsoft.FeatureManagement and System.Linq.Async)
- Works around namespace conflicts by using fully qualified names where .NET 10 introduces conflicting types
- Conditionally excludes System.Linq.Async package for .NET 10 since the functionality is now built into the framework
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| Directory.Build.props | Updates LatestSupportedDotNetVersion property from net9.0 to net10.0 to enable .NET 10 targeting |
| Directory.Packages.props | Adds Microsoft.FeatureManagement and System.Linq.Async package versions to the "Previous DotNet Package Versions" section for .NET 9 compatibility |
| src/Hosting.Services.Web/HostBuilderExtensions.cs | Fully qualifies Validation.ThrowIfNullOrWhiteSpace calls to resolve namespace conflict introduced in .NET 10 |
| tests/FeatureManagement.UnitTests/Microsoft.Omex.Extensions.FeatureManagement.UnitTests.csproj | Adds conditional exclusion of System.Linq.Async package for net10.0 since the functionality is built into the framework |
You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.
tests/FeatureManagement.UnitTests/Microsoft.Omex.Extensions.FeatureManagement.UnitTests.csproj
Outdated
Show resolved
Hide resolved
K-Cully
left a comment
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.
The package references need to be fixed.
The current change reverts all 9.x builds to use 8.x dependencies.
tests/FeatureManagement.UnitTests/Microsoft.Omex.Extensions.FeatureManagement.UnitTests.csproj
Outdated
Show resolved
Hide resolved
tests/FeatureManagement.UnitTests/Microsoft.Omex.Extensions.FeatureManagement.UnitTests.csproj
Outdated
Show resolved
Hide resolved
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.
Pull request overview
Copilot reviewed 10 out of 10 changed files in this pull request and generated 4 comments.
tests/FeatureManagement.UnitTests/Microsoft.Omex.Extensions.FeatureManagement.UnitTests.csproj
Show resolved
Hide resolved
This reverts commit 2d84785.
This pull request updates the supported .NET versions to include .NET 10, resolving the conflicts in compilation and unit testing, keeping the older framework support unchanged.
In the following, the implementation details:
HostBuilderExtensionsclass.System.Linq.Asyncpackage conditional to every framework except .NET 10: this condition does not make use of the alias defined in theDirectory.Build.propsas it is a specific issue related to .NET 10 where the method used from the package has been included in the Framework itself.