简体   繁体   中英

Build fails in vs2015 with no errors

I have an ASP.NET core 1.0 project I created in Visual Studio 2015 (update 3). If I try to build the project within VS I get the following in my output window and there are no errors in the Error List:

1>------ Build started: Project: QuickStartIdentiyServer4, Configuration: Debug Any CPU ------
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

However, if I build the project using the dotnet CLI command ( dotnet build ) it builds and runs just fine.

Apparently, .net core does not work properly when running Visual Studio as Admin. 显然,当以管理员身份运行Visual Studio时,.net core不能正常工作。 You would think everything should work as Admin, I guess not... go figure.

There are simply too many reasons why this type of thing might happen. The easiest way to diagnose the problem is to change the build output verbosity under options to verbose. This might help put you on the trail:

在此处输入图片说明

With regards to this type of thing happening with .Net Core and ASP Core. I have noticed that the project.json dependencies json fragment is a bit buggy especially if you start renaming projects and changing their file system location.

If you see in the diagnostic below you know there is some dangling reference issue:

Done building target "_GetDependencyFragmentFiles" in project "<<?YOUR_CORE_PROJECT?>>.xproj" -- FAILED

May be you are not seeing build errors. Go to Error List window and change 'Show Issues generated' box from ' Build + Intellisense ' to ' Build Only ' and try to build again.

在此处输入图片说明

See if this helps.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM