Build error: Could not load file or assembly '...Microsoft.Build.Tasks.v4.0.dll'

From @Lux2057 on Mon Dec 05 2016 09:57:58 GMT-0500 (EST)

# Bitrise Build Issue Report template

Description of the issue

I got error with NuGet download. It seems that the service can’t download Microsoft.Build.Tasks.v4.0.dll. On local machine project works fine and Visual Studio creates package.


Where did the issue happen?

Xamarin Stable with Xcode 8.1, on macOS 10.12 (Sierra)

Which build Step causes the issue and which version of the step?



  • Does a “Rebuild” help? (You can trigger a rebuild from the Build’s page, by clicking the “Rebuild” button in the top right corner of a finished build) : NO
  • Does a rebuild without caches help? (You can remove the Cache:Pull and Cache:Push steps temporarily to not to use the cache, or you can delete all the caches on the Settings tab of the app. : NO
  • If it’s an issue which happens sporadically, what’s the frequency? (e.g. Once a day ; about x% of the builds) : every build
  • Does upgrading the build Step to the latest version help? : NO
  • When did the issue start? : at first app build

Build log

Copied from original issue:

From @godrei on Wed Dec 21 2016 05:05:29 GMT-0500 (EST)

Hi @Lux2057 ,
sorry for my late response, could you please try the solutions mentioned in this STO thread?

From @Lux2057 on Wed Dec 21 2016 08:44:18 GMT-0500 (EST)

Hi @godrei, thanks, it helped. I think we can close this issue.

From @godrei on Wed Dec 21 2016 09:13:12 GMT-0500 (EST)

@Lux2057 ,
could you please link which solution worked for you? It may help others with this issue…