# Sonar shows code issues on first scan but after second scan it shows passed(SonarQube EE LTS 9.9)

**URL:** <https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546>\
**Category:** SonarQube Server / Community Build\
**Tags:** sonarqube, scanner\
**Created:** [April 20, 2023, 8:39am UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546 "2023-04-20T08:39:54Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 20, 2023, 8:39am UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/1 "2023-04-20T08:39:54Z")

</div>

- **SonarQube 9.9 LTS EE** \*
- **how is SonarQube deployed: Docker**
- **Scanning feature branch**
- 

Hi Team,

We have SonarQube EE 9.9 LTS and we are using project specific setting for a project like this and our Glbal new code setting is set to Previous Version.

 ![Screenshot 2023-04-20 at 10.41.10](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/9/a/9a475a98cdc0491465399ac9d3df9aac7e75ca8f.png)

We use **Reference branch** at project level settings. The problem is when we scan our buggy sonar feature branch on first scan it shows issues/bugs etc and everything works that is fine, But when we run the same branch without any changes again it shows passed/success which is not correct, Can you please help us. is there any settings we are missing ?

Quality Gate Setting are like this

 ![Screenshot 2023-04-20 at 11.05.47](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/5/f/5fa7a2b08c625b710b1b3e1d1be640ac1d5bf94f.png)

@ganncamp @Colin Can you please have a look?

Br,  
Dashrath

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 23, 2023, 7:47am UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/3 "2023-04-23T07:47:05Z")

</div>

The analysis activity of our feature branch like this

![Screenshot 2023-04-23 at 09.43.37](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/3/7/37dcb5d8e8550b573047fb8877e04329560518e9.png)

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 24, 2023, 11:12am UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/4 "2023-04-24T11:12:11Z")

</div>

**Scenario:**

1. Run buggy feature branch with reference branch setting at project level shows issues/bugs(expected behaviour)
2. Do not add any code and rerun the feature branch do not show any code issues.
3. Add one more bug to feature branch and it shows all the bugs/issues.
4. rerun the feature branch and it shows passed/success.

Why the sonar result is not stable when feature branch is buggy?

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 24, 2023, 2:31pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/5 "2023-04-24T14:31:09Z")

</div>

Hi,

Per [the FAQ](https://community.sonarsource.com/faq#sla), please don’t invoke (`@`) people not already involved in your thread. It doesn’t move you up people’s priority lists; just the opposite.

Regarding your question. Can you provide the analysis logs for an analysis where issues were found and one where they were not?

The analysis / scanner log is what’s output from the analysis command. Hopefully, the log you provide - redacted as necessary - will include that command as well.

[This guide](https://community.sonarsource.com/t/how-to-find-logs-about-importing-code-coverage/73317) will help you find them.

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 24, 2023, 4:09pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/6 "2023-04-24T16:09:57Z")

</div>

Hi,

Sorry about that, I have attached debug logs from the build. Please find the attachment.

[1.Logs-for-build\_WITH-ISSUES:BUGS.txt](https://community.sonarsource.com/uploads/short-url/cXTxB4k8ODvyR4uQCPci4V3Hx7n.txt) (1.9 MB)  
[2.rerun-build-PASSED.txt](https://community.sonarsource.com/uploads/short-url/hE2tzYKMlDT9hEXWyTrTruqQ20l.txt) (1.9 MB)

Project homepage

 ![Screenshot 2023-04-24 at 18.26.47](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/c/8/c8de240996069191d0d7a5fc0e5d438edc5d48bf.png)

Br,  
Dashrath

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 24, 2023, 5:30pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/7 "2023-04-24T17:30:26Z")

</div>

Hi Dashrath,

I didn’t see anything noteworthy in your logs. Are both of these analyses running on the same build agent?

Per the (recently updated) docs, [for Reference Branch](https://docs.sonarqube.org/latest/project-administration/defining-new-code/#how-the-new-code-definition-affects-your-analysis-results):

> Any differences between your branch and the reference branch in the clone the scanner has access to at analysis time are considered new code.

So is the same `main` branch clone available to both analyses?

Also, do your Overall metrics change from one analysis to another?

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 24, 2023, 5:44pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/8 "2023-04-24T17:44:10Z")

</div>

Hi Ann,

Yes, both build are running on same agent/docker container. Yes origin/master is available for both analysis. The noteworthy difference I see is that my reference branch overall code has some difference eg **Code smells and Coverage** compared to origin/master.

**Master branch Overall Code:**

 ![Screenshot 2023-04-24 at 19.40.00](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/8/a/8af0992452ad177d36576c0eed2f3fa21acd52e2.png)

**Feature branch Overall Code:**  
\*\*

 ![Screenshot 2023-04-24 at 19.43.4**2](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/a/7/a7009bbf192d3b5e130dfdd8fc495d571075ad84.png)

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 24, 2023, 5:49pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/9 "2023-04-24T17:49:40Z")

</div>

Hi,

I’m confused. Your two Overall Code screenshots show different branches.

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 24, 2023, 5:51pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/10 "2023-04-24T17:51:38Z")

