我有一個TFS在線項目。當我試圖構建該項目時,出現以下錯誤:無法從程序集中加載「Microsoft.CodeAnalysis.BuildTasks.Csc」任務
Severity Code Description Project File Line Error The "Microsoft.CodeAnalysis.BuildTasks.Csc" task could not be loaded from the assembly C:\Users\Bryan\Source\Workspaces\TestProject\ContosoUniversity\packages\Microsoft.Net.Compilers.1.0.0\build..\tools\Microsoft.Build.Tasks.CodeAnalysis.dll. Could not load file or assembly 'file:///C:\Users\Bryan\Source\Workspaces\TestProject\ContosoUniversity\packages\Microsoft.Net.Compilers.1.0.0\tools\Microsoft.Build.Tasks.CodeAnalysis.dll' or one of its dependencies. Could not find the file. Confirm that the declaration is correct, that the assembly and all its dependencies are available, and that the task contains a public class that implements Microsoft.Build.Framework.ITask. ContosoUniversity
這個事情與Azure不兼容不支持ASP.NET 4.6嗎?
你使用託管生成服務器生成項目?您是否嘗試在本地機器上構建項目?你能在本地獲得成功的構建嗎?根據https://www.visualstudio.com/en-us/get-started/build/hosted-agent-pool網站上的「託管構建服務器上的軟件」,託管構建服務器使用.NET 4.6框架進行部署。 –