Skip to content

Building solution in VS 2017 fails with NETSDK1007 error #4497

Open
@vsfeedback

Description

@vsfeedback

I'm trying to build a solution that contains a .NET Core 2.1 unit test project and a few .NET Standard 2.0 project dependencies. I've attached the solution.

Building the solution through the command line using either "dotnet build NetSdk1007.sln" or "msbuild NetSdk1007.sln" is successful and I can run my tests in the command line and in Test Explorer. However, when I build the solution in Visual Studio, I get the error "NETSDK1007: Cannot find project info for 'C:\NetSdk1007\Dependency\Dependency.csproj'. This can indicate a missing project reference."

I have the command line workaround, but I'd like to be able to build this solution in Visual Studio and run the tests in Test Explorer.

This issue has been moved from https://developercommunity.visualstudio.com/content/problem/376855/building-solution-in-vs-2017-fails-with-netsdk1007.html
VSTS ticketId: 724845

These are the original issue comments:

Kevin Pilch [MSFT] on 11/7/2018, 08:59 AM (78 days ago):

Hi - do you have any projects unloaded, or any projects that have ProjectReference elements to projects that are not the .sln file? The in VS restore currently relies on the in memory project model, and fails in this way if a dependent project is unloaded or not present in the .sln file.


Allan Rodriguez on 11/7/2018, 10:10 AM (78 days ago):

Hello,

There are no unloaded projects or ProjectReferences to projects that are outside the solution. I made a test solution using only five projects to reproduce my problem and, aside from a couple NuGet package references, there are no references to outside projects.

Juan José Mejia [MSFT] on 1/10/2019, 07:47 AM (14 days ago):

We appreciate you taking the time to report this problem. We are currently prioritizing problems that are impacting a broad set of our customers, so we may not be able to investigate this one immediately. We know this problem is important to you, so we will continue to monitor it.

These are the original issue solutions:
(no solutions)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions