aws-samples / automated-network-firewall-rules-for-cloudfront-ip-ranges
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
  • 79% duplication:
    • 332 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 264 duplicated lines
  • 5 duplicates
system79% (264 lines)
Duplication per Extension
yml66% (132 lines)
py100% (132 lines)
Duplication per Component (primary)
ROOT79% (264 lines)
Longest Duplicates
The list of 5 longest duplicates.
See data for all 5 duplicates...
Size#FoldersFilesLinesCode
132 x 2 ROOT
ROOT
lambda.py
template.yml
9:198 (100%)
89:278 (66%)
view
12 x 2 ROOT
ROOT
template.yml
template.yml
149:160 (6%)
172:183 (6%)
view
12 x 2 ROOT
ROOT
lambda.py
lambda.py
69:80 (9%)
92:103 (9%)
view
12 x 2 ROOT
ROOT
lambda.py
template.yml
69:80 (9%)
172:183 (6%)
view
12 x 2 ROOT
ROOT
lambda.py
template.yml
92:103 (9%)
149:160 (6%)
view