dotnet / dotnet/sdk

`dotnet package remove <package>` in root with only `.slnx` (or `.sln`) doesn't work

Open
#52,762 2 comments 0 reactions 0 assignees View on GitHub
Area-Workloads
Dominant language
C#
Stars
3.2k
Forks
1.3k
PR merge metrics
PR metrics pending

Description

I didn't see a feature request for this so I assume it's a bug

### Describe the bug
Run `dotnet package remove ` in the root of your repo that only has and `.slnx` (or `sln`).
Gives this error message `Could not find any project in `

### To Reproduce

Run `dotnet package remove ` in the root of your repo that only has and `.slnx` (or `sln`).
Gives this error message `Could not find any project in `

### Exceptions (if any)

N/A

### Further technical details
details of dotnet --info


.NET SDK:
Version: 10.0.102
Commit: 4452502459
Workload version: 10.0.100-manifests.73000c7b
MSBuild version: 18.0.7+445250245

Runtime Environment:
OS Name: Windows
OS Version: 10.0.26200
OS Platform: Windows
RID: win-x64
Base Path: C:\Program Files\dotnet\sdk\10.0.102\

.NET workloads installed:
There are no installed workloads to display.
Configured to use workload sets when installing new manifests.
No workload sets are installed. Run "dotnet workload restore" to install a workload set.

Host:
Version: 10.0.2
Architecture: x64
Commit: 4452502459

.NET SDKs installed:
8.0.417 [C:\Program Files\dotnet\sdk]
9.0.310 [C:\Program Files\dotnet\sdk]
10.0.102 [C:\Program Files\dotnet\sdk]

.NET runtimes installed:
Microsoft.AspNetCore.App 8.0.23 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 9.0.12 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 10.0.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 8.0.23 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 9.0.12 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 10.0.2 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 8.0.23 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 9.0.12 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 10.0.2 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]

Other architectures found:
None

Environment variables:
DOTNET_CLI_TELEMETRY_OPTOUT [1]
DOTNET_NOLOGO [1]

global.json file:
\global.json

Learn more:
https://aka.ms/dotnet/info

Download .NET:
https://aka.ms/dotnet/download

- The IDE (VS / VS Code/ VS4Mac) you're running on, and its version
N/A (using the SDK from the CLI, maybe this question should be changed to cover that scenario?)

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.