Restore target does not exist when building

C:\\src\ : error MSB4057: The target "Restore" does not exist in the project. [C :\\src\] Running build failed. Error: Building src/ failed with exitcode 1

Votes Newest

Answers 4

Update to the latest Visual Studio (currently: Visual Studio 2017).

Ensure that all the F# and .NET Core components are installed (found in the VS installer under "Individual Components).

Posted 3 months ago

MSB4019: The imported project "c:....paket\Paket.Restore.targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk

what exactly is missing?

Posted 3 months ago

for me dotnet sdk helped:


Posted 3 months ago

In my case it was the wrong compiler, using the VS2017 instead of VS2015 did the trick - but I downloaded .net core and .net framework before that, that did not work (properly because the old compiler was still selected automatically - but can't say for sure)

Posted 3 months ago