Skip to content

Use global.json-matched SDK for VMR license scan (1xx) - #8012

Merged
nagilson merged 1 commit into
release/10.0.1xxfrom
nagilson/license-scan-1xx-bootstrap-sdk
Jul 29, 2026
Merged

nagilson merged 1 commit into
release/10.0.1xxfrom
nagilson/license-scan-1xx-bootstrap-sdk

Conversation

@nagilson

@nagilson nagilson commented Jul 28, 2026 •

Copy link
Copy Markdown
Member

What

The VMR license scan job launched dotnet test with the source-build test container's system .NET SDK (currently 10.0.302). On the servicing branches whose global.json pins a different feature band (this branch pins 10.0.1xx), SDK resolution fails with "A compatible .NET SDK was not found" (exit 155) and the scan never runs.

Fix

Install the global.json-matched SDK via eng/common/tools.sh (InitializeDotNetCli) and invoke that dotnet for the scan — the same pattern the sibling Publish_Test_Results_PR job already uses. /p:SkipPrepareSdkArchive=true is kept because the license scan only reads source and does not need the source-built SDK archive.

Testing

Once merged, the next scheduled/triggered run of the source-build license scan pipeline on this branch should launch successfully instead of failing to find an SDK.

Tracking: dotnet/source-build#5623

The source-build license scan job ran `dotnet test` with the container's
system .NET SDK. The shared source-build test container now ships a newer
.NET 10 SDK than this branch's global.json pins (different feature band),
so SDK resolution failed and the scan never ran. Install the global.json
SDK via eng/common/tools.sh and invoke that dotnet instead.

Related to dotnet/source-build#5623

Co-authored-by: Copilot <[email protected]>
Copilot-Session: cdfea5e9-cd26-4b0a-86f7-aecc8d23d983
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
1 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

@nagilson
nagilson marked this pull request as ready for review July 29, 2026 20:18
@nagilson
nagilson requested review from a team as code owners July 29, 2026 20:18
@nagilson
nagilson merged commit e71cf4e into release/10.0.1xx Jul 29, 2026
11 checks passed
@nagilson
nagilson deleted the nagilson/license-scan-1xx-bootstrap-sdk branch July 29, 2026 20:18
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
1 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.


- script: >
dotnet test
$(DotNetPath)/dotnet test

@ViktorHofer ViktorHofer Jul 29, 2026 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh a regression that I introduced. Please just use eng/common/dotnet.sh instead which handles all that stuff automatically.

dkurepa pushed a commit to maestro-auth-test/dotnet that referenced this pull request Aug 11, 2026
…nstall

Follow-up to dotnet#8012. That change worked around an SDK-resolution regression by
installing the global.json-matched SDK via eng/common/tools.sh and invoking it
through $(DotNetPath)/dotnet. Per review feedback, eng/common/dotnet.sh already
acquires the correct SDK and invokes it, so use it directly and drop the manual
install step.

Related to dotnet/source-build#5623

Co-authored-by: Copilot <[email protected]>
Copilot-Session: e7257ff7-f19d-4b7c-ba41-cdac231893fb
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.

3 participants