microsoft / BotBuilder-V3
Duplication

Places in code with 6 or more lines that are exactly the same.

Intro
  • For duplication, we look at places in code where there are 6 or more lines of code that are exactly the same.
  • Before duplication is calculated, the code is cleaned to remove empty lines, comments, and frequently duplicated constructs such as imports.
  • You should aim at having as little as possible (<5%) of duplicated code as high-level of duplication can lead to maintenance difficulties, poor factoring, and logical contradictions.
Learn more...
Duplication Overall
  • 19% duplication:
    • 39,095 cleaned lines of cleaned code (without empty lines, comments, and frequently duplicated constructs such as imports)
    • 7,805 duplicated lines
  • 987 duplicates
system19% (7,805 lines)
Duplication per Extension
js36% (4,396 lines)
ts28% (2,708 lines)
cs3% (531 lines)
ps192% (146 lines)
cmd11% (24 lines)
Duplication per Component (primary)
Node/core28% (4,425 lines)
Node/calling44% (1,685 lines)
Cognitive Services/Node55% (683 lines)
CSharp/Library2% (427 lines)
Azure/Node25% (263 lines)
Azure/CSharp9% (123 lines)
CSharp/buildtools89% (73 lines)
Node/Generator24% (30 lines)
CSharp/EchoBot42% (27 lines)
CSharp/Generator8% (27 lines)
Cognitive Services/CSharp2% (24 lines)
Node/snippets9% (18 lines)
CSharp0% (0 lines)
CSharp/Tools0% (0 lines)

Duplication Between Components (50+ lines)

G Node/calling Node/calling Node/core Node/core Node/calling--Node/core 1720 Azure/Node Azure/Node Azure/Node--Node/core 315 Cognitive Services/Node Cognitive Services/Node Cognitive Services/Node--Node/core 215 Azure/CSharp Azure/CSharp CSharp/buildtools CSharp/buildtools Azure/CSharp--CSharp/buildtools 146 CSharp/EchoBot CSharp/EchoBot CSharp/Generator CSharp/Generator CSharp/EchoBot--CSharp/Generator 54

Download: SVG DOT (open online Graphviz editor)

Open 3D force graph...

Show more details on duplication between components...
Longest Duplicates
The list of 20 longest duplicates.
See data for all 987 duplicates...
Size#FoldersFilesLinesCode
52 x 2 Node/calling/src/storage
Node/core/src/storage
BotStorage.ts
BotStorage.ts
40:122 (92%)
40:122 (92%)
view
50 x 2 Node/calling/lib/storage
Node/core/lib/storage
BotStorage.js
BotStorage.js
2:72 (98%)
3:73 (96%)
view
48 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
defaultAuthenticationConfiguration.js
microsoftAppCredentials.js
1:50 (62%)
1:50 (64%)
view
45 x 2 Cognitive Services/Node/lib
Cognitive Services/Node/src
LuisActionBinding.js
LuisActionBinding.js
1:48 (13%)
34:101 (13%)
view
40 x 2 Cognitive Services/Node/lib
Cognitive Services/Node/src
LuisActionBinding.js
LuisActionBinding.js
121:169 (12%)
202:275 (12%)
view
39 x 2 Azure/CSharp/buildtools
CSharp/buildtools
SetVersionInAssemblyInfoCsFiles.ps1
SetVersionInAssemblyInfoCsFiles.ps1
1:43 (100%)
1:43 (100%)
view
37 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
emulatorValidation.js
skillValidation.js
1:39 (31%)
1:39 (25%)
view
37 x 2 Cognitive Services/Node/lib
Cognitive Services/Node/src
LuisBuiltInTypes.js
LuisBuiltInTypes.js
1:38 (100%)
34:74 (100%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
openIdMetadata.js
skillValidation.js
1:37 (30%)
1:37 (23%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
appCredentials.js
skillValidation.js
1:37 (25%)
1:37 (23%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
jwtTokenValidation.js
skillValidation.js
1:37 (23%)
1:37 (23%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
appCredentials.js
channelValidation.js
1:37 (25%)
1:37 (35%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
jwtTokenExtractor.js
skillValidation.js
13:49 (23%)
2:38 (23%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
emulatorValidation.js
jwtTokenValidation.js
1:37 (30%)
1:37 (23%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
emulatorValidation.js
jwtTokenExtractor.js
2:38 (30%)
13:49 (23%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
channelValidation.js
emulatorValidation.js
1:37 (35%)
1:37 (30%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
jwtTokenValidation.js
microsoftAppCredentials.js
2:38 (23%)
15:51 (46%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
emulatorValidation.js
openIdMetadata.js
1:37 (30%)
1:37 (30%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
channelValidation.js
jwtTokenValidation.js
1:37 (35%)
1:37 (23%)
view
35 x 2 Node/core/skills-validator/lib
Node/core/skills-validator/lib
jwtTokenValidation.js
openIdMetadata.js
1:37 (23%)
1:37 (30%)
view
Duplicated Units
The list of top 20 duplicated units.
See data for all 66 unit duplicates...
Size#FoldersFilesLinesCode
30 x 2 Node/calling/lib/storage
Node/core/lib/storage
BotStorage.js
BotStorage.js
7:37 
8:38 
view
27 x 2 Node/calling/src/storage
Node/core/src/storage
BotStorage.ts
BotStorage.ts
59:89 
59:89 
view
22 x 2 CSharp/Library/Microsoft.Bot.Connector.AspNetCore
CSharp/Library/Microsoft....Connector.NetFramework
TrustServiceUrlAttribute.cs
BotAuthentication.cs
32:54 
85:107 
view
22 x 2 Node/calling/lib/bots
Node/core/lib/bots
Library.js
Library.js
36:58 
415:437 
view
21 x 9 Node/core/skills-validator/lib
Node/core/skills-validator/lib
Node/core/skills-validator/lib
Node/core/skills-validator/lib
Node/core/skills-validator/lib
Node/core/skills-validator/lib
Node/core/skills-validator/lib
Node/core/skills-validator/lib
Node/core/skills-validator/lib
appCredentials.js
channelValidation.js
defaultAuthenticationConfiguration.js
emulatorValidation.js
jwtTokenExtractor.js
jwtTokenValidation.js
microsoftAppCredentials.js
openIdMetadata.js
skillValidation.js
14:35 
14:35 
27:48 
14:35 
25:46 
14:35 
27:48 
14:35 
14:35 
view
20 x 2 Node/calling/lib/dialogs
Node/core/lib/dialogs
DialogAction.js
DialogAction.js
18:38 
20:40 
view
20 x 2 Node/calling/src/bots
Node/core/src/bots
UniversalCallBot.ts
UniversalBot.ts
137:157 
184:204 
view
19 x 2 Node/calling/src/bots
Node/core/src/bots
Library.ts
Library.ts
82:103 
556:577 
view
18 x 2 Node/calling/lib/bots
Node/core/lib/bots
UniversalCallBot.js
UniversalBot.js
170:188 
460:478 
view
17 x 2 CSharp/EchoBot/App_Start
CSharp/Generator/BotApplication/App_Start
WebApiConfig.cs
WebApiConfig.cs
12:34 
12:35 
view
16 x 4 CSharp/Library/Microsoft.Bot.Connector.Shared
CSharp/Library/Microsoft.Bot.Connector.Shared
CSharp/Library/Microsoft.Bot.Connector.Shared
CSharp/Library/Microsoft.Bot.Connector.Shared
AnimationCardEx.cs
AudioCardEx.cs
MediaCardEx.cs
VideoCardEx.cs
15:31 
15:31 
15:31 
15:31 
view
16 x 2 CSharp/Library/Microsoft...nnector.Shared/OAuthAPI
CSharp/Library/Microsoft...nnector.Shared/OAuthAPI
OAuthClient.cs
OAuthClient.cs
185:201 
221:237 
view
16 x 2 Cognitive Services/Node/lib
Cognitive Services/Node/src
LuisActionBinding.js
LuisActionBinding.js
131:147 
217:241 
view
16 x 2 Node/calling/lib/bots
Node/core/lib/bots
UniversalCallBot.js
UniversalBot.js
204:220 
494:510 
view
16 x 2 Node/calling/lib/storage
Node/core/lib/storage
BotStorage.js
BotStorage.js
53:69 
54:70 
view
15 x 2 Node/calling/src/bots
Node/core/src/bots
UniversalCallBot.ts
UniversalBot.ts
292:307 
593:608 
view
15 x 2 Node/calling/src/storage
Node/core/src/storage
BotStorage.ts
BotStorage.ts
110:127 
110:127 
view
14 x 2 CSharp/Library/Microsoft.Bot.Builder.FormFlow.Json
CSharp/Library/Microsoft.Bot.Builder/FormFlow
FormBuilderJson.cs
FormBuilder.cs
391:406 
461:476 
view
14 x 2 Node/calling/lib/bots
Node/core/lib/bots
UniversalCallBot.js
UniversalBot.js
189:203 
479:493 
view
14 x 2 Node/calling/lib/storage
Node/core/lib/storage
BotStorage.js
BotStorage.js
38:52 
39:53 
view