GerritCodeReview / bazlets
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 7% duplication:
    • 1,998 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 143 duplicated lines
  • 55 duplicates
system7% (143 lines)
Duplication per Extension
bzl9% (143 lines)
Duplication per Component (primary)
tools7% (91 lines)
tools/js7% (13 lines)
ROOT5% (13 lines)
tools/maven9% (13 lines)
lib/prolog38% (13 lines)
lib/js0% (0 lines)
lib/js/externs0% (0 lines)
lib/prolog/java0% (0 lines)
tools/eclipse0% (0 lines)
tools/sonar0% (0 lines)

Duplication Between Components (50+ lines)

G tools tools tools/maven tools/maven tools--tools/maven 102 lib/prolog lib/prolog lib/prolog--tools 99 ROOT ROOT ROOT--tools 96 tools/js tools/js tools/js--tools 96

Download: SVG DOT (open online Graphviz editor)

Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 20 longest duplicates.
See data for all 55 duplicates...
Size#FoldersFilesLinesCode
13 x 2 lib/prolog
tools
prolog.bzl
py_binary_path.bzl
1:13 (38%)
1:13 (44%)
view
13 x 2 tools
tools/maven
junit.bzl
package.bzl
1:13 (18%)
1:13 (16%)
view
13 x 2 tools
tools
junit.bzl
maven_jar.bzl
1:13 (18%)
1:13 (8%)
view
13 x 2 tools
tools
genrule2.bzl
junit.bzl
1:13 (48%)
1:13 (18%)
view
13 x 2 tools
tools/maven
genrule2.bzl
package.bzl
1:13 (48%)
1:13 (16%)
view
13 x 2 tools
tools
javadoc.bzl
maven_jar.bzl
1:13 (18%)
1:13 (8%)
view
13 x 2 tools
tools
javadoc.bzl
junit.bzl
1:13 (18%)
1:13 (18%)
view
13 x 2 tools
tools
pkg_war.bzl
py_binary_path.bzl
1:13 (13%)
1:13 (44%)
view
13 x 2 tools
tools/maven
javadoc.bzl
package.bzl
1:13 (18%)
1:13 (16%)
view
13 x 2 tools
tools
genrule2.bzl
javadoc.bzl
1:13 (48%)
1:13 (18%)
view
13 x 2 tools
tools
genrule2.bzl
java.bzl
1:13 (48%)
1:13 (52%)
view
13 x 2 tools
tools
java.bzl
javadoc.bzl
1:13 (52%)
1:13 (18%)
view
13 x 2 tools/maven
tools
package.bzl
maven_jar.bzl
1:13 (16%)
1:13 (8%)
view
13 x 2 tools
tools
java.bzl
junit.bzl
1:13 (52%)
1:13 (18%)
view
13 x 2 lib/prolog
tools
prolog.bzl
pkg_war.bzl
1:13 (38%)
1:13 (13%)
view
13 x 2 tools
tools
genrule2.bzl
maven_jar.bzl
1:13 (48%)
1:13 (8%)
view
13 x 2 tools
tools
java.bzl
maven_jar.bzl
1:13 (52%)
1:13 (8%)
view
13 x 2 ROOT
tools/js
gerrit_api_version.bzl
eslint.bzl
1:13 (52%)
1:13 (12%)
view
13 x 2 tools
tools/maven
java.bzl
package.bzl
1:13 (52%)
1:13 (16%)
view
12 x 2 ROOT
tools/maven
gerrit_api_version.bzl
package.bzl
2:13 (48%)
2:13 (15%)
view