aws-samples / streamlit-application-deployment-on-aws
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 31 units with 246 lines of code in units (13.2% 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 (15 lines of code)
    • 30 very simple units (231 lines of code)
0% | 0% | 0% | 6% | 93%
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
py0% | 0% | 0% | 6% | 93%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
script0% | 0% | 0% | 75% | 25%
deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate0% | 0% | 0% | 0% | 100%
deployment/sagemaker-dashboards-for-ml/cloudformation/assistants/solution-assistant0% | 0% | 0% | 0% | 100%
deployment/sagemaker-dashboards-for-ml/cloudformation/assistants/bucket-assistant0% | 0% | 0% | 0% | 100%
deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/string-functions0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def write_data()
in script/yahoo_idx.py
15 6 4
def delete_acm_certificate()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/delete.py
15 5 3
def attempt_delete_acm_certificate()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/delete.py
24 4 1
def delete_ecr_images()
in deployment/sagemaker-dashboards-for-ml/cloudformation/assistants/solution-assistant/src/index.py
27 4 1
def on_create()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/string-functions/src/index.py
11 3 2
def delete_sagemaker_endpoint()
in deployment/sagemaker-dashboards-for-ml/cloudformation/assistants/solution-assistant/src/index.py
16 3 1
def delete_sagemaker_endpoint_config()
in deployment/sagemaker-dashboards-for-ml/cloudformation/assistants/solution-assistant/src/index.py
18 3 1
def delete_sagemaker_model()
in deployment/sagemaker-dashboards-for-ml/cloudformation/assistants/solution-assistant/src/index.py
13 3 1
def delete_s3_objects()
in deployment/sagemaker-dashboards-for-ml/cloudformation/assistants/bucket-assistant/src/index.py
14 3 1
def random_string()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/string-functions/src/index.py
3 2 1
def on_delete()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/string-functions/src/index.py
2 1 2
def handler()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/string-functions/src/index.py
2 1 2
def on_create()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/delete.py
2 1 2
def on_update()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/delete.py
2 1 2
def on_delete()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/delete.py
3 1 2
def handler()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/delete.py
2 1 2
def generate_key()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/create.py
7 1 0
def generate_self_signed_certificate()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/create.py
21 1 1
def acm_import_certificate()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/create.py
15 1 2
def on_create()
in deployment/sagemaker-dashboards-for-ml/cloudformation/deployment/self-signed-certificate/src/create.py
5 1 2