Last analysis failed Analysis ID "20f8cba8-ab75-44a9-80f6-f242bda6ec0b"

The last analysis is failing on a repo when the repo is transition from an old org to new org,

Hi,

Can you expand on what you mean by

You’ve moved the code repo from e.g. GitHub to GitLab and now the analysis is failing?

And are you using automatic analysis and it’s failing there? Or is the failure in the background task processing?

And finally, can you provide the approximate date/timestamp of this failure? Having it will make this easier to spot in our logs.

 
Thx,
Ann

We just enabled SSO for github organization (created a new SSO enabled organization and moved the repo from old organization to new SSO enabled organization),

Created new projects in new SSO enabled organization and its not analysis.
Also , I see this error when I click the Main branch of the project :

“prod” branch has not been analyzed yet and you have multiple branches already. It looks like it is not your Main Branch, check your configuration.

Can you please suggest what is missing ? Thanks

Hi,

So to be clear, you moved the repo in GitHub. Did you re-bind it in SonarQube Cloud?

And again,

 
Thx,
Ann

So to be clear, you moved the repo in GitHub. Did you re-bind it in SonarQube Cloud?

(yes)

And are you using automatic analysis and it’s failing there? Or is the failure in the background task processing?

(Automatic Analysis and it failed).,I see that background task processing passed this morning.
When I open the project - overview , it still shows that last analysis branch failure message so I am not sure .. Also what does following mean (how can I change the main branch to Prod branch)
“prod” branch has not been analyzed yet and you have multiple branches already. It looks like it is not your Main Branch, check your configuration.

And finally, can you provide the approximate date/timestamp of this failure? Having it will make this easier to spot in our logs.
(I had tried to look for that, but when I click for details, it just points me to go to community forum and provide details (not able to find how do I find the date/timestamp as I explored all the tabs/links under Project

Hi,

We try to keep it to one topic per thread. Otherwise it can get messy, fast. Let’s focus here on the automatic analysis failure.

I’ve flagged this for the folks with log access.

 
Ann

Sure, Thanks ! Just right now, it tried to perform automatic analysis as I was writing you :
Analysis ID “AZgZRoxiWsQwgM_1nWhh” and it failed again.
So July 17th 9:30 AM - 9:55 PM PST logs can be checked if that is helpful,.

1 Like

Hi Ann
Any suggestion ?
How can I resolve this; (where do I check the configuration) –
“prod” branch has not been analyzed yet and you have multiple branches already. It looks like it is not your Main Branch, check your configuration.

Hi,

This is flagged for the experts (and I’m nudging privately as well). Hopefully they’ll be along soon.

 
Ann

Hi @nshukla-spbike,

Apologies for the late reply. Thanks for providing all of this information!

We’ve dug into the logs and found the analysis is failing due to insufficient memory. Could you please update your settings with an increased Node.js heap size? The analysis is failing because the current limit (4144 MB) is not enough for the JS/TS files. Per our documentation, big projects need more memory may need to be allocated.

You can set a higher value for sonar.javascript.node.maxspace.
For example, -Dsonar.javascript.node.maxspace=8192.

Thanks!
Miguel

Hi @miguel.ramirez
Thanks for your response. I will try to set the property in the project settings configuration, and then update here.
I am setting up this property in the sonar-project.properties file. we do not have any such file yet , but would create a new one to set this property

DO you have any advise on how to resolve this error:
“prod” branch has not been analyzed yet and you have multiple branches already. It looks like it is not your Main Branch, check your configuration.

Hi,

For automatic analysis, it’s not a sonar-project.properties file you need, but a .sonarcloud.properties file.

Regarding the other error, we try to keep it to one topic per thread. Otherwise it can get messy, fast. So if you’d like to pursue that, please create a new thread.

 
Thx,
Ann

Do I have to create this file .sonarcloud.properties and put in root of the project or its automatically generated by settings Project Configuration

Hi,

You’ll need to create it manually. Sorry, I should have included the docs link to start with.

 
Ann

Thanks, I am checking, but why do I see “Last Analysis Method”
as Analyzed by an unknown method in Analysis method indicator

Hi,

I’m not sure what you’re referencing. Could you share a screenshot?

 
Thx,
Ann

attached.

Hi,

I’m not sure why you’re seeing that. But is analysis succeeding with the increased memory limit?

 
Ann

No. not yet

Hi,

Then it’s probably time to turn off automatic analysis (Administration → Analysis Method) and set this up to run in your own CI system. If you don’t have one, you should look at GitHub Actions.

 
HTH,
Ann