CSC error CS0006: Metadata file 'SonarAnalyzer.dll' could not be found

半城伤御伤魂 提交于 2019-12-10 11:56:39

问题


I'm having random problems during my build process in TeamCity. I've got two configurations: First for Rebuild + Unit test. Second as artifact dependency, with SonarQube analyzer. When Teamcity is executing first configuration, I'm receiving random error messages every 5-10 builds:

CSC error CS0006: Metadata file 'E:\TeamCity\buildAgent2\temp\buildTmp\.sonarqube\resources\0\Google.Protobuf.dll' could not be found

CSC error CS0006: Metadata file 'E:\TeamCity\buildAgent2\temp\buildTmp\.sonarqube\resources\0\SonarAnalyzer.CSharp.dll' could not be found

CSC error CS0006: Metadata file 'E:\TeamCity\buildAgent2\temp\buildTmp\.sonarqube\resources\0\SonarAnalyzer.dll' could not be found

Errors are totally random - when I run process one more time without any changes, error is gone. When I check buildTmp\.sonarqube directory, there is nothing there, no matter if build was successful or not.

I don't have any references in my project to those libraries and my Rebuild step has nothing to do with SonarQube. We are using SonarLint in VisualStudio 2017, but once again, we don't have any references to SonarQube in our *.csproj files.

来源:https://stackoverflow.com/questions/50696699/csc-error-cs0006-metadata-file-sonaranalyzer-dll-could-not-be-found

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!