[JAVA] common-java:DuplicatedBlocks false positives for Mojo classes (parameters of Maven goals)

139 views
Skip to first unread message

Adam Gabryś

unread,
Jul 30, 2016, 9:53:27 AM7/30/16
to SonarQube

Hello,
The Java Analyzer 4.0 generates a common-java:DuplicatedBlocks false positives for Mojo classes:

Block #1 (project css-splitter-maven-plugin):

Block #2 (project lesscss-maven-plugin):

I use different names for parameters. I know that comments are very similar, but I cannot (and don't want) create a parent class to inherit fields with documentations.

I also know that the detection of duplication is quite complex - so should I mark this as Won't Fix or there is a chance that the rule will stop to mark this type of code?

Environment:

  • SonarQube 5.6.1
  • Plugins:
    • CSS 2.0
    • Checkstyle 2.4
    • Findbugs 3.4.3
    • Git 1.2
    • Java 4.0
    • Java Properties 2.0
    • JavaScript 2.14
    • PHP 2.8
    • PMD 2.6
    • Web 2.4
    • Widget Lab 1.8.1
    • XML 1.4.1

My projects are build by Maven.
Links:

Regards,
Adam Gabryś

Nicolas Peru

unread,
Aug 15, 2016, 6:01:39 AM8/15/16
to Adam Gabryś, SonarQube
Hi Adam, 

Sorry to let you know that we don't really plan to fix such cases shortly. So you should mark those as FP. 

One question though : are those issues new after an update to java 4.0 (and/or SQ 5.6) or you happen to notice them after the upgrade ? 

Cheers, 

--
You received this message because you are subscribed to the Google Groups "SonarQube" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sonarqube+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sonarqube/BLU437-SMTP86BF8EA13768C045E1F63098020%40phx.gbl.
For more options, visit https://groups.google.com/d/optout.
--
Nicolas PERU | SonarSource
Senior Developer
http://sonarsource.com

Adam Gabryś

unread,
Dec 17, 2017, 8:10:01 AM12/17/17
to SonarQube
Hi Nicolas,
I would like to apologize for the very late reply. A few minutes I noticed that I did not reply to your question.

I don't remember when those issues appeared, but I can confirm that they continue to occur in the newest environment:
* SonarQube 6.7
* SonarJava 4.15.0.12310

Best Regards
Adam Gabryś
Reply all
Reply to author
Forward
0 new messages