We are getting exception “System.IO.PathTooLongException” in Run Code Analysis task. This step is working fine for couple of branches and throwing error in other branches. From the build server, we can see that maximum length of the file name is 254.
Below are the details. Please let me know for further details.
ALM : Azure DevOps
CI : Azure DevOps
Scanner Task : Run Code Analysis
Languages of the repository : .NET
Error observed : ##[error]System.IO.PathTooLongException: The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less than 248 characters.
Steps to reproduce :
Prepare analysis on SonarCloud
Use NuGet 4.4.1
Run Code Analysis