Skip to content

Bump dotnet-sdk from 11.0.100-preview.1.26104.118 to 11.0.100-preview.2.26159.112#7522

Open
dependabot[bot] wants to merge 2 commits intomainfrom
dependabot/dotnet_sdk/dotnet-sdk-11.0.100.pre.preview.2.26159.112
Open

Bump dotnet-sdk from 11.0.100-preview.1.26104.118 to 11.0.100-preview.2.26159.112#7522
dependabot[bot] wants to merge 2 commits intomainfrom
dependabot/dotnet_sdk/dotnet-sdk-11.0.100.pre.preview.2.26159.112

Conversation

@dependabot
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Mar 11, 2026

Bumps dotnet-sdk from 11.0.100-preview.1.26104.118 to 11.0.100-preview.2.26159.112.

Release notes

Sourced from dotnet-sdk's releases.

.NET 11 Preview 2

Release

Commits

Dependabot compatibility score

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 rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will 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 version will 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 dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [dotnet-sdk](https://github.com/dotnet/sdk) from 11.0.100-preview.1.26104.118 to 11.0.100.pre.preview.2.26159.112.
- [Release notes](https://github.com/dotnet/sdk/releases)
- [Commits](dotnet/sdk@v11.0.100-preview.1.26104.118...v11.0.100-preview.2.26159.112)

---
updated-dependencies:
- dependency-name: dotnet-sdk
  dependency-version: 11.0.100.pre.preview.2.26159.112
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file dotnet_sdk_package_manager Pull requests that update dotnet_sdk_package_manager code labels Mar 11, 2026
@Youssef1313 Youssef1313 changed the title Bump dotnet-sdk from 11.0.100-preview.1.26104.118 to 11.0.100.pre.preview.2.26159.112 Bump dotnet-sdk from 11.0.100-preview.1.26104.118 to 11.0.100-preview.2.26159.112 Mar 11, 2026
@Youssef1313 Youssef1313 enabled auto-merge (squash) March 11, 2026 08:11
@Youssef1313
Copy link
Member

Youssef1313 commented Mar 11, 2026

We are getting now IDE0305 while we didn't set this to warning in any place that I can see. Not sure if it's a Roslyn regression between P1 and P2.

I'm fine fixing the extra diagnostics though.

@Youssef1313
Copy link
Member

@akhera99 @ToddGrun Do you know if this is somehow expected? Or if it's a regression in P2?

@CyrusNajmabadi
Copy link

What is a repro case?

@Youssef1313
Copy link
Member

@CyrusNajmabadi I haven't worked towards getting a minimal repro. So this dependabot branch is all I got. On Preview 1 we didn't get the diagnostic (as we are not enabling it), but on Preview 2 we get a diagnostic.

@Evangelink
Copy link
Member

I have seen similar behavior on some other repos, bumping preview 1 to 2 had many IDEXXX analyzers now triggering. Maybe you "just" fixed something.

@CyrusNajmabadi
Copy link

Without actually spring the case, it's nearly impossible to answer:

Not sure if it's a Roslyn regression between P1 and P2.

@Evangelink
Copy link
Member

src/Adapter/MSTestAdapter.PlatformServices/Helpers/ManagedNameParser.cs(125,48): error IDE0305: (NETCORE_ENGINEERING_TELEMETRY=Build) Collection initialization can be simplified (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/style-rules/ide0305)

If you just take the code there you have your repro

@CyrusNajmabadi
Copy link

That's this line: parameterTypes = types.ToArray();

I don't see any reason to not get the analyzer suggestion there. As an example, you can now write that more simply as: parameterTypes = [.. types];.

Why do you think this is a regression to get this analyzer firing here?

@Evangelink
Copy link
Member

The trigger seems correct to me, I think we are more suprised to have new issues showing up by a bump of preview version

@Youssef1313
Copy link
Member

I don't see where we are setting the severity of the analyzer to warning. IDExxxx should all be suggestion by default unless explicitly enabled right? That's what surprised me. In addition, there were no changes in that specific analyzer between P1 and P2. Maybe I could be wrong and there is something that sets it to warning, but I don't see it.

@Youssef1313
Copy link
Member

Note that in Preview 1, I'm able to see the diagnostic in IDE as a suggestion. So the analyzer was already reporting in this case. It's just that the severity is changing to warning out of sudden.

@Youssef1313
Copy link
Member

Youssef1313 commented Mar 12, 2026

In P1, this is the globalconfig file that's used:

  • D:\a\_work\1\s\.dotnet\sdk\11.0.100-preview.1.26104.118\Sdks\Microsoft.NET.Sdk\analyzers\build\config\analysislevel_10_recommended.globalconfig

In P2, it's:

  • D:\a\_work\1\s\.dotnet\sdk\11.0.100-preview.2.26159.112\Sdks\Microsoft.NET.Sdk\codestyle\cs\build\config\analysislevelstyle_recommended.globalconfig

The full list of AnalyzerConfigFiles in P1:

AnalyzerConfigFiles
    D:\a\_work\1\s\.editorconfig
    D:\a\_work\1\s\.packages\polyfill\9.7.3\.editorconfig
    D:\a\_work\1\s\src\.editorconfig
    D:\a\_work\1\s\.globalconfig
    D:\a\_work\1\s\artifacts\obj\MSTestAdapter.PlatformServices\Debug\net9.0\MSTestAdapter.PlatformServices.GeneratedMSBuildEditorConfig.editorconfig
    D:\a\_work\1\s\.dotnet\sdk\11.0.100-preview.1.26104.118\Sdks\Microsoft.NET.Sdk\analyzers\build\config\analysislevel_10_recommended.globalconfig

And the full list of AnalyzerConfigFiles in P2:

AnalyzerConfigFiles
    D:\a\_work\1\s\.editorconfig
    D:\a\_work\1\s\.packages\polyfill\9.7.3\.editorconfig
    D:\a\_work\1\s\src\.editorconfig
    D:\a\_work\1\s\.globalconfig
    D:\a\_work\1\s\.dotnet\sdk\11.0.100-preview.2.26159.112\Sdks\Microsoft.NET.Sdk\codestyle\cs\build\config\analysislevelstyle_recommended.globalconfig
    D:\a\_work\1\s\artifacts\obj\MSTestAdapter.PlatformServices\Debug\net9.0\MSTestAdapter.PlatformServices.GeneratedMSBuildEditorConfig.editorconfig

Interestingly, the one in P1 is only about CAxxxx rules, and the one in P2 is only about IDExxxx rules.

So it's not only about IDExxxx rules now being enabled as warning by default out of sudden (which may or may not be expected - I'll need to dig further to understand). But it seems to me like now CAxxxx rules that were enabled are warnings might no longer be enabled.

The main change I can see is the bump of _LatestAnalysisLevel from 9.0 to 10.0. I'm also not sure if _LatestAnalysisLevel is supposed to actually be 11 during .NET 11 previews?

Adding @baronfel as well.

@Youssef1313
Copy link
Member

In P2, NetAnalyzers (CAxxxx) is resolving _GlobalAnalyzerConfigFileName_MicrosoftCodeAnalysisNetAnalyzers to analysislevel_12_recommended.globalconfig (which does not exist?)

So that's why CAxxxx are no longer enabled. Note that the generation of the globalconfig files relies on the release numbers in AnalyzerReleases.Shipped.md AFAIK.

I haven't yet tried to dig into why IDExxxx are now enabled and whether that's expected. In the process of doing that.

@Youssef1313
Copy link
Member

Youssef1313 commented Mar 12, 2026

EffectiveAnalysisLevel between P1 and P2 jumped from 10 to 12 (we set AnalysisLevel to preview - so I think 12 is expected). The target AddGlobalAnalyzerConfigForPackage_MicrosoftCodeAnalysisCSharpCodeStyle adds editorconfig for IDExxxx rules based on this condition:

    <ItemGroup Condition="Exists('$(_GlobalAnalyzerConfigFile_MicrosoftCodeAnalysisCSharpCodeStyle)') and
                           ('$(AnalysisLevelStyle)' != '$(AnalysisLevel)' or '$(AnalysisModeStyle)' != '$(AnalysisMode)' or ('$(EffectiveAnalysisLevelStyle)' != '' and $([MSBuild]::VersionGreaterThanOrEquals('$(EffectiveAnalysisLevelStyle)', '11.0'))))">
      <EditorConfigFiles Include="$(_GlobalAnalyzerConfigFile_MicrosoftCodeAnalysisCSharpCodeStyle)" />
    </ItemGroup>

I cannot make sense of most parts of the condition, but the important part, I think, is the >= 11 check.

I think there are two things here:

  • CAxxxx no longer working as expected. This looks like a bug to me.
  • More IDExxxx are now enabled. This looks like an unintentional change that makes AnalysisLevel affecting IDExxx analyzers. The documentation mentions it only for CAxxxx. I think it should be documented as a breaking change that AnalysisLevel now impacts also CodeStyle analyzers. Also, is it documented somewhere what IDExxxx analyzers are enabled in default, minimum, and recommended analysis modes? For example, IDE0004 is not enabled in recommended, but IDE0005 is. Is that documented somewhere without digging into the globalconfigs inside the SDK installation?

I opened:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file dotnet_sdk_package_manager Pull requests that update dotnet_sdk_package_manager code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants