1
votes

I have my custom continous build that log an error for my tfs service host.

Service 'Default Agent - basv-tfs-001' had an exception: Exception Message: Problem with loading custom assemblies: API restriction: The assembly 'file:///C:\Windows\ServiceProfiles\NetworkService\AppData\Local\ProjectBranchDevelopment\BuildAgent\2\ReportViewer.ProcessingObjectModel\Microsoft.ReportViewer.ProcessingObjectModel.dll' has already loaded from a different location. It cannot be loaded from a new location within the same appdomain. (type Exception)

I have found i have the same dll saved in 2 locations in my repository. can i hide it from build?

2

2 Answers

2
votes

Edit the workspace in your build definition. Add a reference to the folder containing one of the dll's and change "active" to "cloaked" that will stop TFS getting that folder during the build

0
votes

I've seen this in tests where it's defaulted to using **test.dll (or similar), to get round this I changed it to just test.dll, since it was (as the error suggests) finding it in multiple locations.

So whatever is attempting to resolve your DLL is probably doing something similar. Not a solution I know by may help you track down the offending code :)