Sonarcloud Loop Error then Timeout

Hi team,

We were trying to add sonarcloud analysis in one of our pipelines in azure devops with the code hosted also in azure devops when we notice the analysis step was timing out the whole pipeline due to an error that was looping (until the timeout eventually happened). Because the pipeline never finishes the analysis step, the result nevers shows in sonarcloud.

Can you help us identify what’s wrong?
Thanks!

The following is a sample taken from one of our runs of the error that occurs

2023-01-06T16:11:34.8593556Z 16:11:34.859 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFindAs .
2023-01-06T16:11:34.9783332Z 16:11:34.978 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFindAs .
2023-01-06T16:11:35.0947376Z 16:11:35.094 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFindAs .
2023-01-06T16:11:35.8639033Z 16:11:35.863 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFindAs .
2023-01-06T16:11:39.0217817Z 16:11:39.021 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFind .
2023-01-06T16:11:39.0531955Z 16:11:39.052 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFind .
2023-01-06T16:11:39.8325910Z 16:11:39.830 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFindAs .
2023-01-06T16:11:39.9447930Z 16:11:39.944 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFindAs .
2023-01-06T16:11:40.0602830Z 16:11:40.060 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFindAs .
2023-01-06T16:11:40.8054437Z 16:11:40.804 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFindAs .
2023-01-06T16:11:42.6951904Z 16:11:42.694 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFind .
2023-01-06T16:11:42.7280091Z 16:11:42.727 DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M with argFind .

Hi,

Can you provide the last few log lines before it falls into this loop?

 
Ann

Hi Ann,

I’m not sure what you’re looking for, so attach the whole analysis log.

Regards
SonarAnalysis.zip (734.4 KB)

Hi,

Thanks for the log. I’m going to flag this for more expert attention.

 
Ann

Thanks a lot!

Just replying to check if there’s any update on this issue.

Thanks!

A post was split to a new topic: Heap space error during analysis

Hello folks,

Do we have an update on this one? As you can see, more people are facing the same issue.

Thanks!

Hey folks,

thank you very much for your reports! :slight_smile:

Though the two problems described in this thread may appear to be related at first sight because of the messages that look like

DEBUG: Did not expect to visit symbol class com.sonar.security.E.D.B.M.

…I believe that this message is in fact not connected to either problem: This message is just an internal warning of minor relevance.

Given that the context of these two problems is very different (JS vs. C#, SonarCloud vs. SonarQube), I believe the two problems in this thread to be unrelated.

Therefore:

@MichaelK Could you please split off your post into a separate thread so that we can keep the two topics separate? :pray: I am certain @ganncamp will be happy to help with that and we will be happy to help you in the other thread. :slight_smile:

@FNunes To help me investigate this problem further, could you please zip and send me the contents of the directory /home/vsts/work/1/s/.scannerwork?

1 Like

Hi,

I was away for a few this and was not able to respond on this thread earlier.

Regarding your request for additional information, we’re using a microsoft hosted agent running on aure devops and we cannot remotely access those machines. Additionally, we run a bash ls command during the run and got the following result:

ls: cannot access ‘/home/vsts/work/1/s/.scannerwork’: No such file or directory

Additionally, we have a lot of other pipelines running on those linux hosted agents without a problem.

Let me know what other information you might require.

Thank you.

Hey Filipe,

thank you for your feedback! :slight_smile:

Can you clarify what those other pipelines do? Are they also running a SonarCloud scan on the same codebase?

In the analysis log that you provided, you can see that there are a lot of lines that mention this directory, such as

Reading UCFGs from: /home/vsts/work/1/s/.scannerwork/ucfg2/js

In order to investigate your problem, I would need to have a look the contents of this .scannerwork directory. Since, when running the ls command you mentioned above, that directory did not exist, could it be possible that you executed it on another machine? Or maybe your pipeline creates different subdirectories under /home/vsts/work in different runs of your pipeline? In that case, the .scannerwork directory might have been in a different subdirectory in the second run.

Cheers,
Malte

1 Like

Ok Malte. I understand. This might take us a bit of time. I’m going to speak to the team and see if we can setup a self-owned agent in a machine wer can remote to. I suspect the folder you need the contents is a temporary folder that’s only created when the analysis is running. That could explain the result of the ls command.

It might take a few days for my to post another reply here.