canonical / paas-app-charmer

2 stars 2 forks source link

Refactor #29

Closed javierdelapuente closed 2 months ago

javierdelapuente commented 3 months ago

…init__

Applicable spec:

Overview

Rationale

Juju Events Changes

Module Changes

Library Changes

Checklist

github-actions[bot] commented 3 months ago

Test coverage for 77bb097c35bc1c2ef23f66fc6a05345a7c0291c8

Name                                            Stmts   Miss Branch BrPart  Cover   Missing
-------------------------------------------------------------------------------------------
paas_app_charmer/__init__.py                       29     14      0      0    52%   13-14, 19-20, 26-27, 33-34, 40-41, 47-48, 54-55
paas_app_charmer/_gunicorn/__init__.py              0      0      0      0   100%
paas_app_charmer/_gunicorn/charm.py                15      0      0      0   100%
paas_app_charmer/_gunicorn/webserver.py            77      4     14      1    95%   162, 174-180
paas_app_charmer/_gunicorn/workload_config.py       8      0      0      0   100%
paas_app_charmer/_gunicorn/wsgi_app.py            104      0     44      2    99%   86->88, 116->exit
paas_app_charmer/app.py                            25      0      2      0   100%
paas_app_charmer/charm.py                         204     25     48      4    88%   30-31, 38-39, 166-167, 169-170, 191->exit, 203-207, 260-262, 320-321, 326, 331, 336, 346, 351, 356, 361, 366, 391
paas_app_charmer/charm_state.py                   109      2     20      2    97%   189, 273
paas_app_charmer/charm_utils.py                    23      0      0      0   100%
paas_app_charmer/database_migration.py             35      0      2      0   100%
paas_app_charmer/databases.py                      25      2     11      1    92%   89-90
paas_app_charmer/django/__init__.py                 1      0      0      0   100%
paas_app_charmer/django/charm.py                   40      6      6      1    85%   71-75, 92, 107-108
paas_app_charmer/exceptions.py                      5      0      0      0   100%
paas_app_charmer/flask/__init__.py                  1      0      0      0   100%
paas_app_charmer/flask/charm.py                    32      0      2      0   100%
paas_app_charmer/observability.py                  13      0      2      0   100%
paas_app_charmer/secret_storage.py                 50      3     16      5    88%   51, 55->54, 56->58, 86, 105
paas_app_charmer/utils.py                          11      0     12      0   100%
-------------------------------------------------------------------------------------------
TOTAL                                             807     56    179     16    92%

Static code analysis report

Run started:2024-08-02 11:31:47.827364

Test results:
    No issues identified.

Code scanned:
    Total lines of code: 1724
    Total lines skipped (#nosec): 0
    Total potential issues skipped due to specifically being disabled (e.g., #nosec BXXX): 0

Run metrics:
    Total issues (by severity):
        Undefined: 0
        Low: 0
        Medium: 0
        High: 0
    Total issues (by confidence):
        Undefined: 0
        Low: 0
        Medium: 0
        High: 0
Files skipped (0):