-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Update .NET SDK to 9.0.300 #11887
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
base: main
Are you sure you want to change the base?
Update .NET SDK to 9.0.300 #11887
Conversation
Co-authored-by: rainersigwald <[email protected]>
global.json
Outdated
@@ -1,9 +1,10 @@ | |||
{ | |||
"sdk": { | |||
"version": "9.0.300", |
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.
Do not pin the SDK here. Update only the tools.dotnet
version.
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.
I've removed the explicit SDK version from the sdk section while keeping the tools.dotnet version updated to 9.0.300. Changes are in commit 8c5ff36.
Co-authored-by: rainersigwald <[email protected]>
The change to the |
I've fixed the warnings-as-errors in the WeakStringCache_Tests.cs file by simplifying the lambda expressions (removed unnecessary type annotations) to address the IDE0350 warnings. Both the net9.0 and net472 builds now succeed with WarningsAsErrors=IDE0350. Changes are in commit 9f83e5c. Warning Firewall rules blocked me from connecting to one or more addressesI tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
@@ -684,12 +684,12 @@ public void VerifyAssemblyNameExSerializationByTranslator(string assemblyName) | |||
MemoryStream serializationStream = new MemoryStream(); | |||
ITranslator writeTranslator = BinaryTranslator.GetWriteTranslator(serializationStream); | |||
|
|||
writeTranslator.Translate(ref assemblyNameOriginal, (ITranslator t) => new AssemblyNameExtension(t)); |
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.
Ok I want opinions on this one. I have two:
- I think the old lambdas were fine? Like sure maybe we can type-infer but specifying it doesn't seem horrible?
- I don't love enforcing all of the rules we have in the context of our tests. I want our tests to be good, but for some things like this I'm way less bothered . . .
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.
I slightly don't like IDE0350, since the code is then less immediately understandable as a text file (which is important for copilots).
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.
doesn't copilot check AssemblyNameExtension ctor ?
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.
It might be able to use a tool to do so, but it would have to decide to do that. I think this is a rule that I don't want to have to stick to, so I reconfigured the rule instead.
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
This is contentious--the untyped lambdas can be harder to read and for LLMs to work with so let's not enforce it.
99a2dd0
to
27e862f
Compare
This PR updates the global.json file to use .NET SDK version 9.0.300 instead of the previous 9.0.106 version.
Changes made:
The update ensures that the repository builds with the latest .NET 9.0 SDK version.
Verified changes by:
Fixes #11886.
Warning
Firewall rules blocked me from connecting to one or more addresses
I tried to connect to the following addresses, but was blocked by firewall rules:
dnceng.pkgs.visualstudio.com
/home/REDACTED/work/msbuild/msbuild/.dotnet/dotnet /home/REDACTED/work/msbuild/msbuild/.dotnet/sdk/9.0.300/NuGet.Build.Tasks.Console.dll Recursive=True;CleanupAssetsForUnsupportedProjects=True;DisableParallel=False;Force=False;ForceEvaluate=False;HideWarningsAndErrors=False;IgnoreFailedSources=False;Interactive=False;NoCache=False;NoHttpCache=False;RestorePackagesConfig=False /home/REDACTED/work/msbuild/msbuild/.dotnet/sdk/9.0.300/MSBuild.dll /home/REDACTED/work/msbuild/msbuild/MSBuild.sln ContinuousIntegrationBuild=false;Configuration=Debug;RepoRoot=/home/REDACTED/work/msbuild/msbuild/;DotNetBuildRepo=false;ArcadeBuildFromSource=false;DotNetBuildSourceOnly=false;Rebuild=false;Test=false;Pack=false;IntegrationTest=false;PerformanceTest=false;VersionsPropsPath=/home/REDACTED/work/msbuild/msbuild/eng/Versions.props;__BuildPhase=SolutionRestore;_NETCORE_ENGINEERING_TELEMETRY=Restore;MSBuildRestoreSessionId=3ca5e0e0-e149-4144-9aeb-522ca3e0315f;RestoreUseStaticGraphEvaluation=true;ExcludeRestorePackageImports=True;OriginalMSBuildStartupDirectory=/home/REDACTED/work/msbuild/msbuild;SolutionPath=/home/REDACTED/work/msbuild/msbuild/MSBuild.sln
(dns block)/home/REDACTED/work/msbuild/msbuild/.dotnet/dotnet /home/REDACTED/work/msbuild/msbuild/.dotnet/sdk/9.0.300/NuGet.Build.Tasks.Console.dll Recursive=True;CleanupAssetsForUnsupportedProjects=True;DisableParallel=False;Force=False;ForceEvaluate=False;HideWarningsAndErrors=False;IgnoreFailedSources=False;Interactive=False;NoCache=False;NoHttpCache=False;RestorePackagesConfig=False /home/REDACTED/work/msbuild/msbuild/.dotnet/sdk/9.0.300/MSBuild.dll /home/REDACTED/work/msbuild/msbuild/MSBuild.sln ContinuousIntegrationBuild=false;Configuration=Debug;RepoRoot=/home/REDACTED/work/msbuild/msbuild/;DotNetBuildRepo=false;ArcadeBuildFromSource=false;DotNetBuildSourceOnly=false;Rebuild=false;Test=false;Pack=false;IntegrationTest=false;PerformanceTest=false;SkipTemplateBuild=true;VersionsPropsPath=/home/REDACTED/work/msbuild/msbuild/eng/Versions.props;__BuildPhase=SolutionRestore;_NETCORE_ENGINEERING_TELEMETRY=Restore;MSBuildRestoreSessionId=06926f6a-5ade-4ce0-b89e-65f56c21ae76;RestoreUseStaticGraphEvaluation=true;ExcludeRestorePackageImports=True;OriginalMSBuildStartupDirectory=/home/REDACTED/work/msbuild/msbuild;SolutionPath=/home/REDACTED/work/msbuild/msbuild/MSBuild.sln
(dns block)dotnet build src/MSBuild/MSBuild.csproj
(dns block)If you need me to access, download, or install something from one of these locations, you can either:
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.