You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The task-authoring analyzers validate MSBuild task code, including multithreaded-task safety. They now build as the standalone Microsoft.Build.TaskAuthoring.Analyzer package. The package is opt-in and is not exposed transitively by Microsoft.Build.Framework.
Steps
Publish to the internal feed as a NuGet package for early adopters
Task authors in dotnet/sdk, dotnet/nuget, dotnet/roslyn, dotnet/arcade, the VMR, and other repositories that explicitly install Microsoft.Build.TaskAuthoring.Analyzer.
Definition of done
A task author can explicitly install Microsoft.Build.TaskAuthoring.Analyzer from NuGet.org. The default rules do not add build-breaking diagnostics for regular non-MT tasks, full migration analysis has documented opt-in configuration, there are no known P1 false positives, and the VMR and Arcade build with the analyzer.
@jankratochvilcz the idea to tie the diagnostics to the presence of the attribute was more defensive than that - it's a library compat issue where the analyzer could run on a user that didn't have the same runtime version of MSBuild. If the user wasn't targeting a version of MSBuild Hosts that understood MT (or the type-parameter binding) then their Task would start to crash.
Immediate next focus: Getting the analyzer triggers right and ship them via Microsoft.Build.Framework. Fixing the triggers is important so that we don't accidentally regress existing non-MT tasks. Afterwards focus on the overall quality of these analyzers.
Activity
baronfel commentedon Jun 16, 2026
@jankratochvilcz the idea to tie the diagnostics to the presence of the attribute was more defensive than that - it's a library compat issue where the analyzer could run on a user that didn't have the same runtime version of MSBuild. If the user wasn't targeting a version of MSBuild Hosts that understood MT (or the type-parameter binding) then their Task would start to crash.
jankratochvilcz commentedon Jun 17, 2026
@baronfel please feel free to amend the ticket 🙏
ViktorHofer commentedon Aug 4, 2026
MSBuild triage: We should do this for MT on by default. Needs an assignee.
ViktorHofer commentedon Aug 19, 2026
Immediate next focus: Getting the analyzer triggers right and ship them via Microsoft.Build.Framework. Fixing the triggers is important so that we don't accidentally regress existing non-MT tasks. Afterwards focus on the overall quality of these analyzers.
[TaskAnalyzer] Align diagnostic severities and ignore open generic IT…
Scope MT-specific TaskAnalyzer diagnostics and support .editorconfig (#…
1 remaining item
[-][MT] Ship multi-threaded task analyzer as a NuGet package[/-][+]Ship the MSBuild task-authoring analyzers[/+]