Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Build fails: Could not load file or assembly Microsoft.CodeAnalysis
marhoily
#1 Posted : Thursday, October 1, 2015 8:26:53 AM(UTC)
Rank: Member

Groups: Registered
Joined: 9/2/2012(UTC)
Posts: 13

Thanks: 3 times
Was thanked: 1 time(s) in 1 post(s)
Hello! I submitted bug report with the same name as this topic a few seconds ago.

Do you have any workaround for it for now?

The output is:

..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): Unexpected exception:
..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.CodeAnalysis, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): File name: 'Microsoft.CodeAnalysis, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): at Microsoft.CodeAnalysis.BuildTasks.ManagedCompiler.GetArguments(String commandLineCommands, String responseFileCommands)
..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): at Microsoft.CodeAnalysis.BuildTasks.ManagedCompiler.ExecuteTool(String pathToTool, String responseFileCommands, String commandLineCommands)
..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): WRN: Assembly binding logging is turned OFF.
..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): Note: There is some performance penalty associated with assembly bind failure logging.
..\..\..\..\Program Files (x86)\MSBuild\14.0\bin\Microsoft.CSharp.Core.targets (67, 5): To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

Remco
#2 Posted : Thursday, October 1, 2015 10:47:36 AM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 7,144

Thanks: 959 times
Was thanked: 1290 time(s) in 1196 post(s)
Hi,

This is likely to be the same as this issue here: http://forum.ncrunch.net/yaf_postst1664_NCrunch-build-failure-after-adding-Microsoft-Net-Compilers-package.aspx.

Adding the relevant package to your additional files to include should resolve the issue.



Cheers,

Remco
1 user thanked Remco for this useful post.
marhoily on 10/1/2015(UTC)
marhoily
#3 Posted : Thursday, October 1, 2015 12:12:51 PM(UTC)
Rank: Member

Groups: Registered
Joined: 9/2/2012(UTC)
Posts: 13

Thanks: 3 times
Was thanked: 1 time(s) in 1 post(s)
Maybe it worth including as a suggestion to the output window of the ncrunch then? Because googling didn't helped me in this instance
Remco
#4 Posted : Thursday, October 1, 2015 8:10:39 PM(UTC)
Rank: NCrunch Developer

Groups: Administrators
Joined: 4/16/2011(UTC)
Posts: 7,144

Thanks: 959 times
Was thanked: 1290 time(s) in 1196 post(s)
Sorry. The actual solution for this is to have NCrunch automatically try to detect the Nuget dependency and include its files automatically. This is coming in the 2.17 release.

The previous line on this has been to allow people to include the files themselves, to prevent workspace bloat .. but for some reason the number of Nuget packages that use build targets has massively increased in the last two months, so an automated solution now seems like the best option.
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

YAF | YAF © 2003-2011, Yet Another Forum.NET
This page was generated in 0.036 seconds.
Trial NCrunch
Take NCrunch for a spin
Do your fingers a favour and supercharge your testing workflow
Free Download