I have version 01.00.00 in the new code tab but it does not update. Currently the version of our project is 01.01.00 but in new code we still see “Since 01.00.00”. We have tried to pass the parameter sonar.projectversion=01.01.00 but in the new code tab it still shows “Since 01.00.00”
How can I solve it?
I use SonarQube 9
Welcome to the community!
What you’re seeing in the tab header is the New Code definition. I.e. it’s the description of what shows up on that tab. In your case, it’s showing all the code that was added/modified “Since 01.00.00”. Stated differently, what shows up on this tab are results for code changes made after the 01.00.00, or the code in your 01.01.00 version.
Does that make sense? Does it help?
Thanks for answering and for the welcome.
The problem we have is that we can’t get the issues of the current version to appear in the ‘New Code’ tab of the projects. For example, if the latest versions of our application are these
Being the current version 01.02.00, in the ‘New Code’ tab ‘Since 01.00.00’ appears, and therefore old issues are shown, making it very difficult to differentiate between the issues of the current version.
Can you share the content of the project activity tab?
On this tab, you’ll be able to find out when version changes are detected and when the new code period started.
Yes, In the activity tab I have a day that shows “New Code Period starts here” with version 01.00.00. But how can I do so that when there is a version change (for example 01.10.00 and then 01.20.00) the “new code start” is changed and starts at that version (01.10.00)?
The new code period is automatically re-calculated as soon as the version provided by the analyzer is changed.
I’ve run a small test on my side and attached the activity page result snapshot.
We can see that the new code period has been recalculated as soon as a new version has been reported.
I’d need more information from you in order to support you:
- What is your SonarQube version (you can check this out in the SonarQube footer)
- What is your SonarQube edition (you can check this out in the SonarQube footer)
- A snapshot of the project activity page (similar to the one I provided)
- The new code definition of the branch you’re encountering this issue
Thank you. It is fixed. The problem was that the version from jenkins to sonar was not being passed correctly.
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.