openai / vetu
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
  • 8% duplication:
    • 2,716 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 232 duplicated lines
  • 16 duplicates
system8% (232 lines)
dependency graphs: 2D graph | 2D graph (with duplicates)... | 3D graph | 3D graph (with duplicates)...
Duplication per Extension
go8% (232 lines)
Duplication per Component (primary)
internal8% (232 lines)
.github0% (0 lines)
cmd0% (0 lines)
Longest Duplicates
The list of 16 longest duplicates.
See data for all 16 duplicates...
Size#FoldersFilesLinesCode
25 x 2 internal/network/host
internal/network/software/dhcp
41:73 (58%)
66:98 (47%)
view
20 x 2 internal/command/run
internal/command/set
59:91 (18%)
42:73 (31%)
view
12 x 2 internal/oci/pull/tart
internal/oci/pull/vetu
26:41 (23%)
22:36 (17%)
view
11 x 2 internal/oci
internal/oci/pull/vetu
17:28 (52%)
22:32 (16%)
view
11 x 2 internal/oci
internal/oci/pull/tart
17:28 (52%)
26:37 (21%)
view
8 x 2 internal/command/push
internal/command/set
55:66 (16%)
57:68 (12%)
view
8 x 2 internal/command/push
internal/command/run
55:66 (16%)
75:86 (7%)
view
7 x 2 internal/network/host
internal/network/software/dhcp
29:39 (16%)
54:64 (13%)
view
7 x 2 internal/network/bridged
internal/network/host
25:34 (25%)
25:34 (11%)
view
7 x 2 internal/network/bridged
internal/network/software
15:27 (70%)
16:28 (70%)
view
7 x 2 internal/network/host
internal/network/software
16:28 (70%)
16:28 (70%)
view
7 x 2 internal/network/bridged
internal/network/host
15:27 (70%)
16:28 (70%)
view
7 x 2 internal/storage/local
internal/storage/remote
51:61 (9%)
80:90 (4%)
view
6 x 2 internal/command/create
internal/storage/remote
50:56 (9%)
24:30 (11%)
view
6 x 2 internal/storage/remote
internal/storage/remote
101:108 (3%)
248:256 (3%)
view
6 x 2 internal/network/bridged
internal/network/host
50:61 (22%)
99:110 (9%)
view
Most Frequent Duplicates
The list of 11 most frequently found duplicates.
Size#FoldersFilesLinesCode
6 x 3 internal/command/run
internal/command/set
internal/command/push
76:85 (5%)
58:67 (9%)
56:65 (12%)
view
6 x 3 internal/oci/pull/vetu
internal/oci
internal/oci/pull/tart
22:27 (8%)
17:22 (28%)
26:31 (11%)
view
6 x 3 internal/command/run
internal/command/set
internal/command/push
75:84 (5%)
57:66 (9%)
55:64 (12%)
view
6 x 3 internal/oci/pull/vetu
internal/oci
internal/oci/pull/tart
23:28 (8%)
18:23 (28%)
27:32 (11%)
view
6 x 3 internal/oci/pull/vetu
internal/oci
internal/oci/pull/tart
25:30 (8%)
20:26 (28%)
29:35 (11%)
view
6 x 3 internal/network/software
internal/network/bridged
internal/network/host
19:28 (60%)
18:27 (60%)
19:28 (60%)
view
6 x 3 internal/command/run
internal/command/set
internal/command/push
79:86 (5%)
61:68 (9%)
59:66 (12%)
view
6 x 3 internal/oci/pull/vetu
internal/oci
internal/oci/pull/tart
27:32 (8%)
22:28 (28%)
31:37 (11%)
view
6 x 3 internal/oci/pull/vetu
internal/oci
internal/oci/pull/tart
24:29 (8%)
19:24 (28%)
28:33 (11%)
view
6 x 3 internal/network/software
internal/network/bridged
internal/network/host
16:27 (60%)
15:26 (60%)
16:27 (60%)
view
6 x 3 internal/oci/pull/vetu
internal/oci
internal/oci/pull/tart
26:31 (8%)
21:27 (28%)
30:36 (11%)
view
Duplicated Units
The list of top 2 duplicated units.
See data for all 2 unit duplicates...
Size#FoldersFilesLinesCode
25 x 2 internal/network/software/dhcp
internal/network/host
71:100 
46:75 
view
9 x 2 internal/storage/temporary
internal/storage/local
182:196 
131:145 
view