Use SDK directory for environment command search - #55925
Merged
Merged
Conversation
|
Azure Pipelines: 3 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
dsplaisted
approved these changes
Aug 25, 2026
baronfel
force-pushed
the
copilot/environment-provider-sdk-directory
branch
from
August 25, 2026 21:52
a6d604d to
a040b21
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the CLI utility EnvironmentProvider to prefer the versioned SDK directory (via SdkPaths.SdkDirectory) as the first location for executable discovery, aligning command lookup behavior with the SDK-root resolution used by the NativeAOT bridge.
Changes:
- Switch default executable search precedence from
AppContext.BaseDirectorytoSdkPaths.SdkDirectory. - Add a NativeAOT regression test that asserts commands are discovered from the versioned SDK directory first.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| test/dotnet-aot.Tests/EnvironmentProviderTests.cs | Adds regression coverage for SDK-directory-first command discovery. |
| src/Cli/Microsoft.DotNet.Cli.Utils/EnvironmentProvider.cs | Changes default command search root to the versioned SDK directory. |
Base automatically changed from
copilot/baronfel/fix-aot-forwarding-paths
to
main
August 26, 2026 15:34
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: c6929a73-7e24-4f78-830c-f6ae2a14b812
baronfel
force-pushed
the
copilot/environment-provider-sdk-directory
branch
from
August 26, 2026 15:34
a040b21 to
0712e3f
Compare
Member
Author
|
@dsplaisted ok, this one is green now too after base branch merges |
dsplaisted
approved these changes
Aug 28, 2026
Evangelink
approved these changes
Aug 28, 2026
Evangelink
left a comment
Member
There was a problem hiding this comment.
No actionable issues found.
Note
This review content was generated with AI assistance.
baronfel
had a problem deploying
to
copilot-pat-pool
August 28, 2026 13:50 — with
GitHub Actions
Failure
This was referenced Aug 28, 2026
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.
Summary
SdkPaths.SdkDirectoryas the first default executable search path inEnvironmentProviderPATHlookup behavior unchangedStacked on #55923; merge that PR first.
Testing
EnvironmentProviderTestsEnvironmentProviderTestsMicrosoft.DotNet.Cli.Utils.Tests(230 passed, 6 skipped)Microsoft.DotNet.Cli.Utilsbuild fornet11.0andnet472