-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Show specific error message for dotnet <app_path>
where app_path is a non-dll/exe file that exists
#116940
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
… separators Co-authored-by: elinor-fung <47805090+elinor-fung@users.noreply.github.com>
Co-authored-by: elinor-fung <47805090+elinor-fung@users.noreply.github.com>
dotnet <app_path>
where <app_path> is a non-dll/exe file that existsdotnet <app_path>
where app_path is a non-dll/exe file that exists
…reporting Co-authored-by: jkotas <6668460+jkotas@users.noreply.github.com>
…error directly in command_line.cpp Co-authored-by: elinor-fung <47805090+elinor-fung@users.noreply.github.com>
src/installer/tests/HostActivation.Tests/DotnetArgValidation.cs
Outdated
Show resolved
Hide resolved
src/installer/tests/HostActivation.Tests/DotnetArgValidation.cs
Outdated
Show resolved
Hide resolved
src/installer/tests/HostActivation.Tests/DotnetArgValidation.cs
Outdated
Show resolved
Hide resolved
src/installer/tests/HostActivation.Tests/DotnetArgValidation.cs
Outdated
Show resolved
Hide resolved
src/installer/tests/HostActivation.Tests/DotnetArgValidation.cs
Outdated
Show resolved
Hide resolved
src/installer/tests/HostActivation.Tests/DotnetArgValidation.cs
Outdated
Show resolved
Hide resolved
src/installer/tests/HostActivation.Tests/DotnetArgValidation.cs
Outdated
Show resolved
Hide resolved
…tions, remove test file Co-authored-by: elinor-fung <47805090+elinor-fung@users.noreply.github.com>
Co-authored-by: elinor-fung <47805090+elinor-fung@users.noreply.github.com>
src/installer/tests/HostActivation.Tests/DotnetArgValidation.cs
Outdated
Show resolved
Hide resolved
Co-authored-by: elinor-fung <47805090+elinor-fung@users.noreply.github.com>
This comment was marked as spam.
This comment was marked as spam.
On the bright side, Copilot gets smarter for future PRs. Plus, CO₂ in its supercritical form has some surprising uses, like powering sCO₂ turbines for electricity. So hey, not all doom and gloom on the hippie’s fry! ✌️ |
This comment was marked as off-topic.
This comment was marked as off-topic.
Carbon capture has legitimate applications if used alongside real emissions cuts. And LLMs are far beyond Markov chains, they learn complex patterns across context, not just next-word guessing. |
Co-authored-by: jkotas <6668460+jkotas@users.noreply.github.com>
src/installer/tests/HostActivation.Tests/FrameworkDependentAppLaunch.cs
Outdated
Show resolved
Hide resolved
Co-authored-by: elinor-fung <47805090+elinor-fung@users.noreply.github.com>
Currently, when a user runs
dotnet <app_path>
and the host determines that<app_path>
is not a runnable app, it's treated as a CLI command and routed to the SDK, which shows a generic error message.This PR improves the user experience by detecting when the user passes a path to an existing non-dll/exe file and showing a specific error message instead of routing to the SDK.
cc @dotnet/appmodel @AaronRobinsonMSFT
Changes Made
Core Logic Enhancement:
command_line.cpp
to detect the specific scenario:Behavior Change:
Before:
After:
$ dotnet /path/to/config.json The application '/path/to/config.json' does not exist or is not a managed .dll or .exe.
Preserves Existing Behavior:
dotnet build
) still route to SDKdotnet exec
behavior unchangedTest Coverage
Added comprehensive tests covering:
./subdir/file.txt
All existing tests pass, confirming no regressions.
Fixes #116939.
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.