[release/11.0.1xx] Use SDK directory for CLI forwarding and command search - #55988
Open
baronfel wants to merge 5 commits into
Open
[release/11.0.1xx] Use SDK directory for CLI forwarding and command search#55988baronfel wants to merge 5 commits into
baronfel wants to merge 5 commits into
Conversation
Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com>
Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com>
Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com>
Resolve NuGet, VSTest, and FSI assets from SdkPaths so NativeAOT help forwarding uses the selected SDK instead of the muxer directory. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: c6929a73-7e24-4f78-830c-f6ae2a14b812
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: c6929a73-7e24-4f78-830c-f6ae2a14b812
|
Azure Pipelines: Successfully started running 1 pipeline(s). 2 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes dotnet format forwarding path resolution so the NativeAOT CLI uses the versioned SDK directory (via SdkPaths.SdkDirectory) instead of AppContext.BaseDirectory, matching where DotnetTools/dotnet-format is laid out in the SDK.
Changes:
- Update
FormatForwardingAppto resolvedotnet-format.dll,.deps.json, and.runtimeconfig.jsonfromSdkPaths.SdkDirectory. - Add an AOT-focused regression test that sets
Microsoft.DotNet.Sdk.Rootand verifies forwardeddotnet formatpaths use that versioned SDK directory. - Extract the test helper
SdkDirectoryScopeinto its own file for reuse across AOT tests.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| test/dotnet-aot.Tests/SdkDirectoryScope.cs | Adds a reusable scope helper to set/restore Microsoft.DotNet.Sdk.Root and clear the SdkPaths cache for tests. |
| test/dotnet-aot.Tests/MSBuildEvaluationTests.cs | Removes the inline SdkDirectoryScope now that it’s shared. |
| test/dotnet-aot.Tests/FormatForwardingAppTests.cs | Adds regression coverage ensuring dotnet format forwarding uses the versioned SDK directory. |
| src/Cli/dotnet/Commands/Format/FormatForwardingApp.cs | Switches dotnet format forwarder asset paths from AppContext.BaseDirectory to SdkPaths.SdkDirectory. |
baronfel
had a problem deploying
to
copilot-pat-pool
August 28, 2026 14:10 — with
GitHub Actions
Failure
Member
Author
|
@dsplaisted here are those three PRs backported to 11 so that AOT forwarded apps work |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #55920, #55923, and #55925 to release/11.0.1xx.