Skip to content

Work around license scan timeout by scanning source-build-assets serially - #55219

Merged
mthalman merged 1 commit into
dotnet:release/9.0.1xxfrom
mthalman:mthalman-port-license-scan-fix
Jul 10, 2026
Merged

mthalman merged 1 commit into
dotnet:release/9.0.1xxfrom
mthalman:mthalman-port-license-scan-fix

Conversation

@mthalman

@mthalman mthalman commented Jul 9, 2026

Copy link
Copy Markdown
Member

Backport of dotnet/dotnet#7626

Copilot AI review requested due to automatic review settings July 9, 2026 19:16
@mthalman
mthalman requested review from a team as code owners July 9, 2026 19:16

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 backports a change to make the VMR license-scan pipeline more reliable by allowing the smoke test’s scancode invocation to run with a configurable process count (including serial execution for problematic repos).

Changes:

  • Add a new runtime config switch (LicenseScanProcessCount) to the SourceBuild smoke tests and plumb it from MSBuild properties.
  • Update LicenseScanTests to use the configured scancode --processes value (defaulting to 4 when not provided).
  • Update vmr-license-scan.yml to flow a per-repo scanProcessCount through the job matrix and into the test run.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.SmokeTests/Microsoft.DotNet.SourceBuild.SmokeTests.csproj Adds a runtime host configuration option to pass LicenseScanProcessCount into the test process.
src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.SmokeTests/LicenseScanTests.cs Uses the configured process count when invoking scancode (fallback default remains 4).
src/SourceBuild/content/test/Microsoft.DotNet.SourceBuild.SmokeTests/Config.cs Adds parsing for the new LicenseScanProcessCount AppContext switch.
src/SourceBuild/content/eng/pipelines/vmr-license-scan.yml Extends the matrix to include scanProcessCount and passes it to the test as an MSBuild property.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@mthalman
mthalman merged commit 379ba8e into dotnet:release/9.0.1xx Jul 10, 2026
34 of 36 checks passed
@mthalman
mthalman deleted the mthalman-port-license-scan-fix branch July 10, 2026 13:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants