- Sonar scanner MSBuild
- Azure DevOps
- Yaml pipelines
##[error]One or more errors occurred. (One or more errors occurred. (Access to the path 'C:\agent-a\_work\24\.sonarqube\bin\SonarScanner.MSBuild.Common.dll' is denied.)) (Access to the path 'C:\agent-a\_work\24\.sonarqube\bin\SonarScanner.MSBuild.Common.dll' is denied.)
The first build works, the second build fails with the error shown above.
In case of a follow-up, failing, build it is always a build that runs in the same working directory (e.g. _work\24\ in the error above).
It looks like the build is keeping a lock on the DLL file, even after it’s done. After a while, it seems to work again, but I haven’t figured out the time interval yet.
Before today I haven’t seen this issue and it’s also only occurring on 1 of our 28 projects. It could be related to the amount of builds this particular team runs close after each other.