aws-samples / ecs-chargeback-cloudformation
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
  • 16% duplication:
    • 593 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 100 duplicated lines
  • 11 duplicates
system16% (100 lines)
Duplication per Extension
yaml21% (100 lines)
Duplication per Component (primary)
Analytics_Account21% (88 lines)
Management_Account30% (12 lines)
source0% (0 lines)
Longest Duplicates
The list of 11 longest duplicates.
See data for all 11 duplicates...
Size#FoldersFilesLinesCode
13 x 2 Analytics_Account
Analytics_Account
ecs_data.yaml
get_accounts.yaml
42:54 (9%)
29:41 (7%)
view
8 x 2 Analytics_Account
Analytics_Account
ecs_data.yaml
get_accounts.yaml
33:40 (5%)
20:27 (4%)
view
7 x 2 Analytics_Account
Analytics_Account
ecs_data.yaml
get_accounts.yaml
124:130 (5%)
159:165 (4%)
view
7 x 2 Analytics_Account
Analytics_Account
ecs_data.yaml
main.yaml
42:48 (5%)
66:72 (6%)
view
7 x 2 Analytics_Account
Analytics_Account
get_accounts.yaml
main.yaml
29:35 (4%)
66:72 (6%)
view
6 x 2 Analytics_Account
Management_Account
main.yaml
Management.yaml
66:71 (5%)
16:21 (15%)
view
6 x 2 Analytics_Account
Analytics_Account
ecs_data.yaml
get_accounts.yaml
107:112 (4%)
146:151 (3%)
view
6 x 2 Analytics_Account
Analytics_Account
ecs_data.yaml
main.yaml
65:70 (4%)
80:85 (5%)
view
6 x 2 Analytics_Account
Management_Account
get_accounts.yaml
Management.yaml
29:34 (3%)
16:21 (15%)
view
6 x 2 Analytics_Account
Management_Account
ecs_data.yaml
Management.yaml
64:69 (4%)
30:35 (15%)
view
6 x 2 Analytics_Account
Management_Account
ecs_data.yaml
Management.yaml
42:47 (4%)
16:21 (15%)
view