Skip to content

Adding an .esproj project to the solution breaks dotnet list package #12817

Open
@cremor

Description

@cremor

NuGet Product Used

dotnet.exe

Product Version

7.0.400

Worked before?

No response

Impact

It's more difficult to complete my work

Repro Steps & Context

  1. Create a new solution with a .NET 7 project.
  2. Run dotnet list package in the solution folder. Notice that it shows a correct output for the project.
  3. Add a new "Standalone TypeScript Angular Project" to the solution. (This is an .esproj file type.)
  4. Make sure to save the solution.
  5. Run dotnet list package in the solution folder. Notice that it shows an error about the project "AngularProject1.esproj" saying that it uses "package.config" for NuGet packages. This is wrong!
  6. Add another new .NET 7 project to the solution
  7. Make sure to save the solution.
  8. Run dotnet list package in the solution folder. Notice that it shows the exact same output as in step 5. There is no output for the new project created in step 6!
  9. Modify the solution file so that the "AngularProject1.esproj" is listed after the two .NET projects.
  10. Run dotnet list package in the solution folder. Notice that it now lists both .NET projects before showing the error. This means that the behavior of dotnet list package is dependent on the order of the projects in the solution folder!

Expected behavior:

  • dotnet list package should not show an error about .esproj projects in the solution.
  • dotnet list package should continue with other projects in the solution even if it has an error with one project.

Actual behavior:

  • dotnet list package shows a wrong error message when there is an .esproj project in the solution.
  • dotnet list package doesn't continue with other projects in the solution once it finds an .esproj project

Additional Information:
I'm using flags like dotnet list package --outdated to check my solution for outdated/deprecated/vulnerable NuGet packages.

Verbose Logs

> dotnet list package --verbosity diag
Project 'ConsoleApp1' has the following package references
   [net7.0]: No packages were found for this framework.
The project `C:\Projects\ConsoleApp1\AngularProject1\AngularProject1.esproj` uses package.config for NuGet packages, while the command works only with package reference projects.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions