microsoft / BotBuilder-V3
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 3,206 units with 38,524 lines of code in units (68.5% of code).
    • 2 very complex units (830 lines of code)
    • 21 complex units (1,877 lines of code)
    • 102 medium complex units (5,250 lines of code)
    • 350 simple units (8,473 lines of code)
    • 2,731 very simple units (22,094 lines of code)
2% | 4% | 13% | 21% | 57%
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
cs4% | 4% | 10% | 13% | 66%
js0% | 5% | 15% | 28% | 49%
ts0% | 4% | 16% | 28% | 51%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
CSharp/Library5% | 4% | 10% | 12% | 66%
Node/core0% | 4% | 17% | 28% | 49%
Node/calling0% | 9% | 7% | 30% | 52%
Cognitive Services/CSharp0% | 11% | 6% | 22% | 59%
Cognitive Services/Node0% | 0% | 24% | 26% | 49%
Azure/Node0% | 0% | 26% | 18% | 55%
CSharp/Tools0% | 0% | 65% | 0% | 34%
Azure/CSharp0% | 0% | 7% | 21% | 71%
Node/Generator0% | 0% | 0% | 52% | 47%
CSharp/Generator0% | 0% | 0% | 25% | 74%
Node/snippets0% | 0% | 0% | 0% | 100%
CSharp/EchoBot0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
private string ExpandTemplate()
in CSharp/Library/Microsoft.Bot.Builder/FormFlow/IPrompt.cs
233 65 7
public delegate Task DefineAsyncDelegate()
in CSharp/Library/Microsoft.Bot.Builder/FormFlow/Field.cs
597 58 2
private bool MoveToNext()
in CSharp/Library/Microsoft.Bot.Builder/FormFlow/FormDialog.cs
186 50 1
Prompts.prototype.replyReceived = function()
in Node/calling/lib/dialogs/Prompts.js
173 45 1
public replyReceived()
in Node/calling/src/dialogs/Prompts.ts
170 45 1
public async Task MessageReceived()
in CSharp/Library/Microsoft.Bot.Builder/FormFlow/FormDialog.cs
223 43 2
ChatConnector.prototype.verifyBotFramework = function()
in Node/core/lib/bots/ChatConnector.js
130 38 3
private verifyBotFramework()
in Node/core/src/bots/ChatConnector.ts
127 38 3
function PromptChoice()
in Node/core/lib/dialogs/PromptChoice.js
113 37 1
constructor()
in Node/core/src/dialogs/PromptChoice.ts
108 36 1
public async Task ProcessAsync()
in CSharp/Library/Microsoft.Bot.Builder/FormFlow/Steps.cs
164 33 5
function step()
in Node/core/skills-validator/lib/appCredentials.js
22 32 1
function step()
in Node/core/skills-validator/lib/channelValidation.js
22 32 1
function step()
in Node/core/skills-validator/lib/defaultAuthenticationConfiguration.js
22 32 1
function step()
in Node/core/skills-validator/lib/emulatorValidation.js
22 32 1
function step()
in Node/core/skills-validator/lib/jwtTokenExtractor.js
22 32 1
function step()
in Node/core/skills-validator/lib/jwtTokenValidation.js
22 32 1
function step()
in Node/core/skills-validator/lib/microsoftAppCredentials.js
22 32 1
function step()
in Node/core/skills-validator/lib/openIdMetadata.js
22 32 1
function step()
in Node/core/skills-validator/lib/skillValidation.js
22 32 1