firebase / firebase-admin-python
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 875 units with 5,544 lines of code in units (82.7% of code).
    • 0 very long units (0 lines of code)
    • 2 long units (170 lines of code)
    • 37 medium size units (1,034 lines of code)
    • 114 small units (1,585 lines of code)
    • 722 very small units (2,755 lines of code)
0% | 3% | 18% | 28% | 49%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 3% | 18% | 28% | 49%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
firebase_admin0% | 3% | 19% | 23% | 52%
snippets/auth0% | 0% | 18% | 40% | 41%
snippets/messaging0% | 0% | 13% | 71% | 15%
snippets/database0% | 0% | 0% | 66% | 33%
integration0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def encode_android_notification()
in firebase_admin/_messaging_encoder.py
89 18 2
def verify()
in firebase_admin/_token_gen.py
81 24 3
def encode_action_code_settings()
in firebase_admin/_user_mgt.py
45 19 1
def update_user()
in firebase_admin/_user_mgt.py
44 18 12
def encode_webpush_notification()
in firebase_admin/_messaging_encoder.py
44 9 2
def update_oidc_provider_config()
in firebase_admin/_auth_providers.py
37 13 9
def create_custom_token()
in firebase_admin/_token_gen.py
37 11 4
def encode_aps_alert()
in firebase_admin/_messaging_encoder.py
37 11 2
def encode_light_settings()
in firebase_admin/_messaging_encoder.py
36 10 2
def update_saml_provider_config()
in firebase_admin/_auth_providers.py
35 12 9
def send_all()
in firebase_admin/messaging.py
32 6 3
def __init__()
in firebase_admin/_messaging_utils.py
31 1 26
def create_session_cookie()
in firebase_admin/_token_gen.py
30 12 3
def handle_operation()
in firebase_admin/ml.py
29 7 4
def create_oidc_provider_config()
in firebase_admin/_auth_providers.py
28 9 9
def get_users()
in firebase_admin/_user_mgt.py
28 9 2
def get_client()
in firebase_admin/db.py
28 7 2
def make_topic_management_request()
in firebase_admin/messaging.py
28 12 4
def __next__()
in firebase_admin/_sseclient.py
27 11 1
def import_without_password()
in snippets/auth/index.py
27 3 0