Skip to content

Re-Bootstrap to .NET 11.0.100-preview.4.26210.111 - #6001

Merged
ViktorHofer merged 5 commits into
mainfrom
release-pr-11.0.100-preview.4.26210.111
Apr 14, 2026
Merged

ViktorHofer merged 5 commits into
mainfrom
release-pr-11.0.100-preview.4.26210.111

Conversation

@dotnet-bot

Copy link
Copy Markdown
Collaborator

Re-Bootstrap .NET to 11.0.0-preview.4.26210.111 / 11.0.100-preview.4.26210.111.

@dotnet-bot
dotnet-bot requested review from a team as code owners April 14, 2026 00:10
@ViktorHofer

ViktorHofer commented Apr 14, 2026 •

Copy link
Copy Markdown
Member
  D:\a\_work\1\s\.dotnet\sdk\11.0.100-preview.4.26210.111\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Publish.targets(1319,5): error NETSDK1236: The single-file bundle generation task excluded files that were expected to be included: D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\jitinterface_x64.dll, D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\clrjit_universal_arm64_x64.dll, D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\clrjit_universal_arm_x64.dll, D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\clrjit_universal_wasm_x64.dll, D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\clrjit_unix_x64_x64.dll, D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\clrjit_win_x64_x64.dll, D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\clrjit_win_x86_x64.dll. This may indicate a mismatch between the SDK's bundle filtering logic and the bundler task. [D:\a\_work\1\s\src\runtime\src\coreclr\tools\aot\ILCompiler\ILCompiler_inbuild.csproj]
  EXEC : error : Dll was not found. [D:\a\_work\1\s\src\runtime\src\coreclr\tools\aot\ILCompiler\ILCompiler_publish.csproj]
  D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\build\Microsoft.NETCore.Native.targets(311,5): error MSB3073: The command ""D:\a\_work\1\s\src\runtime\artifacts\bin\coreclr\windows.x64.Release\x64\ilc\\ilc" @"D:\a\_work\1\s\src\runtime\artifacts\obj\coreclr\ILCompiler_publish\windows.x64.Release\native\ilc.ilc.rsp"" exited with code 1. [D:\a\_work\1\s\src\runtime\src\coreclr\tools\aot\ILCompiler\ILCompiler_publish.csproj]
      0 Warning(s)
      3 Error(s)

@MichalStrehovsky @agocke can you please help with these errors? It would be great if the message could include actionable steps how to resolve the failure.

@dotnet-policy-service
dotnet-policy-service Bot requested a review from a team April 14, 2026 09:07
@ViktorHofer

ViktorHofer commented Apr 14, 2026 •

Copy link
Copy Markdown
Member

cc @jkoritzinsky @steveisok - whoever is able to help here :)

@dotnet-policy-service
dotnet-policy-service Bot requested a review from a team April 14, 2026 11:45
@MichalStrehovsky

Copy link
Copy Markdown
Member

@MichalStrehovsky @agocke can you please help with these errors? It would be great if the message could include actionable steps how to resolve the failure.

Copilot said we need to set IncludeNativeLibrariesForSelfExtract to clear it. When I said I don't want to do that, it instead said we need to set ExcludeFromSingleFile so I did that. Looks like crossgen2 project is already setting this, weird that this only breaks on Windows. Cc @elinor-fung on the error message feedback.

@ViktorHofer
ViktorHofer merged commit 7615896 into main Apr 14, 2026
10 checks passed
@ViktorHofer
ViktorHofer deleted the release-pr-11.0.100-preview.4.26210.111 branch April 14, 2026 14:13
@baronfel

baronfel commented Apr 14, 2026 •

Copy link
Copy Markdown
Member

Some context for @jkoritzinsky and @steveisok - I added this warning in dotnet/sdk#52755 when I basically copied the single-file-bundler file selection logic into MSBuild logic. We needed this duplication so that we could correctly calculate inputs and outputs for bundle generation, because there was an incrementality/correctness bug where repeated publish invocations would over-clean native dependencies because of bundle generations' untracked incrementality - we needed to be able to know which files bundle generation would not include in the bundle so that we could ensure those were correctly copied to the publish directory.

When I did this, I added a warning that would alert if the set of files that the MSBuild logic computed for exclusion wasn't complete - meaning if the bundler logic (that we have to run anyway when we actually execute bundle generation) ever reported files that we passed it an inputs that it wanted to exclude from the bundle. This would indicate a gap in the incrementality that could result in the subsequent-publish-deletes-files bug popping up again.

So the main thing I'm interested in is understanding

  • what these two files mean
  • if they should be part of the bundle
    • if yes, then the MSBuild logic needs to be updated to make sure they aren't filtered out like they are currently being before the change in this boostrap PR
    • if no, then this change is fine 👍
  • if there is a difference in bundle-inclusion for self-contained apps vs framework-dependent apps

Longer-term I raised dotnet/runtime#124051 to track the bundler APIs for input/output detection being made public so that I can use them directly in the SDK instead of replicating them in MSBuild logic.

@MichalStrehovsky

Copy link
Copy Markdown
Member

When I did this, I added a warning that would alert if the set of files that the MSBuild logic computed for exclusion wasn't complete - meaning if the bundler logic (that we have to run anyway when we actually execute bundle generation) ever reported files that we passed it an inputs that it wanted to exclude from the bundle

Does the warning we were seeing mean that there's a bug in the default handling of native libraries in the new SDK logic then? I.e. when one doesn't set IncludeNativeLibrariesForSelfExtract and doesn't set ExcludeFromSingleFile either, one component thinks we will include and the other thing thinks we will exclude?

@MichalStrehovsky

Copy link
Copy Markdown
Member

As to whether we want to include or exclude for the ilc project - it doesn't really matter, this is a non-shipping version of ilc. For repo build perf it's slightly preferable to not include them in the single file bundle (so I'm good with this change and it matches crossgen2 project with a similar purpose, the lines were likely just missed when the single file configuration of the project was added).

@elinor-fung

Copy link
Copy Markdown
Member

When I did this, I added a warning that would alert if the set of files that the MSBuild logic computed for exclusion wasn't complete - meaning if the bundler logic (that we have to run anyway when we actually execute bundle generation) ever reported files that we passed it an inputs that it wanted to exclude from the bundle

Does the warning we were seeing mean that there's a bug in the default handling of native libraries in the new SDK logic then? I.e. when one doesn't set IncludeNativeLibrariesForSelfExtract and doesn't set ExcludeFromSingleFile either, one component thinks we will include and the other thing thinks we will exclude?

Maybe specifically for native binaries? The bundler will inspect the file to determine if it is a native binary for the target platform, which I imagine the msbuild logic does not.

@baronfel

Copy link
Copy Markdown
Member

The bundler's decision for if it should include a native asset is tied to

The 'should bundle native deps' option is driven by the IncludeNativeLibrariesForSelfExtract property, and we adhere to it in the MSBuild logic (and we also get data on if the item is native or not from NuGet already).

So I think the MSBuild logic is aligned here, and the real gap is just that these items should have been marked as ExcludeFromSingleFile regardless of the changes that I made - my changes just included an early-warning system so that we'd see the discrepancy. We can definitely make the message more actionable - it seems likely that either a) the items need to be marked 'ExcludeFromSingleFile', or that an issue needs to be raised against the dotnet SDK.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants