whatsapp / WADebug
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 158 units with 1,535 lines of code in units (71.8% of code).
    • 1 very long units (105 lines of code)
    • 0 long units (0 lines of code)
    • 14 medium size units (426 lines of code)
    • 30 small units (426 lines of code)
    • 113 very small units (578 lines of code)
6% | 0% | 27% | 27% | 37%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py6% | 0% | 27% | 27% | 37%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
wadebug/wa_actions/implementations26% | 0% | 31% | 13% | 28%
wadebug0% | 0% | 31% | 29% | 39%
wadebug/wa_actions0% | 0% | 23% | 33% | 42%
wadebug/wa_actions/models0% | 0% | 0% | 68% | 31%
wadebug/wa_actions/common0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 50 longest units
Unit# linesMcCabe index# params
105 21 4
49 7 3
45 12 4
37 6 3
33 3 0
30 3 2
30 5 4
29 10 2
29 3 4
28 3 1
25 9 0
24 4 4
24 4 4
22 6 3
21 5 2
20 7 1
20 5 4
19 6 3
19 1 2
19 6 4
17 6 3
17 3 4
16 4 1
16 4 1
15 5 1
15 2 2
15 3 0
14 4 2
14 4 2
14 1 2
13 3 1
13 3 3
13 4 0
12 3 0
12 1 3
12 2 1
12 1 2
12 4 2
11 3 1
11 2 1
11 1 3
11 3 1
11 3 1
11 3 1
11 2 1
10 1 1
10 1 1
10 2 2
10 1 1
10 2 1