awslabs / aws-simple-cicd
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 20 units with 573 lines of code in units (64.1% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 0 medium complex units (0 lines of code)
    • 1 simple units (181 lines of code)
    • 19 very simple units (392 lines of code)
0% | 0% | 0% | 31% | 68%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
ts0% | 0% | 0% | 36% | 63%
py0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
lib/pipelines0% | 0% | 0% | 100% | 0%
lib/projects0% | 0% | 0% | 0% | 100%
lib0% | 0% | 0% | 0% | 100%
lambda-helpers/semver-handler0% | 0% | 0% | 0% | 100%
lib/iam0% | 0% | 0% | 0% | 100%
lambda-helpers/email-handler0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
constructor()
in lib/pipelines/simple-cicd-pipeline.ts
181 7 3
def get_user_params()
in lambda-helpers/semver-handler/lambda.py
11 5 1
constructor()
in lib/cicd-stack.ts
33 2 3
constructor()
in lib/iam/code-build-role.ts
43 2 3
def put_job_success()
in lambda-helpers/semver-handler/lambda.py
6 2 2
def put_job_failure()
in lambda-helpers/semver-handler/lambda.py
6 2 2
def semver_handler()
in lambda-helpers/semver-handler/lambda.py
28 2 2
constructor()
in lib/emailHandler-stack.ts
27 1 3
constructor()
in lib/semverHandler-stack.ts
33 1 3
constructor()
in lib/projects/deploy-project.ts
31 1 3
environmentVariables: projectEnvironmentVars()
in lib/projects/deploy-project.ts
1 1 4
constructor()
in lib/projects/build-project.ts
29 1 3
environmentVariables: projectEnvironmentVars()
in lib/projects/build-project.ts
1 1 3
export function projectEnvironmentVars()
in lib/projects/deploy-project-environment.ts
39 1 1
constructor()
in lib/projects/test-project.ts
32 1 3
environmentVariables: projectEnvironmentVars()
in lib/projects/test-project.ts
1 1 3
export function projectEnvironmentVars()
in lib/projects/build-project-environment.ts
22 1 1
constructor()
in lib/cicd-s3-stack.ts
23 1 3
constructor()
in lib/iam/pipeline-role.ts
6 1 3
def send_codebuild_events_to_sns()
in lambda-helpers/email-handler/lambda.py
20 1 2