</div>

Hi Ann,

Yes, because **origin/master** is my reference branch or main branch which get’s compared against the feature branch which is mundkda/ITADS-23220/test-sonar-cost-tariff-new I am using this because of project level setting like this.

 ![Screenshot 2023-04-24 at 19.53.04](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/6/d/6da423b4d5a6746fd1880d69dbbc74e6d7f8de42.png)

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 24, 2023, 5:59pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/11 "2023-04-24T17:59:53Z")

</div>

Hi,

When you use your main branch as the reference branch, what will be reported as New Code in the other branch is what has changed in the other branch. Thus, it’s not necessarily useful to compare overall values between your branch and main. You’re complaining that from one branch analysis to the next, issues disappear and reappear. So I wanted to see two screenshots of the branch - a “disappear” one and a “reappear” one.

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 24, 2023, 6:22pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/12 "2023-04-24T18:22:57Z")

</div>

Hi Ann, I have just tested and here are the results

**Buggy Feature branch first Scan result:**

 ![Screenshot 2023-04-24 at 20.12.27](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/f/4/f415bc35f8cc137c81ea3f28b70d0765154ba6f5.png)

**Second scan without change Scan Result:**

 ![Screenshot 2023-04-24 at 20.22.31](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/3/5/35678dbdef56c77fe92acef0fb146ebf71f9d68d.png)

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 24, 2023, 6:28pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/13 "2023-04-24T18:28:53Z")

</div>

Hi,

Both of those analyses were on the same build agent?

Can you go to the branch’s Activity tab and screenshot a graph of just Code Smells (overall)? E.G.:

 ![Selection_1024](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/7/d/7d267755fa0fd6644911320c4ae5e715ecb0f36a.png)

Can you provide the analysis logs of those two analyses?

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 24, 2023, 6:33pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/14 "2023-04-24T18:33:02Z")

</div>

Hi Ann,  
Yes, both analyses were on the same build agent/docker container one after the another.

 ![Screenshot 2023-04-24 at 20.30.52](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/5/9/59899ee287771f8a2b6e34df6021dce350e53c9f.png)  
 ![Screenshot 2023-04-24 at 20.32.04](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/c/b/cb6488baeac5ad873d5207653d383cab5a6839a5.png)

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 24, 2023, 6:35pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/15 "2023-04-24T18:35:03Z")

</div>

Hi,

I’m looking for a graph of Overall Code Smells.

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 24, 2023, 6:35pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/16 "2023-04-24T18:35:18Z")

</div>

here is it

 ![Screenshot 2023-04-24 at 20.34.53](https://europe1.discourse-cdn.com/sonarsource/uploads/sonarcommunity/original/3X/a/8/a8b678a98515c36818315e3e70292a7ab227b1b8.png)

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 24, 2023, 6:42pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/17 "2023-04-24T18:42:58Z")

</div>

Hi,

The overall number of Code Smells remains steady as far as I can tell, so this is a question of what’s detected as new code. Can I have the entire job log (from checkout) for the second run?

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 24, 2023, 6:55pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/18 "2023-04-24T18:55:51Z")

</div>

Hi Ann,  
Here is the second run log I have kept all the necessary things for you regarding sonar stage but removed some unnecessary stage which has some data that I cannot display.

[Entire log.txt](https://community.sonarsource.com/uploads/short-url/2EHsqrR9a6SQDG9oLm9rTtH3qjB.txt) (6.6 MB)

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 25, 2023, 1:58pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/19 "2023-04-25T13:58:04Z")

</div>

Hi,

I think I’ve found the problem:

> Using shallow clone with depth 1

Since you seem to be using GitLab, I’ll quote [those docs](https://docs.sonarqube.org/latest/devops-platform-integration/gitlab-integration/)

> You need to disable git shallow clone to make sure the scanner has access to all of your history when running analysis with GitLab CI/CD. For more information, see [**Git shallow clone**](https://docs.gitlab.com/ee/ci/large_repositories/).

The shallow clone means the information isn’t available to analysis to properly detect new code.

&nbsp;  
HTH,  
Ann

---

<div class="post-metadata">

**Author:** ![DASHRATH\_MUNDKAR](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/dashrath_mundkar/32/44317_2.png) [@DASHRATH\_MUNDKAR](https://community.sonarsource.com/u/DASHRATH_MUNDKAR)\
**Post date:** [April 25, 2023, 3:16pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/20 "2023-04-25T15:16:23Z")

</div>

Hi Ann,

I disabled the shallow clone and issue is still there. Indeed we use the GitLab for source code and then we clone that source code in Jenkins to mvn build and sonar Analysis.

I also checked the sonarQube server logs to check if I find anything but it looks fine to me  
**First buggy analysis log from sonarQube server which Failed:**

```auto
2023.04.25 15:00:52 INFO ce[][o.s.c.t.CeWorkerImpl] Execute task | project=com.hlag.fis.costtariff:CostTariff | type=REPORT | branch=mundkda/ITADS-23220/test-sonar-cost-tariff-new | branchType=BRANCH | id=AYe47oLW1-wMjco5ZUtk | submitter=mundkda
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Extract report | status=SUCCESS | time=834ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist scanner context | status=SUCCESS | time=6ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Propagate analysis warnings from scanner report | status=SUCCESS | time=0ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Generate analysis UUID | status=SUCCESS | time=0ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Load analysis metadata | status=SUCCESS | time=1ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Initialize | status=SUCCESS | time=2ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Build tree of components | components=1961 | status=SUCCESS | time=60ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Validate project | status=SUCCESS | time=3ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Load quality profiles | status=SUCCESS | time=449ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Load file hashes and statuses | status=SUCCESS | time=1ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Load Quality gate | status=SUCCESS | time=1ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Load new code period | status=SUCCESS | time=1ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Detect file moves | status=SUCCESS | time=0ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Detect file moves in Pull Request scope | status=SUCCESS | time=0ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Load duplications | duplications=157 | status=SUCCESS | time=29ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute cross project duplications | status=SUCCESS | time=0ms
2023.04.25 15:00:53 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute size measures | status=SUCCESS | time=59ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute new coverage | status=SUCCESS | time=1167ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute coverage measures | status=SUCCESS | time=56ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute comment measures | status=SUCCESS | time=4ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute duplication measures | status=SUCCESS | time=4ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute size measures on new code | status=SUCCESS | time=794ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute language distribution | status=SUCCESS | time=2ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute test measures | status=SUCCESS | time=2ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute complexity measures | status=SUCCESS | time=4ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Load measure computers | status=SUCCESS | time=0ms
2023.04.25 15:00:55 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute Quality Profile status | status=SUCCESS | time=1ms
2023.04.25 15:00:56 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Execute component visitors | status=SUCCESS | time=804ms
2023.04.25 15:00:56 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Checks executed after computation of measures | status=SUCCESS | time=3ms
2023.04.25 15:00:56 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute Quality Gate measures | status=SUCCESS | time=1ms
2023.04.25 15:00:56 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Compute Quality profile measures | status=SUCCESS | time=1ms
2023.04.25 15:00:56 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Generate Quality profile events | status=SUCCESS | time=1ms
2023.04.25 15:00:56 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Generate Quality gate events | status=SUCCESS | time=2ms
2023.04.25 15:00:56 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Check upgrade possibility for not analyzed code files. | status=SUCCESS | time=0ms
2023.04.25 15:00:56 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist scanner analysis cache | status=SUCCESS | time=223ms
2023.04.25 15:00:57 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist components | status=SUCCESS | time=472ms
2023.04.25 15:00:57 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist analysis | status=SUCCESS | time=4ms
2023.04.25 15:00:57 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist analysis properties | status=SUCCESS | time=4ms
2023.04.25 15:00:57 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist measures | inserts=70 | status=SUCCESS | time=6ms
2023.04.25 15:01:06 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist live measures | insertsOrUpdates=72803 | status=SUCCESS | time=8727ms
2023.04.25 15:01:06 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist duplication data | insertsOrUpdates=101 | status=SUCCESS | time=23ms
2023.04.25 15:01:06 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist new ad hoc Rules | status=SUCCESS | time=0ms
2023.04.25 15:01:06 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist issues | cacheSize=335.3 kB | inserts=500 | updates=0 | merged=0 | status=SUCCESS | time=111ms
2023.04.25 15:01:06 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Delete issue changes | changes=0 | status=SUCCESS | time=0ms
2023.04.25 15:01:06 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist project links | status=SUCCESS | time=0ms
2023.04.25 15:01:06 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist events | status=SUCCESS | time=5ms
2023.04.25 15:01:10 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist sources | status=SUCCESS | time=4658ms
2023.04.25 15:01:10 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Persist cross project duplications | status=SUCCESS | time=0ms
2023.04.25 15:01:10 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Enable analysis | status=SUCCESS | time=2ms
2023.04.25 15:01:10 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Update last usage date of quality profiles | status=SUCCESS | time=5ms
2023.04.25 15:01:10 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Purge db | status=SUCCESS | time=20ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Index analysis | status=SUCCESS | time=297ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Update need issue sync for branch | status=SUCCESS | time=2ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Publishing taint vulnerabilities events | status=SUCCESS | time=5ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Send issue notifications | newIssuesNotifs=0 | newIssuesDeliveries=0 | myNewIssuesNotifs=0 | myNewIssuesDeliveries=0 | changesNotifs=0 | changesDeliveries=0 | status=SUCCESS | time=3ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Publish task results | status=SUCCESS | time=0ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.s.ComputationStepExecutor] Trigger refresh of Portfolios and Applications | refreshesAPP=0 | refreshesVW=0 | status=SUCCESS | time=11ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Webhooks | globalWebhooks=5 | projectWebhooks=0 | status=SUCCESS | time=83ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Pull Request decoration | status=SUCCESS | time=0ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Report branch Quality Gate status to devops platforms | status=SUCCESS | time=1ms
2023.04.25 15:01:11 INFO ce[AYe47oLW1-wMjco5ZUtk][o.s.c.t.CeWorkerImpl] Executed task | project=com.hlag.fis.costtariff:CostTariff | type=REPORT | branch=mundkda/ITADS-23220/test-sonar-cost-tariff-new | branchType=BRANCH | id=AYe47oLW1-wMjco5ZUtk | submitter=mundkda | status=SUCCESS | time=19541ms

```

**Second rerun analysis log from sonarQube server which passed:**

```auto
2023.04.25 15:12:06 INFO ce[][o.s.c.t.CeWorkerImpl] Execute task | project=com.hlag.fis.costtariff:CostTariff | type=REPORT | branch=mundkda/ITADS-23220/test-sonar-cost-tariff-new | branchType=BRANCH | id=AYe4-MdH1-wMjco5ZUtq | submitter=mundkda
2023.04.25 15:12:07 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Extract report | status=SUCCESS | time=845ms
2023.04.25 15:12:07 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist scanner context | status=SUCCESS | time=2ms
2023.04.25 15:12:07 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Propagate analysis warnings from scanner report | status=SUCCESS | time=0ms
2023.04.25 15:12:07 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Generate analysis UUID | status=SUCCESS | time=0ms
2023.04.25 15:12:07 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Load analysis metadata | status=SUCCESS | time=2ms
2023.04.25 15:12:07 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Initialize | status=SUCCESS | time=6ms
2023.04.25 15:12:07 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Build tree of components | components=1961 | status=SUCCESS | time=67ms
2023.04.25 15:12:07 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Validate project | status=SUCCESS | time=3ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Load quality profiles | status=SUCCESS | time=442ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Load file hashes and statuses | status=SUCCESS | time=160ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Load Quality gate | status=SUCCESS | time=2ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Load new code period | status=SUCCESS | time=0ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Detect file moves | reportFiles=1516 | dbFiles=1516 | addedFiles=0 | status=SUCCESS | time=25ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Detect file moves in Pull Request scope | status=SUCCESS | time=0ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Load duplications | duplications=157 | status=SUCCESS | time=30ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute cross project duplications | status=SUCCESS | time=0ms
2023.04.25 15:12:08 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute size measures | status=SUCCESS | time=53ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute new coverage | status=SUCCESS | time=573ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute coverage measures | status=SUCCESS | time=86ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute comment measures | status=SUCCESS | time=4ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute duplication measures | status=SUCCESS | time=3ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute size measures on new code | status=SUCCESS | time=382ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute language distribution | status=SUCCESS | time=2ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute test measures | status=SUCCESS | time=3ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute complexity measures | status=SUCCESS | time=5ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Load measure computers | status=SUCCESS | time=0ms
2023.04.25 15:12:09 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute Quality Profile status | status=SUCCESS | time=2ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Execute component visitors | status=SUCCESS | time=1846ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Checks executed after computation of measures | status=SUCCESS | time=2ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute Quality Gate measures | status=SUCCESS | time=0ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Compute Quality profile measures | status=SUCCESS | time=1ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Generate Quality profile events | status=SUCCESS | time=1ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Generate Quality gate events | status=SUCCESS | time=3ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Check upgrade possibility for not analyzed code files. | status=SUCCESS | time=0ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist scanner analysis cache | status=SUCCESS | time=345ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist components | status=SUCCESS | time=21ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist analysis | status=SUCCESS | time=2ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist analysis properties | status=SUCCESS | time=2ms
2023.04.25 15:12:11 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist measures | inserts=70 | status=SUCCESS | time=8ms
2023.04.25 15:12:17 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist live measures | insertsOrUpdates=72766 | status=SUCCESS | time=6186ms
2023.04.25 15:12:17 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist duplication data | insertsOrUpdates=101 | status=SUCCESS | time=22ms
2023.04.25 15:12:17 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist new ad hoc Rules | status=SUCCESS | time=0ms
2023.04.25 15:12:17 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist issues | cacheSize=43.9 kB | inserts=0 | updates=86 | merged=0 | status=SUCCESS | time=10ms
2023.04.25 15:12:17 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Delete issue changes | changes=0 | status=SUCCESS | time=0ms
2023.04.25 15:12:17 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist project links | status=SUCCESS | time=0ms
2023.04.25 15:12:17 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist events | status=SUCCESS | time=3ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist sources | status=SUCCESS | time=1856ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Persist cross project duplications | status=SUCCESS | time=0ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Enable analysis | status=SUCCESS | time=4ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Update last usage date of quality profiles | status=SUCCESS | time=2ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Purge db | status=SUCCESS | time=17ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Index analysis | status=SUCCESS | time=117ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Update need issue sync for branch | status=SUCCESS | time=2ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Publishing taint vulnerabilities events | status=SUCCESS | time=1ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Send issue notifications | newIssuesNotifs=0 | newIssuesDeliveries=0 | myNewIssuesNotifs=0 | myNewIssuesDeliveries=0 | changesNotifs=0 | changesDeliveries=0 | status=SUCCESS | time=1ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Publish task results | status=SUCCESS | time=0ms
2023.04.25 15:12:19 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.s.ComputationStepExecutor] Trigger refresh of Portfolios and Applications | refreshesAPP=0 | refreshesVW=0 | status=SUCCESS | time=3ms
2023.04.25 15:12:20 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Webhooks | globalWebhooks=5 | projectWebhooks=0 | status=SUCCESS | time=72ms
2023.04.25 15:12:20 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Pull Request decoration | status=SUCCESS | time=0ms
2023.04.25 15:12:20 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.p.a.p.PostProjectAnalysisTasksExecutor] Report branch Quality Gate status to devops platforms | status=SUCCESS | time=1ms
2023.04.25 15:12:20 INFO ce[AYe4-MdH1-wMjco5ZUtq][o.s.c.t.CeWorkerImpl] Executed task | project=com.hlag.fis.costtariff:CostTariff | type=REPORT | branch=mundkda/ITADS-23220/test-sonar-cost-tariff-new | branchType=BRANCH | id=AYe4-MdH1-wMjco5ZUtq | submitter=mundkda | status=SUCCESS | time=13631ms

```

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [April 25, 2023, 4:57pm UTC](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546/21 "2023-04-25T16:57:06Z")

</div>

Hi,

The `ce.log` contents aren’t really relevant here.

I’ve taken another look at your most recent log. I saw the shallow clone and didn’t look any further. I should have:

> `[INFO] 18:21:55.723 SCM Publisher is disabled`

You need to turn that back on.

&nbsp;  
Ann

[Next page](https://community.sonarsource.com/t/sonar-shows-code-issues-on-first-scan-but-after-second-scan-it-shows-passed-sonarqube-ee-lts-9-9/89546.md?page=2)
