Public report of storybookjs/storybook, published 26 October 2026. It has the same score, grades and number of findings as the full report. The details of security findings (where they are in the code, which known vulnerabilities and which passwords or keys were found) are left out, so nobody can use them against the project.
Public
Executive report Measured under the Code Assurance Index, an open standard for code quality, using its published scoring rules (rubric version 2026.10.5). Assert signed this survey and filed it in the standard's public register, where anyone can look it up by its survey ID. Check this survey → Signed and filed in the standard's public register, 26 October 2026, 12:45 UTC · Survey ID cd_f594970a970f42d99801c761963e108a

storybookjs/storybook

Measured 26 October 2026, 12:20 UTC, at code version 2d0df5c

No regression since the last survey

A regression is a drop of 0.5 points or more in the score, or of 2.5 or more out of 10 in a dimension, since the last survey.

CAI score 53out of 100 At risk Down 1 since the last survey

The score is built from these lenses. Each lens grades one area of the code, such as how easy it is to change or how well it is protected. The weakest lens counts most, so one weak area pulls the score down instead of being averaged away.

A large codebase: 392,689 lines of product code in 86 projects, tests not counted · Estimated rebuild effort: about 4.3 person-years · Weakest lens: Production Readiness, 47

Findings by how serious they are

213 critical 2582 serious 521 minor

7 dimensions are left out of the score. For each one, Watchdog either couldn't measure it in this code, or found no evidence of the safeguard it looks for, such as a tested backup restore. They count neither for nor against the score, and Limitations lists each one with its reason.

This survey was produced by

Watchdog
Producer
Canine Development
Analyzer
Watchdog engine 1.0.0
Measured
26 October 2026, 12:20 UTC

A measurement, not a certificate. The Code Assurance Index records a number together with the evidence it was worked out from, so anyone can recalculate it, but it doesn't certify or guarantee the code. The standard was written by Canine Development, which also builds Watchdog. It is open to any tool that implements it, and today Watchdog is the only one that does.

A critical security finding is open, such as a library with a known critical vulnerability or a password or key found in the code. The score itself is unchanged, but its band shows At risk until the finding is fixed. See the Security and Compliance lens.

The score is deterministic, which means the same code always gets the same score. Watchdog works it out with tools that follow published rules, and an AI model never decides it, so anyone who applies the same rules to the same code gets the same number. How it is done is explained under Methodology ▸

88of 88 dimensions measured by tools.
3151of 3316 findings point to an exact file and line, so you can open each one in the code. The other 165 concern the repository as a whole, such as missing documentation.
88dimensions across 7 lenses, read from 392,689 lines of product code in 86 projects.
Chapters

Executive summary

storybookjs/storybook is rated At risk because critical security findings are open, most of them in the packages it uses. Its score is held back in part because it has uses of packages that aren't listed. It scores 53 out of 100, which the At risk rating leaves unchanged.

Production Readiness, at 47, is the weakest lens and counts most in the score. The best first step for the work it takes is replacing the seven deprecated dependencies, worth about 3 points. Tidying the declared packages would lift Production Readiness itself, worth about 5 points. Raising Production Readiness to 70 would lift the score to about 59.

Ninety-three known security holes in the packages the code depends on can be used by attackers. Eleven passwords or keys are open to anyone who can read the repository, and seven weaknesses in the code could be used by an attacker. Updating the vulnerable packages, replacing each exposed password or key and fixing the weaknesses the scanner points to would close these risks. Pinning each tool to an exact version would fix the two pipeline tools referenced by a changeable name, and the place where the code runs text as code or as a command needs a direct call instead. The 24 tests that check nothing need to check the result they produce.

The product code is 392,689 lines, about €620,000 to rebuild.

A lens is capped at Adequate while one of its dimensions scores below 4 out of 10, however well the rest of the lens does. That way a serious problem in one place always shows in the lens's rating.

How the score is built: what each lens counts for The lenses don't count equally. The weakest lens counts most, the next weakest a little less, and so on, so a weak area pulls the score down instead of being averaged away. In the bar below, each part's width shows how much that lens counts and its colour shows its rating. Improving the widest part moves the score most, and as that lens improves, it counts for less, because another lens becomes the weakest.
Production Readiness 47 · counts for 46%Accessibility 56 · counts for 25%Security and Compliance 60 · counts for 14%Architecture 60 · counts for 8%Performance 60 · counts for 4%Code Health 65 · counts for 2%Maturity 75 · counts for 1%

If Production Readiness rose from 47 to 70, the lowest score rated Strong, the score would rise from 53 to about 59.

Code composition: what the lines of code are
Product code 62%Tests 38%
New since the last survey: 995 findings

These 995 critical or serious findings weren't in the previous survey, on 12 October 2026. The first 100 are listed here, and the findings file in the download package lists them all.

  • Cyclomatic Complexity · Tree.Tree (cyclomatic 85) code/core/src/manager/components/sidebar/Tree.tsx
  • Cyclomatic Complexity · scope.analyzeScopes.visitNode (cyclomatic 81) code/core/src/csf-tools/estree/scope.ts
  • Cyclomatic Complexity · ConfigObject.locateConfigRoot (cyclomatic 67) code/core/src/csf-tools/ConfigObject.ts
  • Cyclomatic Complexity · CsfFile._visitExportNamed (cyclomatic 57) REDACTED
  • Cyclomatic Complexity · Editor.groupValues (cyclomatic 46) code/core/src/csf-tools/CsfObject.ts
  • Cyclomatic Complexity · generate-docgen.extractDocgen (cyclomatic 46) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts
  • Cyclomatic Complexity · print-template.printTemplate (cyclomatic 43) code/renderers/svelte/src/docgen/story-docs/print-template.ts
  • Cyclomatic Complexity · server-code-elimination.eliminateServerCode (cyclomatic 41) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts
  • Cyclomatic Complexity · ConfigFile.findCallArguments (cyclomatic 38) code/core/src/csf-tools/ConfigFile.ts
  • Cyclomatic Complexity · values.readResolved (cyclomatic 31) code/core/src/csf-tools/estree/values.ts
  • Cyclomatic Complexity · server-code-elimination.isPure (cyclomatic 30) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts
  • Cyclomatic Complexity · print-template.replaceArgsReads (cyclomatic 30) code/renderers/svelte/src/docgen/story-docs/print-template.ts
  • Cyclomatic Complexity · scope.analyzeScopes (cyclomatic 28) code/core/src/csf-tools/estree/scope.ts
  • Cyclomatic Complexity · editor.appendFirst (cyclomatic 28) code/core/src/csf-tools/estree/editor.ts
  • Cyclomatic Complexity · ObjectMembers.onlyRead (cyclomatic 28) code/core/src/csf-tools/ObjectMembers.ts
  • Cyclomatic Complexity · create-server-arg-types.createServerArgTypes (cyclomatic 28) code/renderers/svelte/src/docgen/component-docgen/arg-types/create-server-arg-types.ts
  • Cyclomatic Complexity · generateCodeSnippet.rewriteJsx (cyclomatic 27) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cyclomatic Complexity · changed-files-outside-stories.detectChangedFilesOutsideStories (cyclomatic 26) code/core/src/shared/open-service/toolsets/stories/changed-files-outside-stories.ts
  • Cyclomatic Complexity · TreeNode.TreeNode (cyclomatic 26) code/core/src/manager/components/sidebar/TreeNode.tsx
  • Cyclomatic Complexity · Editor.moveValue (cyclomatic 25) code/core/src/csf-tools/CsfObject.ts
  • Cyclomatic Complexity · snippet-imports.markupReferences (cyclomatic 25) code/renderers/svelte/src/docgen/story-docs/snippet-imports.ts
  • Cyclomatic Complexity · scope.analyzeScopes.enterScope (cyclomatic 24) code/core/src/csf-tools/estree/scope.ts
  • Cyclomatic Complexity · generate-docgen.convertType (cyclomatic 24) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts
  • Cyclomatic Complexity · resolve-component.followExport (cyclomatic 24) code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts
  • Cyclomatic Complexity · CsfObjectDiscovery.assignmentsOf (cyclomatic 23) code/core/src/csf-tools/CsfObjectDiscovery.ts
  • Cyclomatic Complexity · generate-docgen.createDocgenProgram (cyclomatic 23) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts
  • Cyclomatic Complexity · generateCodeSnippet.functionSnippet (cyclomatic 22) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cyclomatic Complexity · build-story-docs.snippetArg (cyclomatic 22) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts
  • Cyclomatic Complexity · imports.setImport (cyclomatic 21) code/core/src/csf-tools/estree/imports.ts
  • Cyclomatic Complexity · editor.printValue (cyclomatic 20) code/core/src/csf-tools/estree/editor.ts
  • Cyclomatic Complexity · eslintPlugin.findConfigHelperNames (cyclomatic 20) code/core/src/cli/eslintPlugin.ts
  • Cyclomatic Complexity · CsfFile._visitExpressionStatement (cyclomatic 19) REDACTED
  • Cyclomatic Complexity · duplicate-story-with-new-name.duplicateStoryWithNewName (cyclomatic 19) code/core/src/core-server/utils/save-story/duplicate-story-with-new-name.ts
  • Cyclomatic Complexity · svelte-csf-to-csf-factory.transformModuleScript (cyclomatic 19) code/lib/cli-storybook/src/codemod/helpers/svelte-csf-to-csf-factory.ts
  • Cyclomatic Complexity · generate-docgen.initializerToDefaultValue (cyclomatic 19) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts
  • Cyclomatic Complexity · codemod.transformSvelteCsfNextFile (cyclomatic 19) scripts/snippets/codemod.ts
  • Cyclomatic Complexity · resolve-members.declaredMembers (cyclomatic 18) code/core/src/csf-tools/story-shape/resolve-members.ts
  • Cyclomatic Complexity · ContextMenu.ContextMenu (cyclomatic 18) code/core/src/manager/components/sidebar/ContextMenu.tsx
  • Cyclomatic Complexity · server-code-elimination.eliminateDeadCode (cyclomatic 18) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts
  • Cyclomatic Complexity · util.generateUpgradeSpecs (cyclomatic 18) code/lib/cli-storybook/src/util.ts
  • Cyclomatic Complexity · metroConfig.transformMetroConfigSource (cyclomatic 18) code/lib/create-storybook/src/generators/REACT_NATIVE/metroConfig.ts
  • Cyclomatic Complexity · forward-setup.collectArgsReads (cyclomatic 18) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts
  • Cyclomatic Complexity · CsfFile._visitCallExpression (cyclomatic 17) REDACTED
  • Cyclomatic Complexity · vitest-setup-file.countReferences (cyclomatic 17) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts
  • Cyclomatic Complexity · import-source.findMeta (cyclomatic 17) code/renderers/svelte/src/svelte-csf/utils/import-source.ts
  • Cyclomatic Complexity · Source.useCode (cyclomatic 16) code/addons/docs/src/blocks/blocks/Source.tsx
  • Cyclomatic Complexity · CsfObjectPath.locate (cyclomatic 16) code/core/src/csf-tools/CsfObjectPath.ts
  • Cyclomatic Complexity · sync-main-preview-addons.syncPreviewAddonsWithMainConfig (cyclomatic 16) code/core/src/common/utils/sync-main-preview-addons.ts
  • Cyclomatic Complexity · eslintPlugin.findConfigTarget (cyclomatic 16) code/core/src/cli/eslintPlugin.ts
  • Cyclomatic Complexity · build-story-docs.buildStoryDocsPayload (cyclomatic 16) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts
  • Cyclomatic Complexity · build-story-docs.storySnippet (cyclomatic 16) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts
  • Cognitive Complexity · CsfFile._visitExportNamed (cognitive 133) REDACTED
  • Cognitive Complexity · scope.analyzeScopes.visitNode (cognitive 91) code/core/src/csf-tools/estree/scope.ts
  • Cognitive Complexity · ConfigObject.locateConfigRoot (cognitive 84) code/core/src/csf-tools/ConfigObject.ts
  • Cognitive Complexity · Tree.Tree (cognitive 83) code/core/src/manager/components/sidebar/Tree.tsx
  • Cognitive Complexity · Editor.groupValues (cognitive 79) code/core/src/csf-tools/CsfObject.ts
  • Cognitive Complexity · generate-docgen.extractDocgen (cognitive 71) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts
  • Cognitive Complexity · values.readResolved (cognitive 55) code/core/src/csf-tools/estree/values.ts
  • Cognitive Complexity · generateCodeSnippet.rewriteJsx (cognitive 50) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cognitive Complexity · server-code-elimination.eliminateServerCode (cognitive 49) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts
  • Cognitive Complexity · scope.analyzeScopes (cognitive 44) code/core/src/csf-tools/estree/scope.ts
  • Cognitive Complexity · eslintPlugin.findConfigHelperNames (cognitive 43) code/core/src/cli/eslintPlugin.ts
  • Cognitive Complexity · print-template.printTemplate (cognitive 42) code/renderers/svelte/src/docgen/story-docs/print-template.ts
  • Cognitive Complexity · editor.appendFirst (cognitive 40) code/core/src/csf-tools/estree/editor.ts
  • Cognitive Complexity · scope.analyzeScopes.enterScope (cognitive 39) code/core/src/csf-tools/estree/scope.ts
  • Cognitive Complexity · ConfigFile.findCallArguments (cognitive 38) code/core/src/csf-tools/ConfigFile.ts
  • Cognitive Complexity · generateCodeSnippet.functionSnippet (cognitive 38) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cognitive Complexity · CsfObjectPath.locate (cognitive 35) code/core/src/csf-tools/CsfObjectPath.ts
  • Cognitive Complexity · generate-docgen.createDocgenProgram (cognitive 35) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts
  • Cognitive Complexity · CsfFile._visitCallExpression (cognitive 34) REDACTED
  • Cognitive Complexity · server-code-elimination.eliminateDeadCode (cognitive 34) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts
  • Cognitive Complexity · CsfObjectDiscovery.storyExports (cognitive 31) code/core/src/csf-tools/CsfObjectDiscovery.ts
  • Cognitive Complexity · changed-files-outside-stories.detectChangedFilesOutsideStories (cognitive 31) code/core/src/shared/open-service/toolsets/stories/changed-files-outside-stories.ts
  • Cognitive Complexity · snippet-imports.markupReferences (cognitive 31) code/renderers/svelte/src/docgen/story-docs/snippet-imports.ts
  • Cognitive Complexity · resolve-component.followExport (cognitive 30) code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts
  • Cognitive Complexity · editor.printValue (cognitive 28) code/core/src/csf-tools/estree/editor.ts
  • Cognitive Complexity · TreeNode.TreeNode (cognitive 28) code/core/src/manager/components/sidebar/TreeNode.tsx
  • Cognitive Complexity · print-template.replaceArgsReads (cognitive 28) code/renderers/svelte/src/docgen/story-docs/print-template.ts
  • Cognitive Complexity · CsfObjectDiscovery.assignmentsOf (cognitive 27) code/core/src/csf-tools/CsfObjectDiscovery.ts
  • Cognitive Complexity · generate-docgen.convertType (cognitive 27) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts
  • Cognitive Complexity · import-source.findMeta (cognitive 27) code/renderers/svelte/src/svelte-csf/utils/import-source.ts
  • Cognitive Complexity · build-story-docs.snippetArg (cognitive 25) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts
  • Cognitive Complexity · Editor.moveValue (cognitive 24) code/core/src/csf-tools/CsfObject.ts
  • Cognitive Complexity · status.getGroupDualStatus (cognitive 24) code/core/src/manager/utils/status.tsx
  • Cognitive Complexity · codemod.transformSvelteCsfNextFile (cognitive 24) scripts/snippets/codemod.ts
  • Cognitive Complexity · editor.removeFromList (cognitive 23) code/core/src/csf-tools/estree/editor.ts
  • Cognitive Complexity · imports.setImport (cognitive 23) code/core/src/csf-tools/estree/imports.ts
  • Cognitive Complexity · resolve-members.declaredMembers (cognitive 23) code/core/src/csf-tools/story-shape/resolve-members.ts
  • Cognitive Complexity · svelte-csf-to-csf-factory.transformModuleScript (cognitive 23) code/lib/cli-storybook/src/codemod/helpers/svelte-csf-to-csf-factory.ts
  • Cognitive Complexity · ObjectMembers.onlyRead (cognitive 22) code/core/src/csf-tools/ObjectMembers.ts
  • Cognitive Complexity · ConfigFile._getPresetValue (cognitive 21) code/core/src/csf-tools/ConfigFile.ts
  • Cognitive Complexity · tag-filter-api.renameSetFilterIdentifiers (cognitive 21) code/lib/cli-storybook/src/automigrate/fixes/tag-filter-api.ts
  • Cognitive Complexity · extend.getStoryParents (cognitive 21) code/renderers/svelte/src/svelte-csf/parser/analyse/story/extend.ts
  • Cognitive Complexity · build-story-docs.buildStoryDocsPayload (cognitive 21) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts
  • Cognitive Complexity · ast.normalize (cognitive 20) code/core/src/csf-tools/estree/ast.ts
  • Cognitive Complexity · svelte-csf-file.templateParameter (cognitive 20) code/renderers/svelte/src/docgen/story-docs/svelte-csf-file.ts
  • Cognitive Complexity · codemod.buildSvelteCsfNextFence (cognitive 20) scripts/snippets/codemod.ts
  • Cognitive Complexity · scope.analyzeScopes.declareLexical (cognitive 19) code/core/src/csf-tools/estree/scope.ts
  • Cognitive Complexity · ContextMenu.ContextMenu (cognitive 19) code/core/src/manager/components/sidebar/ContextMenu.tsx
  • Cognitive Complexity · create-server-arg-types.createServerArgTypes (cognitive 19) code/renderers/svelte/src/docgen/component-docgen/arg-types/create-server-arg-types.ts

Watchdog compares every finding with the previous survey's. A finding that has only moved to another line in the same file counts as the same finding, so only new findings appear here. Advisory notes from the AI model are left out, because the model words them afresh in every survey.

Fixed since the last survey: 1365 findings

These 1365 critical or serious findings were in the previous survey, on 12 October 2026, and are gone from this one. The first 100 are listed here.

  • Cyclomatic Complexity · Tree.Node (cyclomatic 68) code/core/src/manager/components/sidebar/Tree.tsx
  • Cyclomatic Complexity · ConfigObject.createConfigObject (cyclomatic 57) code/core/src/csf-tools/ConfigObject.ts
  • Cyclomatic Complexity · generateDocgen.generateDocgen (cyclomatic 54) code/frameworks/svelte-vite/src/plugins/generateDocgen.ts
  • Cyclomatic Complexity · CsfObjectEditor.group (cyclomatic 47) code/core/src/csf-tools/CsfObject.ts
  • Cyclomatic Complexity · ConfigFile.callArguments (cyclomatic 37) code/core/src/csf-tools/ConfigFile.ts
  • Cyclomatic Complexity · server-code-elimination.serverCodeElimination (cyclomatic 36) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts
  • Cyclomatic Complexity · useExpanded.useExpanded (cyclomatic 33) code/core/src/manager/components/sidebar/useExpanded.ts
  • Cyclomatic Complexity · generateCodeSnippet.buildSnippetNode (cyclomatic 33) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cyclomatic Complexity · CsfObjectEditor.readValue (cyclomatic 31) code/core/src/csf-tools/CsfObject.ts
  • Cyclomatic Complexity · updateVitestFile.updateConfigFile (cyclomatic 30) code/addons/vitest/src/updateVitestFile.ts
  • Cyclomatic Complexity · ConfigObject.createConfigObject::syncExports (cyclomatic 29) code/core/src/csf-tools/ConfigObject.ts
  • Cyclomatic Complexity · update-args-in-csf-file.updateArgsInCsfFile (cyclomatic 26) code/core/src/core-server/utils/save-story/update-args-in-csf-file.ts
  • Cyclomatic Complexity · generateDocgen.convertType (cyclomatic 24) code/frameworks/svelte-vite/src/plugins/generateDocgen.ts
  • Cyclomatic Complexity · CsfObjectEditor.move (cyclomatic 22) code/core/src/csf-tools/CsfObject.ts
  • Cyclomatic Complexity · ConfigFile.removeField (cyclomatic 22) code/core/src/csf-tools/ConfigFile.ts
  • Cyclomatic Complexity · ConfigFile._removeRequireImport (cyclomatic 22) code/core/src/csf-tools/ConfigFile.ts
  • Cyclomatic Complexity · generateCodeSnippet.inlineArgsInJsx (cyclomatic 22) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cyclomatic Complexity · ConfigFile.setRequireImport (cyclomatic 21) code/core/src/csf-tools/ConfigFile.ts
  • Cyclomatic Complexity · ConfigFile.setImport (cyclomatic 21) code/core/src/csf-tools/ConfigFile.ts
  • Cyclomatic Complexity · forward-setup.collectArgsReads::visit (cyclomatic 21) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts
  • Cyclomatic Complexity · CsfObjectDiscovery.annotationCandidates (cyclomatic 20) code/core/src/csf-tools/CsfObjectDiscovery.ts
  • Cyclomatic Complexity · ConfigFile._removeImport (cyclomatic 20) code/core/src/csf-tools/ConfigFile.ts
  • Cyclomatic Complexity · useHighlighted.useHighlighted (cyclomatic 20) code/core/src/manager/components/sidebar/useHighlighted.ts
  • Cyclomatic Complexity · generateDocgen.initializerToDefaultValue (cyclomatic 19) code/frameworks/svelte-vite/src/plugins/generateDocgen.ts
  • Cyclomatic Complexity · find-implicit-spies.getAnnotationKeys (cyclomatic 19) code/lib/codemod/src/transforms/find-implicit-spies.ts
  • Cyclomatic Complexity · generateCodeSnippet.transformArgsSpreadsInJsx (cyclomatic 18) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cyclomatic Complexity · nodes.extractCompiledASTNodes (cyclomatic 18) code/renderers/svelte/src/svelte-csf/parser/extract/compiled/nodes.ts
  • Cyclomatic Complexity · server-only-stub.collectExports (cyclomatic 17) code/frameworks/tanstack-react/src/plugins/server-only-stub.ts
  • Cyclomatic Complexity · utils.resolveIdentifierInit (cyclomatic 16) code/core/src/csf-tools/story-shape/utils.ts
  • Cyclomatic Complexity · ContextMenu.useContextMenu (cyclomatic 16) code/core/src/manager/components/sidebar/ContextMenu.tsx
  • Cognitive Complexity · Tree.Node (cognitive 92) code/core/src/manager/components/sidebar/Tree.tsx
  • Cognitive Complexity · generateDocgen.generateDocgen (cognitive 87) code/frameworks/svelte-vite/src/plugins/generateDocgen.ts
  • Cognitive Complexity · CsfObjectEditor.group (cognitive 81) code/core/src/csf-tools/CsfObject.ts
  • Cognitive Complexity · ConfigObject.createConfigObject (cognitive 81) code/core/src/csf-tools/ConfigObject.ts
  • Cognitive Complexity · ConfigObject.createConfigObject::syncExports (cognitive 63) code/core/src/csf-tools/ConfigObject.ts
  • Cognitive Complexity · updateVitestFile.updateConfigFile (cognitive 56) code/addons/vitest/src/updateVitestFile.ts
  • Cognitive Complexity · CsfObjectEditor.readValue (cognitive 54) code/core/src/csf-tools/CsfObject.ts
  • Cognitive Complexity · update-args-in-csf-file.updateArgsInCsfFile (cognitive 54) code/core/src/core-server/utils/save-story/update-args-in-csf-file.ts
  • Cognitive Complexity · generateCodeSnippet.buildSnippetNode (cognitive 53) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cognitive Complexity · server-code-elimination.serverCodeElimination (cognitive 49) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts
  • Cognitive Complexity · ConfigFile.callArguments (cognitive 36) code/core/src/csf-tools/ConfigFile.ts
  • Cognitive Complexity · useExpanded.useExpanded (cognitive 32) code/core/src/manager/components/sidebar/useExpanded.ts
  • Cognitive Complexity · generateCodeSnippet.inlineArgsInJsx (cognitive 31) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cognitive Complexity · ConfigFile.setImport (cognitive 30) code/core/src/csf-tools/ConfigFile.ts
  • Cognitive Complexity · generateDocgen.convertType (cognitive 27) code/frameworks/svelte-vite/src/plugins/generateDocgen.ts
  • Cognitive Complexity · CsfObjectDiscovery.addAliasedBindings (cognitive 26) code/core/src/csf-tools/CsfObjectDiscovery.ts
  • Cognitive Complexity · ConfigFile.removeField (cognitive 23) code/core/src/csf-tools/ConfigFile.ts
  • Cognitive Complexity · server-code-elimination.removeDeadTopLevelDeclarations (cognitive 22) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts
  • Cognitive Complexity · metroConfig.statementContainsStorybookCall (cognitive 22) code/lib/create-storybook/src/generators/REACT_NATIVE/metroConfig.ts
  • Cognitive Complexity · generateCodeSnippet.transformArgsSpreadsInJsx (cognitive 22) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cognitive Complexity · forward-setup.collectArgsReads::visit (cognitive 22) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts
  • Cognitive Complexity · utils.resolveIdentifierInit (cognitive 20) code/core/src/csf-tools/story-shape/utils.ts
  • Cognitive Complexity · ConfigFile._removeImport (cognitive 20) code/core/src/csf-tools/ConfigFile.ts
  • Cognitive Complexity · useHighlighted.useHighlighted (cognitive 20) code/core/src/manager/components/sidebar/useHighlighted.ts
  • Cognitive Complexity · vitest-config-helpers.getTargetConfigObject (cognitive 19) code/core/src/babel/vitest-config-helpers.ts
  • Cognitive Complexity · CsfObjectEditor.move (cognitive 19) code/core/src/csf-tools/CsfObject.ts
  • Cognitive Complexity · CsfObjectDiscovery.annotationCandidates (cognitive 19) code/core/src/csf-tools/CsfObjectDiscovery.ts
  • Cognitive Complexity · find-implicit-spies.getAnnotationKeys (cognitive 18) code/lib/codemod/src/transforms/find-implicit-spies.ts
  • Cognitive Complexity · dangerfile.checkRequiredLabels (cognitive 18) scripts/dangerfile.ts
  • Cognitive Complexity · updateVitestFile.mergeProperties (cognitive 17) code/addons/vitest/src/updateVitestFile.ts
  • Cognitive Complexity · render.resolveRenderFunction (cognitive 17) code/core/src/csf-tools/story-shape/render.ts
  • Cognitive Complexity · CsfObjectDiscovery.discoverMeta (cognitive 17) code/core/src/csf-tools/CsfObjectDiscovery.ts
  • Cognitive Complexity · ConfigFile.setRequireImport (cognitive 17) code/core/src/csf-tools/ConfigFile.ts
  • Cognitive Complexity · ConfigFile._removeRequireImport (cognitive 17) code/core/src/csf-tools/ConfigFile.ts
  • Cognitive Complexity · generateDocgen.initializerToDefaultValue (cognitive 17) code/frameworks/svelte-vite/src/plugins/generateDocgen.ts
  • Cognitive Complexity · nodes.extractCompiledASTNodes (cognitive 17) code/renderers/svelte/src/svelte-csf/parser/extract/compiled/nodes.ts
  • Cognitive Complexity · imports.collectImportBindings (cognitive 16) code/core/src/csf-tools/story-shape/imports.ts
  • Cognitive Complexity · CsfObject.lookupProperty (cognitive 16) code/core/src/csf-tools/CsfObject.ts
  • Cognitive Complexity · ContextMenu.useContextMenu (cognitive 16) code/core/src/manager/components/sidebar/ContextMenu.tsx
  • Cognitive Complexity · AngularComponentMetaProject.extractViaModuleExports (cognitive 16) code/lib/angular-cm/src/project.ts
  • Cognitive Complexity · generateCodeSnippet.getArgsMemberKey (cognitive 16) code/renderers/react/src/componentManifest/generateCodeSnippet.ts
  • Cognitive Complexity · StorybookSvelteCSFError.storyNameFromAttribute (cognitive 16) code/renderers/svelte/src/svelte-csf/utils/error.ts
  • Cognitive Complexity · transform-template.collectArgsReferences (cognitive 16) code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts
  • Cognitive Complexity · arg-values.evaluate (cognitive 16) code/renderers/web-components/src/docgen/story-docs/arg-values.ts
  • God Classes · MethodTooLong: CsfFile.parse REDACTED
  • God Classes · FunctionTooLong: Tree.Node code/core/src/manager/components/sidebar/Tree.tsx
  • God Classes · FunctionTooLong: ConfigObject.createConfigObject code/core/src/csf-tools/ConfigObject.ts
  • God Classes · FunctionTooLong: updateVitestFile.wrapTestConfigAsProject code/addons/vitest/src/updateVitestFile.ts
  • God Classes · FunctionTooLong: generateDocgen.generateDocgen code/frameworks/svelte-vite/src/plugins/generateDocgen.ts
  • God Classes · FunctionTooLong: useExpanded.useExpanded code/core/src/manager/components/sidebar/useExpanded.ts
  • God Classes · MethodTooLong: CsfObjectEditor.group code/core/src/csf-tools/CsfObject.ts
  • God Classes · FunctionTooLong: component-transformer.collectComponentExports code/core/src/csf-tools/vitest-plugin/component-transformer.ts
  • God Classes · FunctionTooLong: forward-setup.readForwardableSetup code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts
  • God Classes · ClassTooLong: CsfObjectEditor code/core/src/csf-tools/CsfObject.ts
  • Coupling · Circular dependency
  • Coupling · Off the main sequence: @acme/ui
  • Test Reliability · Test reliability not measured — JavaScript/TypeScript suite install refused the lockfile
  • Dependency Hygiene · Floating npm dependency: @storybook/addon-docs
  • Dependency Hygiene · Floating npm dependency: @storybook/react
  • Dependency Hygiene · Floating npm dependency: @storybook/react-webpack5
  • Dependency Hygiene · One package at two majors across the workspace: next
  • Dependency Hygiene · One package at two majors across the workspace: react
  • Churn × Complexity Hotspots · Hotspot: code/frameworks/tanstack-react/src/routing/duplicate-tree.ts code/frameworks/tanstack-react/src/routing/duplicate-tree.ts
  • Churn × Complexity Hotspots · Hotspot: code/renderers/svelte/src/svelte-csf/parser/extract/compiled/nodes.ts code/renderers/svelte/src/svelte-csf/parser/extract/compiled/nodes.ts
  • Churn × Complexity Hotspots · Hotspot: code/renderers/vue3/src/docgen/component-docgen/arg-types/extractArgTypes.ts code/renderers/vue3/src/docgen/component-docgen/arg-types/extractArgTypes.ts
  • Churn × Complexity Hotspots · Hotspot: code/renderers/svelte/src/svelte-csf/parser/extract/svelte/module-nodes.ts code/renderers/svelte/src/svelte-csf/parser/extract/svelte/module-nodes.ts
  • Churn × Complexity Hotspots · Hotspot: code/core/src/controls/manager.tsx code/core/src/controls/manager.tsx
  • Churn × Complexity Hotspots · Repeated repair: code/core/src/cli/skills/content/build-stories-skill.ts code/core/src/cli/skills/content/build-stories-skill.ts
  • Churn × Complexity Hotspots · Repeated repair: code/core/src/cli/installSkills.ts code/core/src/cli/installSkills.ts
  • Explicit Debt · TodoComment code/addons/docs/src/blocks/blocks/external/ExternalPreview.ts
Rebuild cost: about €620,000 · Estimate
Cost to rebuild€210,000 to €1,000,000, for 3,438 to 10,905 hours of work, about 4.3 person-years for 2 to 9 engineers
Difficulty of the problemStandard, judged from the kind of software and how it is built. Code that solves a harder problem, such as payments or medical bookings, costs more per line to write.
Quality factor×0.7 at a score of 53. Better code takes more work to write, so the factor is ×1.0 at a score of 70, lower below it and higher above it.
SizeLarge: 392,689 lines of product code
What it is notNot a quotation: nobody has offered to build it for that. Not a valuation: it says nothing about what the business is worth. Not a certified figure: no professional has signed it as one.

How the estimate is made: Watchdog prices the hours a team would need to write this code again, at €60 to €95 an hour. Declarations and boilerplate are priced at a fast rate and logic at a slower one, and the logic is then multiplied by the difficulty of the problem and by the quality factor. The estimate can be about 30% off either way, and it moves most with the hourly rate and the difficulty. For this code, every line is priced as straight logic, which keeps the estimate on the low side.

Top priorities

The three actions that raise the score most for the work they take. The full ranked list is in the Roadmap.

1
Resolve the 7 Deprecated finding(s) in Dependency Hygiene — start with REDACTED (7).
Raises the score by about 3 points · Low effort · Dependency Hygiene
2
Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.
Raises the score by about 5 points · Medium effort · Dependency Hygiene
3
Resolve the 4 Test suite cannot be installed from its own lockfile finding(s) in Test Reliability.
Raises the score by about 2 points · Low effort · Test Reliability

Diagnosis: what the measurements show together

Each conclusion below combines several dimensions into one point that no single dimension shows, and lists the measurements it rests on.

Files that change often carry extra risk · Combined risk
36 files are changed often and are hard to read, which makes them the likeliest places for a mistake. They also have under half their code tested, or were written almost entirely by one person, so a mistake there is less likely to be caught, or only one person knows the code well enough to avoid it. A change to these files therefore carries more risk than the overall score suggests.
Based on: Churn × Complexity Hotspots (149 files) · Code Coverage (277 files under half tested) · Bus Factor (0 files written almost entirely by one person) · The files: REDACTED, ConfigFile.ts and stories.ts
What to do: Add tests to these files and have a second person review every change to them, starting with REDACTED, ConfigFile.ts and stories.ts.
Where the investment is most exposed · Value at risk
This code would cost about €620,000 to build again, about 4.3 person-years of work. Its weakest lens is Production Readiness, at 47 (Weak). Production Readiness is about whether the product is ready to run in production and to change without breaking. Because the weakest lens counts most in the score, work on Production Readiness also moves the score most.
Based on: the rebuild estimate · the Production Readiness grade · how much each lens counts
What to do: Start with the Production Readiness actions in Top priorities.
If you do one thing first · First action
Resolve the 7 Deprecated finding(s) in Dependency Hygiene. Of all the actions in this report, it raises the score most for the work it takes: about 3 points for low effort, because it clears the 7 Dependency Hygiene findings. The next survey will show the change in the score.
Based on: the ranked actions in Top priorities, by score gain and effort
What hard-to-read code costs each year · Cost
Four dimensions measure how easy the code is to work in: two measure how tangled its logic is, one how much of it is copied, and one how well each part sticks to a single job. In this codebase they average 6.5 out of 10. Code at that level is slower to change than clean code, and Watchdog estimates the extra work at 4% to 9% on every change. The history of the code shows how much it changes: about 512,914 lines over the last 90 days, which is about 2,080,151 lines a year. At that pace, the extra work comes to an estimated 198.9 to 1193.5 engineer-days a year, and it grows as more code changes.
How this is estimated: The number of changed lines is measured from the history of the code. The rest rests on two assumptions of Watchdog's own: code scoring 8 out of 10 or more adds no extra work, and each point below 8 adds 2.5% to 5.6% to every change, never less than 2% to 5% and never more than 40% to 60% in all; and an engineer changes 150 to 400 lines in a day. The result is a range for planning, not a measurement.
Based on: Cyclomatic Complexity · Cognitive Complexity · Cohesion (LCOM4) · the code's change history
What to do: Start with the files listed under Churn × Complexity Hotspots, which change often and are hard to read, because that is where the extra work is paid most often.

Architecture — module dependency graph

Project dependencies, layered top-to-bottom; arrows show direction. Any dashed red edge points upward or sideways, which only happens where the projects form a dependency cycle. A graph without cycles has none.

arch @storybook/addon-vitest addon-vitest @storybook/builder-vite builder-vite @storybook/addon-vitest->@storybook/builder-vite @storybook/react-vite react-vite @storybook/addon-vitest->@storybook/react-vite storybook storybook @storybook/addon-vitest->storybook @storybook/angular angular @storybook/builder-webpack5 builder-webpack5 @storybook/angular->@storybook/builder-webpack5 @storybook/core-webpack core-webpack @storybook/angular->@storybook/core-webpack @storybook/angular->storybook @storybook/angular-vite angular-vite @storybook/angular-vite->@storybook/builder-vite @storybook/angular-vite->storybook @storybook/builder-vite->storybook @storybook/builder-webpack5->@storybook/core-webpack @storybook/builder-webpack5->storybook @storybook/code code @storybook/code->@storybook/addon-vitest @storybook/code->@storybook/angular @storybook/code->@storybook/angular-vite @storybook/code->@storybook/builder-vite @storybook/code->@storybook/builder-webpack5 @storybook/codemod codemod @storybook/code->@storybook/codemod @storybook/code->@storybook/core-webpack @storybook/ember ember @storybook/code->@storybook/ember @storybook/html-vite html-vite @storybook/code->@storybook/html-vite @storybook/nextjs nextjs @storybook/code->@storybook/nextjs @storybook/preact-vite preact-vite @storybook/code->@storybook/preact-vite @storybook/preset-react-webpack preset-react-webpack @storybook/code->@storybook/preset-react-webpack @storybook/preset-server-webpack preset-server-webpack @storybook/code->@storybook/preset-server-webpack @storybook/react react @storybook/code->@storybook/react @storybook/code->@storybook/react-vite @storybook/react-webpack5 react-webpack5 @storybook/code->@storybook/react-webpack5 @storybook/server-webpack5 server-webpack5 @storybook/code->@storybook/server-webpack5 @storybook/code->storybook @storybook/codemod->@storybook/react @storybook/codemod->storybook @storybook/core-webpack->storybook @storybook/ember->@storybook/builder-webpack5 @storybook/ember->@storybook/core-webpack @storybook/ember->storybook @storybook/html-vite->@storybook/builder-vite @storybook/html-vite->storybook @storybook/nextjs->@storybook/builder-webpack5 @storybook/nextjs->@storybook/preset-react-webpack @storybook/nextjs->@storybook/react @storybook/nextjs->storybook @storybook/nextjs-vite nextjs-vite @storybook/nextjs-vite->@storybook/builder-vite @storybook/nextjs-vite->@storybook/react @storybook/nextjs-vite->@storybook/react-vite @storybook/nextjs-vite->storybook @storybook/preact-vite->@storybook/builder-vite @storybook/preact-vite->storybook @storybook/preset-react-webpack->@storybook/core-webpack @storybook/preset-react-webpack->storybook @storybook/preset-server-webpack->@storybook/core-webpack @storybook/preset-server-webpack->storybook @storybook/react->storybook @storybook/react-vite->@storybook/builder-vite @storybook/react-vite->@storybook/react @storybook/react-vite->storybook @storybook/react-webpack5->@storybook/builder-webpack5 @storybook/react-webpack5->@storybook/preset-react-webpack @storybook/react-webpack5->@storybook/react @storybook/server-webpack5->@storybook/builder-webpack5 @storybook/server-webpack5->@storybook/preset-server-webpack @storybook/server-webpack5->storybook storybook->@storybook/react-webpack5 __more__ +33 more projects

Architecture: which parts of the code depend on which

The code is divided into modules, groups of code that each handle one part of the product, and a module depends on another when it uses code from it. The table lists the modules both down the side and across the top, in an order where each module should only use modules listed above it. A number in a cell means the module on that row uses the module in that column, and it counts the pairs of building blocks (types) that connect them. The one thing to look for is a mark above the diagonal line. It means two or more modules use each other in a loop (a dependency cycle), so none of them can be changed, tested or released on its own.

1646 modules, with 1604 dependencies between them. 4 loops run through 12 of the modules, marked above the diagonal.

The table shows the 40 modules with the most connections; 1606 more are left out to keep it readable.

Which modules use which. The module on each row uses the module in each column, and the number counts the pairs of types that connect them. A cell above the diagonal is part of a loop.
uses →1 agent-eval.lib.agentic-reference2 agent-eval.lib.agentic-reference.comparison3 agent-eval.scripts.judge-ds-misuse4 code.addons.docs.src.blocks.components.ArgsTable.types5 code.core.src.channels.main6 code.core.src.common.js-package-manager.JsPackageManager7 code.core.src.components.components.typography.elements8 code.core.src.csf-tools.story-shape.imports9 code.core.src.instrumenter.types10 code.core.src.mocking-utils.esmWalker11 code.core.src.shared.status-store12 code.frameworks.angular-vite.template.cli.user13 code.frameworks.html-vite.template.cli.ts.Header14 code.lib.angular-cm.src.types15 code.lib.angular-compodoc.src.compodoc-types16 agent-eval.lib.agentic-reference.metrics17 code.core.src.component-meta.types18 code.core.src.csf-tools.estree.editor19 code.core.src.csf.story20 code.core.src.types.modules.core-common21 code.renderers.vue3.src.docgen.shared.render-primitives22 code.addons.docs.src.blocks.blocks23 code.addons.vitest.src24 code.core.src.csf-tools.CsfObject25 code.core.src.types.modules.addons26 code.core.src.types.modules.indexer27 code.renderers.svelte.src.docgen.story-docs28 code.core.src.core-server.utils29 code.core.src.csf-tools.ConfigFile30 code.core.src.csf-tools.CsfFile31 code.core.src.manager.components.sidebar32 code.core.src.preview-api.modules.store.StoryStore33 code.core.src.shared.open-service.services.docgen.types34 code.core.src.common.utils35 code.core.src.csf-tools36 code.core.src.csf-tools.story-shape37 code.frameworks.angular-vite.src.docgen38 code.lib.cli-storybook.src.automigrate.fixes39 code.renderers.react.src.componentManifest40 code.renderers.web-components.src.docgen.story-docs
1 agent-eval.lib.agentic-reference
2 agent-eval.lib.agentic-reference.comparison
3 agent-eval.scripts.judge-ds-misuse
4 code.addons.docs.src.blocks.components.ArgsTable.types
5 code.core.src.channels.main
6 code.core.src.common.js-package-manager.JsPackageManager
7 code.core.src.components.components.typography.elements
8 code.core.src.csf-tools.story-shape.imports
9 code.core.src.instrumenter.types
10 code.core.src.mocking-utils.esmWalker
11 code.core.src.shared.status-store
12 code.frameworks.angular-vite.template.cli.user
13 code.frameworks.html-vite.template.cli.ts.Header
14 code.lib.angular-cm.src.types
15 code.lib.angular-compodoc.src.compodoc-types
16 agent-eval.lib.agentic-reference.metrics5
17 code.core.src.component-meta.types1
18 code.core.src.csf-tools.estree.editor21
19 code.core.src.csf.story3
20 code.core.src.types.modules.core-common2
21 code.renderers.vue3.src.docgen.shared.render-primitives1
22 code.addons.docs.src.blocks.blocks2111
23 code.addons.vitest.src111121
24 code.core.src.csf-tools.CsfObject11
25 code.core.src.types.modules.addons2
26 code.core.src.types.modules.indexer2
27 code.renderers.svelte.src.docgen.story-docs213111
28 code.core.src.core-server.utils613193
29 code.core.src.csf-tools.ConfigFile115
30 code.core.src.csf-tools.CsfFile2221
31 code.core.src.manager.components.sidebar321
32 code.core.src.preview-api.modules.store.StoryStore2
33 code.core.src.shared.open-service.services.docgen.types1
34 code.core.src.common.utils8135321
35 code.core.src.csf-tools16351835
36 code.core.src.csf-tools.story-shape3633
37 code.frameworks.angular-vite.src.docgen113212
38 code.lib.cli-storybook.src.automigrate.fixes221223
39 code.renderers.react.src.componentManifest111
40 code.renderers.web-components.src.docgen.story-docs252
Uses a module listed above itPart of a loopThe module itself
1 agent-eval.lib.agentic-reference2 agent-eval.lib.agentic-reference.comparison3 agent-eval.scripts.judge-ds-misuse4 code.addons.docs.src.blocks.components.ArgsTable.types5 code.core.src.channels.main6 code.core.src.common.js-package-manager.JsPackageManager7 code.core.src.components.components.typography.elements8 code.core.src.csf-tools.story-shape.imports9 code.core.src.instrumenter.types10 code.core.src.mocking-utils.esmWalker11 code.core.src.shared.status-store12 code.frameworks.angular-vite.template.cli.user13 code.frameworks.html-vite.template.cli.ts.Header14 code.lib.angular-cm.src.types15 code.lib.angular-compodoc.src.compodoc-types16 agent-eval.lib.agentic-reference.metrics17 code.core.src.component-meta.types18 code.core.src.csf-tools.estree.editor19 code.core.src.csf.story20 code.core.src.types.modules.core-common21 code.renderers.vue3.src.docgen.shared.render-primitives22 code.addons.docs.src.blocks.blocks23 code.addons.vitest.src24 code.core.src.csf-tools.CsfObject25 code.core.src.types.modules.addons26 code.core.src.types.modules.indexer27 code.renderers.svelte.src.docgen.story-docs28 code.core.src.core-server.utils29 code.core.src.csf-tools.ConfigFile30 code.core.src.csf-tools.CsfFile31 code.core.src.manager.components.sidebar32 code.core.src.preview-api.modules.store.StoryStore33 code.core.src.shared.open-service.services.docgen.types34 code.core.src.common.utils35 code.core.src.csf-tools36 code.core.src.csf-tools.story-shape37 code.frameworks.angular-vite.src.docgen38 code.lib.cli-storybook.src.automigrate.fixes39 code.renderers.react.src.componentManifest40 code.renderers.web-components.src.docgen.story-docsagent-eval.lib.agentic-reference1agent-eval.lib.agentic-reference.comparison2agent-eval.scripts.judge-ds-misuse3code.addons.docs.src.blocks.components.ArgsTable.types4code.core.src.channels.main5code.core.src.common.js-package-manager.JsPackageManager6code.core.src.components.components.typography.elements7code.core.src.csf-tools.story-shape.imports8code.core.src.instrumenter.types9code.core.src.mocking-utils.esmWalker10code.core.src.shared.status-store11code.frameworks.angular-vite.template.cli.user12code.frameworks.html-vite.template.cli.ts.Header13code.lib.angular-cm.src.types14code.lib.angular-compodoc.src.compodoc-types15agent-eval.lib.agentic-reference.metrics16code.core.src.component-meta.types17code.core.src.csf-tools.estree.editor18code.core.src.csf.story19code.core.src.types.modules.core-common20code.renderers.vue3.src.docgen.shared.render-primitives21code.addons.docs.src.blocks.blocks22code.addons.vitest.src23code.core.src.csf-tools.CsfObject24code.core.src.types.modules.addons25code.core.src.types.modules.indexer26code.renderers.svelte.src.docgen.story-docs27code.core.src.core-server.utils28code.core.src.csf-tools.ConfigFile29code.core.src.csf-tools.CsfFile30code.core.src.manager.components.sidebar31code.core.src.preview-api.modules.store.StoryStore32code.core.src.shared.open-service.services.docgen.types33code.core.src.common.utils34code.core.src.csf-tools35code.core.src.csf-tools.story-shape36code.frameworks.angular-vite.src.docgen37code.lib.cli-storybook.src.automigrate.fixes38code.renderers.react.src.componentManifest39code.renderers.web-components.src.docgen.story-docs405121321211111112111222131116131931152221321218135321163518353633113212221223111252+1606 more modules (most-connected shown)

At a glance — Code Health · 65% · Adequate · gated by D2 ·

At a glance — Architecture · 60% · Adequate · gated by R9 ·

At a glance — Maturity · 75% · Strong ·

At a glance — Readiness · 47% · Weak · gated by R8, P7 ·

At a glance — Security · 60% · Adequate · gated by D28, D29, D30 ·

At a glance — Accessibility · 56% · Adequate ·

At a glance — Performance · 60% · Adequate ·

Security & Compliance — OWASP Top-10 mapping

Findings mapped to OWASP categories; the specific CVEs/secrets are in the Security dimension cards below and findings.md (redacted only on the public version of this report).

OWASP categoryFindingsSeverity
A03:2025 — Software Supply Chain Failures137High / Critical
A05:2025 — Injection99High / Critical
A07:2025 — Authentication Failures12High / Critical

Roadmap

First, clean up the dependency tree by removing unused packages, explicitly declaring imports, and moving type-only or test-only packages to devDependencies. Next, address the seven deprecated packages and resolve the four test suite installation issues to ensure a stable foundation. Then, fix the twenty-four empty tests to improve code coverage and reliability. Finally, harden outbound HTTP calls by adding timeouts, retries, and circuit breakers to prevent failures from cascading.

Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.

Do thisHelpsEffortDimension
Resolve the 7 Deprecated finding(s) in Dependency Hygiene — start with REDACTED (7).+2.7 ptsLowDependency Hygiene
Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.+5.2 ptsMediumDependency Hygiene
Resolve the 4 Test suite cannot be installed from its own lockfile finding(s) in Test Reliability.+2.3 ptsLowTest Reliability
Bound every outbound call: pass `signal: AbortSignal.timeout(ms)` to `fetch`, set `timeout` on the axios instance (`axios.create({ timeout })`), and add retries with back-off (`axios-retry`, `p-retry`) and a breaker (`opossum`, `cockatiel`) around dependencies that fail.+4.1 ptsMediumOutbound HTTP resilience
Resolve the 24 No assertions (empty test) finding(s) in Test Quality — start with csf-factories.test.ts (16), csf-factories.test.tsx (7), index.test.ts.+2.3 ptsMediumTest Quality
Resolve the 338 Low coverage finding(s) in Code Coverage — start with index.ts (20), preset.ts (7), REDACTED (7).+2.0 ptsHighCode Coverage
Resolve the 2 One package at two majors across the workspace finding(s) in Dependency Hygiene.+0.8 ptsLowDependency Hygiene
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.+1.1 ptsMediumKeyboard semantics

File quality

Per-file score 0–10 — a quality signature. Of 872 files carrying findings, judged against the Production bar: 0% slop · 46% mixed · 54% near-clean.

FileScoreBandWorst signal
REDACTED0.0SlopDependency Vulnerabilities: Critical CVE: REDACTED
code/renderers/react/src/csf-factories.test.tsx3.1SlopTest Quality: No assertions (empty test): Component type can be overridden
code/frameworks/angular-vite/src/client/csf-factories.test.ts3.3SlopTest Quality: No assertions (empty test): Component type can be overridden
code/frameworks/angular/src/client/csf-factories.test.ts3.3SlopTest Quality: No assertions (empty test): Component type can be overridden
REDACTED4.0MixedStatic Analysis (SAST): Medium: REDACTED
code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts4.0MixedCyclomatic Complexity: resolve-component.followExport (cyclomatic 24)
REDACTED4.0MixedStatic Analysis (SAST): Medium: REDACTED
REDACTED4.0MixedStatic Analysis (SAST): Medium: REDACTED
code/renderers/svelte/src/csf-factories.test.ts4.0MixedTest Quality: No assertions (empty test): snippet props are args
code/core/src/csf/csf-factories.test.ts4.1MixedTest Quality: No assertions (empty test): do not collapse preview types when used without factory addons
code/frameworks/sveltekit/src/csf-factories.test.ts4.2MixedTest Quality: No assertions (empty test): accepts mocks that return nothing, as the docs show
REDACTED4.2MixedStatic Analysis (SAST): High: REDACTED
REDACTED4.2MixedStatic Analysis (SAST): Medium: REDACTED
REDACTED4.9MixedStatic Analysis (SAST): Medium: REDACTED
code/renderers/web-components/src/csf-factories.test.ts5.0MixedTest Quality: No assertions (empty test): stories override meta args and infer callback parameters
code/renderers/vue3/src/csf-factories.test.ts5.0MixedTest Quality: No assertions (empty test): stories override meta args and infer callback parameters
REDACTED5.1MixedSecrets (history): REDACTED: REDACTED
code/lib/angular-cm/src/analyzer/type-index.ts5.1MixedCyclomatic Complexity: TypeIndex.render (cyclomatic 23)
REDACTED5.2MixedDependency Vulnerabilities: Medium CVE: REDACTED
REDACTED5.4MixedStatic Analysis (SAST): Medium: REDACTED

How the grades work

Every finding carries one of four grades. Three say how serious it is. The fourth says this survey could not settle it — and it is a grade, not a gap.

Critical — 213

A definite problem that already costs you something and drags the score down: a missing authorisation check, a dependency with a known exploit, a build that does not reproduce. Failure here tends to cause failures elsewhere.

Serious — 2582

Likely wrong, but not failing yet. It degrades the codebase over a longer horizon and can cause failures elsewhere — not urgent this week, not something to carry for two years either.

Minor — 521

Recorded, with no effect on how the codebase functions. Present so the survey is complete, not because it needs doing.

Could not be resolved — 7

Something this survey could not settle from the outside, and which could be critical or serious. Either a control was required and no positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean result. These are excluded from the score rather than awarded a pass, so the number on the cover neither rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each one is named under Limitations.

Methodology & how to trust this report

Watchdog is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. 88 of 88 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); none rely on LLM judgement. Overall confidence is 0.9 — the weighted average across measured dimensions; it falls as more of the score leans on LLM-assisted judgement and rises when it's fully tool-backed.

Every figure here is one of three kinds, and we label which: ✓ Measured — a deterministic fact (LoC, complexity, coverage); ~ Modeled — an estimate from a stated model (cost, effort, value-at-risk), always a range with its assumptions, never a precise fact; ◐ Advisory — an LLM prose judgement. We never present a modelled estimate as if it were measured. Perfect or absent scores carry their provenance too (ADR-0011): ✓ Tool-verified means the property itself was measured across the surface; ○ Nothing flagged means the probes came back clean — a claim bounded by what a repository can show; ⊘ Not evidenced means a working control (a tested restore, an automated rollback) showed no positive evidence — absence of evidence is not evidence of a control, so it's excluded from the score rather than awarded a spurious 10; ◐ Sampled · advisory marks an LLM verdict over a bounded sample — advisory, never a deterministic measurement.

What we checked — 88 dimensions across the health lenses
D1D2D3D5D6D8D9D10D11D12D13D14D15D16D17D19D20D23D26D28D29D30D34D35D36D37D43D44AC1AC2AC3AC4AC5AC6AC7AX10AX3AX4AX6AX8C2GD1IC1M1M2M3M4P1P10P2P3P4P6P7PF3R1R10R11R2R3R4R6R7R8R9S1X1X12X13X14X15X16X17X18X19X2X21X22X23X24X25X26X27X28X29X3X30X5

Each chip is a dimension scored from real signals across architecture, testing, dependencies, security & compliance, documentation, git-history and code quality — in one coherent pass. A surface report typically covers a handful.

How to trust any code-health report — three questions
  1. Can you open the finding? Real findings cite a repo-relative file and line you can open at the cited line — never an absolute scratch path. Here, 3151 of 3316 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line. (Every path in this report is repo-relative by construction: paths are normalized at the producer and the report is rejected if any rooted path leaks through.)
  2. Is there a tool behind the number? Every score below names the method that produced it — Roslyn, git, a scanner, or (for a handful of documentation/naming dimensions) an LLM labelled sampled · advisory — not a narrative.
  3. Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.

This report answers yes to all three. That's the bar to hold any assessment to.

Tools & methods

The actual versions used this run (captured at analysis time) — re-run on the same commit for the identical score.

MethodBacksVersionEvaluator
Roslyn static analysisComplexity, cohesion, coupling, dead code, API surface, layering5.3.0✓ deterministic
Native secret scannerHardcoded secrets / credentials1.0.0✓ deterministic
Watchdog duplication detector (in-process)Code duplication1.0.0✓ deterministic
Coverage (coverlet / dotnet-coverage)Line & branch coverage10.0.400✓ deterministic
NuGet / dotnetOutdated, vulnerable & deprecated dependencies10.0.400✓ deterministic
git / LibGit2SharpChurn hotspots, knowledge concentration, history2.43.0 · 0.31.0✓ deterministic
gitleaks · semgrep · trivySecrets in history, SAST, CVEs, IaC & container, PII / GDPR1.86.0 · 0.69.3✓ deterministic
LLM (sampled · advisory)Documentation quality, ADR conformance, naming — sampled over a bounded sample; advisory, never a deterministic measurement—◐ LLM · sampled · advisory

Every finding is locatable in findings.md. Run 01a17828-1045-7687-8f56-5f3cc7987208.

The exact command behind every deep-scan dimension — tool, version, invocation and retained raw output — is in Appendix B — Reproduction & audit trail.

Run transparency — what happened this run

What ran differently this time — a tool absent, degraded, or that fell back to an estimate. Named openly, not folded silently into the scores. A degraded run also records its exact cause in diagnostics.md.

  • D11 Test Reliability — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Test reliability for the vitest suite in the repository root was NOT MEASURED: the vitest run in the repository root produced no per-test report (⎯⎯⎯⎯⎯⎯⎯ Startup Error ⎯⎯⎯⎯⎯⎯⎯⎯). This is OUR limitation, not a defect in the repository, and the suite is excluded from the measurement rather than counted against it.
  • D11 Test Reliability — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Test reliability for the vitest suite in agent-eval/templates/reshaped-storybook/ was NOT MEASURED: the vitest run in agent-eval/templates/reshaped-storybook/ produced no per-test report (⎯⎯⎯⎯⎯⎯⎯ Startup Error ⎯⎯⎯⎯⎯⎯⎯⎯). This is OUR limitation, not a defect in the repository, and the suite is excluded from the measurement rather than counted against it.
  • D19 Documentation Quality — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Each ecosystem's manifests (what makes a folder runnable or a published package) need their own proof before D19 judges its units. Until then those folders' READMEs are judged only as documents (boilerplate, structure), never counted as complete.
  • D19 Documentation Quality — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This kind did not reach the 95 % precision gate in three adjudicated runs (docs/plans/deterministic-engine/adjudication/D19-sample3-v3.md), so by the pre-registered fallback it publishes no row until a re-measurement shows it does. The candidates are counted here, not reported as findings, and the score does not include them.
  • D21 Naming Consistency — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. D21's deterministic naming rules are gated on C# first (docs/plans/deterministic-engine.md, P5): each other language is switched on only after its own concept suite and A/B gate pass. Until then its declarations carry no naming verdict this run — this says nothing about whether its names are consistent.
  • D22 Internal API Consistency — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. D22's deterministic call-shape rules are gated on C# first (docs/plans/deterministic-engine.md, P5): each other language is switched on only after its own concept suite and A/B gate pass. This says nothing about whether that surface is consistent.
  • D24 Comment Value — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover the language this repository's product is written in, so it had nothing of the product to read. That is a gap in this analyzer's language reach — not a finding about this repository.
  • D27 Navigability — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Navigability is taken over call sites whose callee resolved. For C# that population includes calls into referenced assemblies; for this language only calls declared inside the repository count, so the abstention threshold reads the repository's use of its standard library as a resolution failure. That is a limit of this analyzer, not a build problem in this repository.
  • D32 Data Compliance (PII/GDPR) — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. `agent-eval/evals/803-edit-component/stories/ReviewCard.stories.tsx`, `agent-eval/evals/804-write-story-for-existing-component/stories/ReviewCard.stories.tsx`, `agent-eval/evals/805-non-visual-refactor/stories/ReviewCard.stories.tsx`, `agent-eval/evals/806-browse-request/stories/ReviewCard.stories.tsx`, `agent-eval/evals/807-docs-request/stories/ReviewCard.stories.tsx`, … (+302 more) produced a parse error, so every rule in this engine's `gdpr.yml` was absent there. That absence is NOT a clean result: these rules detect personal data crossing a boundary into a log sink, a URL or browser storage, and a file that was never parsed cannot report any of the three. The rest of the tree analysed normally and its rows above stand; only these files are unaccounted for. You can widen what we reach: fix the syntax error (or exclude the file deliberately) and re-scan to cover it.
  • AXR1 Runtime accessibility — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Render strategy: boot via DevServer (start). the dev server did not expose a crawlable HTTP endpoint in time — no runtime evidence.
  • IC1 Incompleteness & stubs — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 112 further occurrence(s) are not listed individually; the score already reflects all 152.
  • M4 Documentation accuracy — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. M4 checks only the claim kinds adjudicated at or above 95 % precision: links and versions (PREREGISTRATION version 9). Paths, command arguments, installs, environment variables, settings, projects, packages, routes, cd targets, infrastructure products and removed modules are read but not checked, and none of them is reported or counted.
  • P2 Observability — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 22 further occurrence(s) are not listed individually; the score already reflects all 62.
  • PF3 Async & latency hygiene — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 37 further occurrence(s) are not listed individually; the score already reflects all 77.
  • R10 Code Duplication — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 442 further occurrence(s) are not listed individually; the score already reflects all 482.
  • R11 Import Boundaries — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 155 further occurrence(s) are not listed individually; the score already reflects all 195.
  • R3 Large Files — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 88 further occurrence(s) are not listed individually; the score already reflects all 128.
  • R4 Test Coverage — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 297 further occurrence(s) are not listed individually; the score already reflects all 337.
  • R7 Dead Code — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 271 further occurrence(s) are not listed individually; the score already reflects all 311.
  • X24 Document value interpolated into markup unescaped — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 3 further occurrence(s) are not listed individually; the score already reflects all 43.
  • X3 Exception handling — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 111 further occurrence(s) are not listed individually; the score already reflects all 151.
  • X4 Structured logging — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, Kotlin, Python, PHP, Dart, Ruby, Scala and Rust source only, and no C# was loaded, and this repository's JavaScript/TypeScript, Python and PHP log through no library that carries a message's values as fields (pino, winston, bunyan, tslog, LogTape, roarr; Python's logging, structlog; PHP's PSR-3 loggers), so its log calls cannot be judged, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.

Repo exclusion declarations: 34 pattern(s) declared (.gitattributes linguist-generated/vendored, .editorconfig generated_code) excluded 0 source file(s) from code-quality scoring. Declarations are the repo's own visible statement that a tree is machine-written or vendored — auditable in any diff, honored by GitHub the same way.

Limitations & what we did not check

Watchdog assesses the repository exactly as committed, and only the repository. By design it does not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.

Per-dimension blind spots

For each dimension that was measured, what a static, repo-only scan structurally cannot see — the honest edge of the measurement, not a failure of it.

  • D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
  • D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
  • D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
  • D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
  • D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
  • D8 Code Coverage: Coverage is measured by building and running the test suite inside Watchdog's isolated image — the target repo is never modified, and nothing on your systems runs. So coverage exists only when the suite builds and runs within the inline time budget; one that needs external services, can't build, or exceeds the budget yields no coverage (D8 then degrades to not-measured, not a low score). Line coverage also says nothing about assertion quality.
  • D9 Test Distribution: The test-pyramid shape is inferred from project/folder naming and references, with a single test host bucketed per-file by its path tier and content signals — a suite that names tiers unconventionally and gives no per-file signal can still be mis-bucketed.
  • D10 Test Quality: Assertion density is structural — it cannot tell a meaningful behavioural assertion from a trivial one, only that an assertion is present.
  • D11 Test Reliability: Flakiness is inferred from history/markers — Watchdog runs the suite once (for coverage), not the repeated runs under varied conditions that reveal nondeterminism, so a flaky test never recorded as failing is invisible here.
  • D12 Dependency Hygiene: Dependency health reads manifests and lockfiles — a vulnerability in a vendored/copied dependency, or risk from how a dependency is actually used, is outside this view.
  • D13 REDACTED Scanning: REDACTED detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
  • D14 License Compliance: License compatibility is checked against declared package metadata and a policy — mislabelled or missing license metadata, and obligations that depend on how you distribute, are not resolved here.
  • D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
  • D16 Bus Factor: Bus-factor is a time-decayed model of commit attribution (who has recently, repeatedly worked a file), not comprehension — pairing, review and reading-without-committing spread knowledge it can't see; bot commits and shared accounts still distort it.
  • D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
  • D19 Documentation Quality: Documentation quality publishes two things only: a runnable or packaged unit with no example, and a multi-project root README that maps none of its parts. It does not judge clarity, and its other checks (overview, licence, boilerplate, structure, empty sections, XML-doc coverage) are withheld after adjudication: their candidates are counted in the card's gaps, not shown as rows. A false statement in a document is M4's; units are .NET projects only.
  • D20 ADR Quality: ADR quality is an LLM read of the decision records present — it cannot know about decisions made and never recorded, and its verdict is sampled and advisory.
  • D23 Boundary Type-Coupling: Boundary leakage is detected from type references across detected contexts — leaks that flow through primitives, serialization or shared infrastructure may not surface as a typed reference.
  • D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
  • D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
  • D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
  • D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
  • D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
  • D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
  • D43 Malicious Dependencies: Only packages some vulnerability database has already NAMED as malicious are seen — a compromise published in the last hours, or never reported at all, is invisible here, and this dimension reading 10 is not evidence that a dependency is trustworthy. There is no typosquat or dependency-confusion analysis: a package nobody has reported is simply absent from the feeds. Coverage is the dependency scan's: an ecosystem that could not be scanned is disclosed as unmeasured, never as clean.
  • D44 Platform End-of-Life: The support table is FROZEN, so it goes out of date by losing RECALL: a release that ended support after the table was written is missed until the table is refreshed, and this dimension reading 10 is not evidence that a platform is current. Only platforms the repository DECLARES in a place this pass reads are seen — a runtime named only in a Dockerfile (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (go.mod, a Gemfile ruby directive) is invisible here, which is why a repository declaring none of them abstains rather than scoring. Only frameworks with a PUBLISHED support policy are tracked: React, Flask and Express publish none, so their age cannot be judged and their absence from a report is not a statement that they are supported.
  • AC1 Text alternatives: Alt-text is detected structurally — the scan sees that an alternative EXISTS, not whether it meaningfully describes the image, and decorative-vs-missing is judged by attribute shape; runtime-injected images and a non-role=img decorative svg are out of scope. This is accessibility readiness, never a WCAG conformance claim.
  • AC2 Forms & labels: Label association is read from static markup — a label wired up at runtime (JS-set aria-labelledby, framework-injected ids) reads as missing, a present label says nothing about whether its text is correct. A known UI-library field component (e.g. a JSX <TextField>) is now checked conservatively — flagged only when it carries NO label/aria-label/aria-labelledby/id/name — but wrapper/context-labelled libraries (Chakra/Radix FormControl+FormLabel) aren't statically visible (possible false positive) and non-JSX lowercased components are still skipped. A click handler on a plain element is now asked for a name too (it is a control the author declared), but the subtree test that answers it is deliberately generous: any DYNAMIC text expression in the subtree counts as a name, so an icon chosen by a ternary ({cond ? <IconA/> : <IconB/>}) reads as named, and a glyph component from a library the icon-import list does not know still names its parent. A clean result is "no unlabelled control found", not a labelling proof.
  • AC3 Page structure: Page structure is read from the static markup tree — landmarks, headings and lang injected at runtime aren't seen, heading ORDER is checked structurally (not against the rendered visual hierarchy), and lang/title/main fire only on full documents, never partials, and the data-table check sees header-cell presence (a <th> exists), not whether each header correctly associates with its cells. Static readiness, not conformance.
  • AC4 Keyboard semantics: Keyboard semantics are inferred from markup attributes — interactivity wired purely in script, focus managed at runtime, and component-level handlers are invisible. A clean result means "no static keyboard-trap shape", not a keyboard-operability proof.
  • AC5 ARIA correctness: ARIA correctness is checked against the static role/attribute shape — roles/attributes set dynamically aren't seen, a valid role says nothing about whether it matches the element's real behaviour, and required-state checks are suppressed when a JSX spread could supply them. The two-branch toggle check (a control whose state is conveyed only by which of two mutually exclusive branches renders) reads CONDITIONALS THAT ARE ATTRIBUTES — Vue v-if/v-else/v-show and Alpine x-if/x-show — so the same toggle written as a Svelte {#if} block or a JSX ternary is control flow the markup model never projects as a branch and is not seen at all.
  • AC6 Visual & motion safety: Contrast and motion safety are PARTIAL by construction — literal colours (hex/rgb/hsl/named) in inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS top-level declarations are read (same-rule/same-element colour+background pairs only); computed/runtime/theme colour, external-CDN stylesheets, CSS-in-JS dynamic (${…}) and nested-selector colours, cross-element pairs and image contrast stay out of reach, so a clean result is bounded by what the static CSS itself shows.
  • AC7 A11y enforcement: Enforcement is scored from in-repo config/CI evidence only — an a11y gate enforced in external tooling with no in-repo trace can't be credited, and a configured linter is presence, not proof the rules actually run or block a merge.
  • AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
  • M4 Documentation accuracy: Onboarding quality is an LLM read of the docs/setup present — it cannot run the onboarding or measure how long a real new joiner takes; the verdict is sampled and advisory.
  • P4 Deployment & Rollback: Approval/branch-protection rules live in repository settings the scan cannot see — only their in-repo evidence (config files, workflows) is checked, so a control enforced purely in the host's settings reads as "not evidenced".
  • P6 Release Hygiene: Rollback/observability controls are inferred from repo artefacts (pipelines, dashboards-as-code) — controls configured in external tooling, with no in-repo trace, cannot be credited.

Dimensions

D1 · Cyclomatic Complexity5.8 / 10Adequate✓ Tool-verified

What it measures: How tangled the control flow is — methods with many branches are hard to test and change.

Method: Cyclomatic complexity per method (1 + decision points), computed exhaustively across production source; test projects separated by convention. Deterministic.

Maturity: Documented → Verified → Prevented · effective 5.8 / 10 · rule-coverage 100% · ceiling Prevented

289 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was Tree.Tree at 85. A further 5 method(s) were over the threshold but excluded as flat dispatchers (a long switch/match over independent cases: many branches, almost no nesting), the largest being story-to-csf-factory.isExpressionPosition at 30 — they are counted neither in the figure above nor in this dimension's score. 2 files carry no cyclomatic complexity row at all for this reason — every one of their over-threshold methods was excluded, so the exclusion is disclosed nowhere in the file itself: code/core/src/component-testing/components/MethodCall.tsx (MethodCall.Node at 16), code/frameworks/svelte-vite/src/plugins/svelte-docgen.ts (svelte-docgen.transformToSvelteDocParserType at 16). They are named here because the per-file figures other dimensions report are taken BEFORE this exclusion, so such a file can show a high maximum complexity elsewhere in this report and nothing here, with nothing to reconcile the two.

buildAccessibilityTree::nameOf (cyclomatic 30) · ×2agent-eval/lib/mcp/claude-browser-mock.mjs:955
Tree.Tree (cyclomatic 85)code/core/src/manager/components/sidebar/Tree.tsx:118
scope.analyzeScopes.visitNode (cyclomatic 81)code/core/src/csf-tools/estree/scope.ts:569
Select.Select (cyclomatic 81)code/core/src/components/components/Select/Select.tsx:205
story-to-csf-factory.storyToCsfFactory (cyclomatic 79)code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.ts:83

+ 277 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Bring the 8 bodies over 60 down to 60 or less in Cyclomatic Complexity — start with Tree.Tree (cyclomatic 85), scope.analyzeScopes.visitNode (cyclomatic 81), Select.Select (cyclomatic 81). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 8 together lifts Cyclomatic Complexity from 5.8 to about 6.3/10, projected with the scoring formula itself and assuming each lands exactly at 60; a cleaner split scores higher.
  2. Enforce Cyclomatic Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d1_recommendation.md · top locations in Appendix A, every location in findings.md.

D2 · Cognitive Complexity3.6 / 10Weak✓ Tool-verified

What it measures: How hard the code is for a person to follow, beyond raw branching.

Method: Cognitive complexity per method (Sonar-style nesting-penalized score), computed exhaustively over production code, excluding test projects. Deterministic.

Maturity: Documented → Verified → Prevented · effective 3.6 / 10 · rule-coverage 100% · ceiling Prevented

395 method(s) exceeded the cognitive complexity threshold of 15; the worst was html-report.buildEffects at 193.

buildAccessibilityTree::visit (cognitive 40) · ×2agent-eval/lib/mcp/claude-browser-mock.mjs:1031
ComponentMetaManager.findMatchTSConfig::getReferencesChains (cognitive 25) · ×2code/core/src/component-meta/ComponentMetaManager.ts:240
app-router-provider.AppRouterProvider (cognitive 20) · ×2code/frameworks/nextjs-vite/src/routing/app-router-provider.tsx:72
extract-arg-types.extractArgTypesFromData (cognitive 20) · ×2code/lib/angular-cm/src/extract-arg-types.ts:460
actualNameHandler.actualNameHandler (cognitive 18) · ×2code/renderers/react/src/componentManifest/reactDocgen/actualNameHandler.ts:17

+ 377 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Bring the 2 bodies over 120 down to 120 or less in Cognitive Complexity — start with html-report.buildEffects (cognitive 193), CsfFile._visitExportNamed (cognitive 133). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 2 together lifts Cognitive Complexity from 3.6 to about 4.4/10, projected with the scoring formula itself and assuming each lands exactly at 120; a cleaner split scores higher.
  2. Enforce Cognitive Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.

D3 · God Classes8.8 / 10Strong✓ Tool-verified

What it measures: Over-large classes that try to do too much ("god classes").

Method: God-class detection by line and method-count thresholds per logical type (partial classes unified), filtered for generated code and registration/contract false positives. Deterministic.

Maturity: Documented → Verified → Prevented · effective 8.8 / 10 · rule-coverage 100% · ceiling Prevented

116 god class(es) detected.

FunctionTooLong: scope.analyzeScopes · ×75code/core/src/csf-tools/estree/scope.ts:293
FileTooLong: comparison/html-report.ts · ×26agent-eval/lib/agentic-reference/comparison/html-report.ts
MethodTooLong: StoryRender.render · ×7code/core/src/preview-api/modules/preview-web/render/StoryRender.ts:185
ClassTooLong: checklistData · ×5code/core/src/shared/checklist-store/checklistData.tsx:1
TooManyMethods: JsPackageManager · ×3code/core/src/common/js-package-manager/JsPackageManager.ts:106

What to do

  1. Resolve the 75 FunctionTooLong finding(s) in God Classes — start with index.ts (5), scope.ts (2), definition.ts (2). — One of this dimension's main actionable groups (75 warning-level).
  2. Resolve the 26 FileTooLong finding(s) in God Classes — start with html-report.ts, claude-browser-mock.mjs, collect-pr-data.ts. — One of this dimension's main actionable groups (26 warning-level).
  3. Resolve the 7 MethodTooLong finding(s) in God Classes — start with instrumenter.ts (2), StoryRender.ts, REDACTED. — One of this dimension's main actionable groups (7 warning-level).
  4. Enforce God Classes in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.

D5 · Coupling6.8 / 10Adequate✓ Tool-verified

What it measures: Whether volatile projects sit underneath others that depend on them (so their churn ripples upward), and whether project dependencies form cycles. A widely-depended-on but stable shared/kernel project is healthy, not penalised.

Method: Dependency cycles via elementary-DFS over real .csproj references, plus Martin instability (afferent/efferent) per project. Exhaustive over the reference graph, deterministic.

Coverage: Exhaustive · type-level: afferent/efferent coupling + cycles computed over every production type — the population is all types, not a name convention.

Maturity: Documented → Verified → Prevented · effective 6.8 / 10 · rule-coverage 100% · ceiling Prevented

53 production modules (npm), 1 dependency cycle(s), 0 unstable depended-on module(s). Read from the build's own module declarations; 6 module(s) off the main sequence, with abstractness counted on 49 of the 53 (the rest declare no modelled class or interface, export only macros, declare types in source no model reads, or have no source directory of their own).

Circular dependencycode/builders/builder-webpack5/package.json:82
Off the main sequence: eslint-plugin-storybook · ×6

What to do

  1. Resolve the 6 Off the main sequence finding(s) in Coupling. — One of this dimension's main actionable groups (6 warning-level).
  2. Resolve the 1 Circular dependency finding(s) in Coupling — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  3. Enforce Coupling in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d5_recommendation.md · top locations in Appendix A, every location in findings.md.

D6 · Cohesion (LCOM4)10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether a class's methods are focused on a single responsibility.

Method: LCOM4 cohesion per production class with at least two methods: connected components of methods sharing state or calls, computed syntactically. Deterministic, not a proxy.

Coverage: Exhaustive · type-level: LCOM4 cohesion computed over every production class — the population is all types, not a name convention.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Verified

0 of 103 classes have LCOM4 above 3.

✓ On the Gold path — maintain.

Detailed fixes: d6_recommendation.md.

D8 · Code Coverage8.2 / 10Strong✓ Tool-verified

What it measures: How much of the code is actually exercised by tests.

Method: Coverage from coverlet runs or committed reports (Cobertura/OpenCover/lcov), computed per-file with structured exclusions for generated, trivial, and glue code. When the suite can't be built/run in-image AND no report is committed, coverage is reported NOT-MEASURED (excluded from the score) with the precondition to make it measurable — never a LoC-ratio proxy folded in as if measured. Deterministic.

Maturity: Documented → Verified → Prevented · effective 8.2 / 10 · rule-coverage 100% · ceiling Verified

Line coverage 45.6% — 338 file(s) below 50%. Measured from the JavaScript/TypeScript suite (vitest + @vitest/coverage-v8 via `yarn install --immutable --mode=skip-build` in agent-eval/; vitest in agent-eval/templates/monorepo/: not run; vitest in agent-eval/templates/reshaped-storybook/: not run; vitest in agent-eval/templates/vite-app/: not run; vitest + @vitest/coverage-v8 via `yarn install --immutable --mode=skip-build` in code/; vitest + @vitest/coverage-v8 via `yarn install --immutable --mode=skip-build` in code/addons/vitest/; vitest + @vitest/coverage-v8 via `yarn install --immutable --mode=skip-build` in scripts/; jest in test-storybooks/portable-stories-kitchen-sink/nextjs/: not run; vitest in test-storybooks/portable-stories-kitchen-sink/react/: not run).

Low coverage: agent-eval/lib/templates.ts · ×338agent-eval/lib/templates.ts:1

What to do

  1. Resolve the 338 Low coverage finding(s) in Code Coverage — start with index.ts (20), preset.ts (7), REDACTED (7). — One of this dimension's main actionable groups (338 warning-level).
  2. Enforce Code Coverage in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.

Detailed fixes: d8_recommendation.md · top locations in Appendix A, every location in findings.md.

D9 · Test Distribution9.9 / 10Exemplary✓ Tool-verified

What it measures: Whether the test suite has a healthy mix of unit / integration / end-to-end tests.

Method: Test projects classified (Unit/Integration/BDD/E2E) from compiled metadata; test methods counted exhaustively across projects with placement-agnostic disk fallback. Deterministic.

Maturity: Documented → Verified → Prevented · effective 9.9 / 10 · rule-coverage 100% · ceiling Documented

12713 test methods: 12659 unit, 0 integration, 0 BDD, 54 e2e. The JavaScript/TypeScript suite contributes 12713 `it`/`test` case(s) across 1077 test file(s) declaring at least one; its tier split is read from package names and paths only.

✓ On the Gold path — maintain.

Detailed fixes: d9_recommendation.md.

D10 · Test Quality9.4 / 10Adequategated by 24 critical findings✓ Tool-verified

What it measures: Whether the tests truly assert behaviour rather than just running the code.

Method: Per-test assertions, skips, and mock references analyzed via Roslyn; structured skip-reason tags (BUG:/ENV:) separate documented deferrals from debt. Deterministic.

Maturity: Documented → Verified → Prevented · effective 9.4 / 10 · rule-coverage 100% · ceiling Prevented

140 skipped (34 with a documented reason), 346 zero-assertion, 1 synchronised by a fixed sleep, no mocking-framework packages referenced (hand-written doubles or no mocking) across 12713 tests (1 harness-style project(s) excluded from the assertion penalty).

No assertions (empty test): stories override meta args and infer callback parameters · ×24code/renderers/web-components/src/csf-factories.test.ts:381
No assertions: ✅ All required args may be provided in meta · ×307code/renderers/web-components/src/csf-factories.test.ts:96
Skipped test: renders with loaders and play function · ×106test-storybooks/portable-stories-kitchen-sink/vue3/stories/Button.cy.tsx:19
Fixed-sleep synchronisation: waits for each preset import to settle before importing the next, so CJS presets can require() ESM entriescode/core/src/common/presets.test.ts:805
Mock-dominated test: should handle DocumentFragment stories · ×121code/renderers/web-components/src/docs/sourceDecorator.test.ts:85

+ 3 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 24 No assertions (empty test) finding(s) in Test Quality — start with csf-factories.test.ts (16), csf-factories.test.tsx (7), index.test.ts. — One of this dimension's main actionable groups (24 issue-level).
  2. Resolve the 307 No assertions finding(s) in Test Quality — start with csf-factories.test.ts (177), csf-factories.test.tsx (37), public-types.test.ts (32). — One of this dimension's main actionable groups (307 warning-level).
  3. Resolve the 106 Skipped test finding(s) in Test Quality — start with component-testing.spec.ts (12), addon-mcp.spec.ts (11), addon-docs.spec.ts (9). — One of this dimension's main actionable groups (106 warning-level).
  4. Enforce Test Quality in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d10_recommendation.md · top locations in Appendix A, every location in findings.md.

D11 · Test Reliability10.0 / 10Adequategated by 4 critical findings✓ Tool-verified

What it measures: Whether the tests pass reliably, with no flakiness.

Method: Suite re-run N times within tiered wall-clock budgets (unit to e2e); tests failing non-deterministically across runs flagged; guarded tests retried when #if guards detected.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Verified

0 flaky across 1 measured tier(s). JavaScript/TypeScript (vitest via `yarn install --immutable --mode=skip-build` in the repository root; vitest via `yarn install --immutable --mode=skip-build` in agent-eval/ (1225 tests); vitest via `yarn install --immutable --mode=skip-build` in agent-eval/templates/monorepo/ (0 tests); vitest via `yarn install --immutable --mode=skip-build` in agent-eval/templates/reshaped-storybook/; vitest via `yarn install --immutable --mode=skip-build` in agent-eval/templates/vite-app/ (0 tests); vitest via `yarn install --immutable --mode=skip-build` in code/ (3605 tests); vitest via `yarn install --immutable --mode=skip-build` in code/addons/vitest/ (256 tests); vitest via `yarn install --immutable --mode=skip-build` in scripts/ (236 tests); vitest via `yarn install --immutable --mode=skip-build` in test-storybooks/mcp/; jest via `yarn install --immutable --mode=skip-build` in test-storybooks/portable-stories-kitchen-sink/nextjs/; vitest via `yarn install --immutable --mode=skip-build` in test-storybooks/portable-stories-kitchen-sink/react/; vitest via `yarn install --immutable --mode=skip-build` in test-storybooks/portable-stories-kitchen-sink/svelte/): measured (0 flaky).

Test suite cannot be installed from its own lockfile: test-storybooks/mcp/ · ×4

What to do

  1. Resolve the 4 Test suite cannot be installed from its own lockfile finding(s) in Test Reliability. — One of this dimension's main actionable groups (4 issue-level).

Detailed fixes: d11_recommendation.md · top locations in Appendix A, every location in findings.md.

D12 · Dependency Hygiene4.8 4.7 / 10Weak✓ Tool-verified

What it measures: Whether dependencies are current, secure, and not bloated.

Method: Manifest scan via dotnet list package across all projects; worst-signal-per-package deduction (saturating for vulnerabilities, capped-linear for deprecation/outdated) per KLoC. Exhaustive, deterministic.

Maturity: Documented → Verified → Prevented · effective 4.7 / 10 · rule-coverage 100% · ceiling Verified

136 outdated direct production npm dependency(ies) of 208 graded, 3 pinning defect(s), across 70 REDACTED (63 of them the product) and 13 committed lockfile(s). 208 of 209 resolved direct production dependency(ies) were graded against registry.npmjs.org (1 not published there — private or renamed). Development dependencies are deliberately not graded for currency: that grade is about what SHIPS. 5 direct dependency(ies) — production, development or optional — are marked DEPRECATED by their publisher (the registry's per-version mark, or the lockfile's copy of it when the registry could not be asked); deprecated transitive packages are listed but not charged. Whether any is UNMAINTAINED is not graded — the registry publishes no maintenance status, and release age does not stand in for one. Whether any is UNUSED is not graded either: that is a source question, and the frontend dependency lens (R8) answers it in this same run. Known CVEs in this dependency graph are D30's question, read from the manifest there.

Deprecated: @types/prettier · ×7REDACTED:331
One package at two majors across the workspace: magic-string · ×2
Floating npm dependency: vite
Deprecated: @babel/plugin-proposal-class-properties · ×40REDACTED:1137
Outdated (npm): @google-cloud/bigquery · ×11scripts/package.json:52

+ 1 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 7 Deprecated finding(s) in Dependency Hygiene — start with REDACTED (7). — One of this dimension's main actionable groups (7 warning-level).
  2. Resolve the 2 One package at two majors across the workspace finding(s) in Dependency Hygiene. — One of this dimension's main actionable groups (2 warning-level).
  3. Resolve the 1 Floating npm dependency finding(s) in Dependency Hygiene. — One of this dimension's main actionable groups (1 warning-level).
  4. Enforce Dependency Hygiene in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.

Detailed fixes: d12_recommendation.md · top locations in Appendix A, every location in findings.md.

D13 · REDACTED Scanning10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether any secrets (keys, tokens, passwords) have leaked into the code.

Method: In-process native secret scanner (entropy plus signature patterns) across all tracked files; no external tool. A clean result is a measured 10, not no-data zero. Deterministic.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Prevented

REDACTED scan ran and found no leaked secrets.

✓ On the Gold path — maintain.

Detailed fixes: d13_recommendation.md.

D14 · License Compliance10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether the licenses of third-party packages are compatible with your policy.

Method: Third-party package licenses resolved from declared package metadata and checked against the configured policy (allow/deny/copyleft). Deterministic; clean = no incompatible license found at metadata depth.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Verified

0 of 208 shipped npm package(s) use a banned license. Licences were resolved from registry.npmjs.org over the 209 production dependency(ies) this repository's committed lockfile resolves, across 63 product REDACTED manifest(s). Its 730 `devDependencies` declaration(s) are excluded: a consumer installs none of them. ★ DEPTH: this is the DIRECT production set the lockfile resolves, NOT the transitive closure — only one of the four lock dialects this pass reads states a full graph, so a banned licence pulled in only by a dependency's OWN dependencies is outside this verdict, exactly as the JVM arm's declaration-site verdict is. ★ Each licence is the one the registry publishes for the package's CURRENT release rather than for the pinned version, which is the same caveat the Hex and RubyGems arms carry. 1 of them publish no licence this pass can read on registry.npmjs.org — an absent field, `UNLICENSED`, or a `SEE LICENSE IN <file>` pointer into a tarball this pass does not download; that is missing data, not a violation, and none of them is charged. A further 1 package(s) the lockfile resolves are not published on the public registry at all — a private scope, a workspace-internal name or a git install — and are outside this verdict. This repository publishes itself under MIT, which is its own choice and is not judged here.

✓ On the Gold path — maintain.

Detailed fixes: d14_recommendation.md.

D15 · Churn × Complexity Hotspots9.8 / 10Stronggated by 162 serious findings✓ Tool-verified

What it measures: Files that change often and are also complex — the riskiest hotspots.

Method: Per production file churn times cyclomatic complexity over a rolling window, computed from git and Roslyn/JS/Razor analysis. Exhaustive, deterministic per commit date.

Maturity: Documented → Verified → Prevented · effective 9.8 / 10 · rule-coverage 100% · ceiling Documented

Top hotspots: code/core/src/csf-tools/CsfObject.ts (86×46=3956); code/core/src/manager/components/sidebar/Tree.tsx (45×85=3825); REDACTED (50×57=2850) Repeated repair below the complexity floor: code/lib/cli-storybook/src/codemod/helpers/custom-args-type.ts (12 of 20 changes were fixes); code/renderers/react/src/preview.tsx (11 of 19 changes were fixes); code/renderers/web-components/src/preview.ts (11 of 17 changes were fixes)

Hotspot: code/core/src/csf-tools/CsfObject.ts · ×128code/core/src/csf-tools/CsfObject.ts:692
Repeated repair: code/lib/cli-storybook/src/codemod/helpers/custom-args-type.ts · ×34code/lib/cli-storybook/src/codemod/helpers/custom-args-type.ts:15

What to do

  1. Resolve the 128 Hotspot finding(s) in Churn × Complexity Hotspots — start with build-story-docs.ts (3), stories.ts (2), preset.ts (2). — One of this dimension's main actionable groups (128 warning-level).
  2. Resolve the 34 Repeated repair finding(s) in Churn × Complexity Hotspots — start with REDACTED (4), custom-args-type.ts, preview.tsx. — One of this dimension's main actionable groups (34 warning-level).

Detailed fixes: d15_recommendation.md · top locations in Appendix A, every location in findings.md.

D16 · Bus Factor8.4 / 10Strong✓ Tool-verified

What it measures: Whether knowledge is concentrated in too few people (the "bus factor").

Method: Living knowledge per author via time-decayed commit attribution (6-month half-life, focus weighting) across largest source files. Deterministic, avoids blame's mechanical-refactor false positives.

Maturity: Documented → Verified → Prevented · effective 8.4 / 10 · rule-coverage 100% · ceiling Documented

199 source file(s) have their living knowledge concentrated in one author (≥90% of recent, decayed contribution). The largest is agent-eval/lib/agentic-reference/comparison/html-report.ts. Counted over 1237 of the 4164 production source files in this repository: 2917 are under the ~2,400-byte size floor this dimension measures over, and the remaining 10 have no attributable history left to measure.

Off-boarding risk: anonymized user #1 · ×9
Further sole-owners (lower concentration)

What to do

  1. Resolve the 9 Off-boarding risk finding(s) in Bus Factor. — One of this dimension's main actionable groups (9 recommendation-level).
  2. Resolve the 1 Further sole-owners (lower concentration) finding(s) in Bus Factor. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d16_recommendation.md · top locations in Appendix A, every location in findings.md.

D17 · Explicit Debt9.9 / 10Stronggated by 208 serious findings✓ Tool-verified

What it measures: Acknowledged debt left in the code — TODOs, dead code, suppressed warnings.

Method: Roslyn syntactic debt markers (suppressions/TODO/FIXME/HACK/empty-catch/commented-code/Obsolete) plus SymbolFinder dead-code analysis; weighted-debt-per-KLoC density deducted 2.0x per unit. Deterministic, exhaustive.

Maturity: Documented → Verified → Prevented · effective 9.9 / 10 · rule-coverage 100% · ceiling Prevented

208 deducted task-comment markers across 316946 LoC (0.1/KLoC) → score 9.9. Task comments only: this repository's language is read without a compiler, so D17's suppression, dead-code and commented-out-code arms did not run and this score counts fewer marker kinds than a .NET repository's would.

TodoComment · ×180test-storybooks/portable-stories-kitchen-sink/vue3/.storybook/preview.ts:6
FixmeComment · ×21scripts/sandbox/generate.ts:595
HackComment · ×7test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:581

What to do

  1. Resolve the 180 TodoComment finding(s) in Explicit Debt — start with index.ts (12), console.ts (10), compodoc.test.ts (7). — One of this dimension's main actionable groups (180 warning-level).
  2. Resolve the 21 FixmeComment finding(s) in Explicit Debt — start with tool-taxonomy.test.ts (2), generate.ts, parameters.ts. — One of this dimension's main actionable groups (21 warning-level).
  3. Resolve the 7 HackComment finding(s) in Explicit Debt — start with component-testing.spec.ts (4), mdx.tsx (2), stories.test.ts. — One of this dimension's main actionable groups (7 warning-level).
  4. Enforce Explicit Debt in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.

Detailed fixes: d17_recommendation.md · top locations in Appendix A, every location in findings.md.

D19 · Documentation Quality10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether the project's documentation is clear, complete, and useful.

Method: Every README, docs/ document and root guide parsed by its markup and measured in Unicode letters. Published: a runnable or packaged .NET project whose README (or a document it links, or a root guide) shows no example, and a root README naming none of three or more projects. Overview, licence, boilerplate, wall-of-text, empty-section and XML-doc rows are measured and withheld (counted in gaps) after adjudication. Deterministic, exhaustive, advisory.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

1 of 1 documentation facets pass in full. 985 document(s) read across 1 unit(s).

✓ On the Gold path — maintain.

Detailed fixes: d19_recommendation.md.

D20 · ADR Quality0.0 / 10Critical✓ Tool-verified

What it measures: Whether architecture decisions are recorded well (context, decision, consequences).

Method: Per-ADR judgment by language model at low temperature with two-pass stability; confidence is share of ADRs evaluated; enforcement-field presence detected deterministically. Advisory.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

No architecture decision records were found.

No ADRs found

What to do

  1. Resolve the 1 No ADRs found finding(s) in ADR Quality. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d20_recommendation.md · top locations in Appendix A, every location in findings.md.

D23 · Boundary Type-Coupling9.5 / 10Stronggated by 91 serious findings✓ Tool-verified

What it measures: Whether domain types (IDs, enums, value objects) leak across bounded-context boundaries.

Method: Cross-context domain-type leakage via Roslyn structural classification (strongly-typed IDs / value objects) over every public surface. Exhaustive, deterministic, type-level aggregate-boundary check.

Coverage: Bounded contexts derived from NAMESPACE prefix (or graph-inferred where available); cross-boundary domain-type leakage then checked exhaustively over every public member of every type.

Maturity: Documented → Verified → Prevented · effective 9.5 / 10 · rule-coverage 100% · ceiling Verified

91 domain type(s) cross context boundaries across 50 contexts.

Cross-context type ProjectType (core → create-storybook) · ×12code/lib/create-storybook/src/services/TelemetryService.ts:59
Cross-context type SupportedBuilder (core → create-storybook) · ×11code/lib/create-storybook/src/generators/types.ts:32
Cross-context type Type (svelte → angular-vite) · ×6code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts:160
Cross-context type Type (svelte → angular) · ×6code/frameworks/angular/src/client/angular-beta/utils/NgComponentAnalyzer.ts:160
Cross-context type SupportedFramework (core → create-storybook) · ×6code/lib/create-storybook/src/generators/types.ts:82

+ 27 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 12 Cross-context type ProjectType (core → create-storybook) finding(s) in Boundary Type-Coupling — start with TelemetryService.ts (2), ProjectTypeService.ts (2), FrameworkDetectionCommand.ts (2). — One of this dimension's main actionable groups (12 warning-level).
  2. Resolve the 11 Cross-context type SupportedBuilder (core → create-storybook) finding(s) in Boundary Type-Coupling — start with types.ts (5), AddonService.ts (2), FeatureCompatibilityService.ts. — One of this dimension's main actionable groups (11 warning-level).
  3. Resolve the 6 Cross-context type Type (svelte → angular-vite) finding(s) in Boundary Type-Coupling — start with NgComponentAnalyzer.ts (2), ComputesTemplateFromComponent.ts (2), StorybookWrapperComponent.ts. — One of this dimension's main actionable groups (6 warning-level).
  4. Enforce Boundary Type-Coupling in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.

Detailed fixes: d23_recommendation.md · top locations in Appendix A, every location in findings.md.

D26 · Project Cohesion7.8 / 10Strong✓ Tool-verified

What it measures: Whether each project is a focused, coherent unit rather than an oversized grab-bag.

Method: Project size overshoot penalties (LoC / public-type count / namespace count, 2-of-3 flag) weighted by log magnitude. Exhaustive across projects, deterministic, LLM-independent.

Maturity: Documented → Verified → Prevented · effective 7.8 / 10 · rule-coverage 100% · ceiling Documented

10 of 86 build units (npm) flagged as possibly oversized/incoherent.

Projects may be oversized for their cohesion

What to do

  1. Resolve the 1 Projects may be oversized for their cohesion finding(s) in Project Cohesion. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d26_recommendation.md · top locations in Appendix A, every location in findings.md.

D28 · Secrets (history)0.0 / 10Critical✓ Tool-verified

What it measures: Whether any secrets were ever committed — scanned across the full git history, not just now.

Method: REDACTED scan via TWO gitleaks detect passes in an isolated checkout — the full git history, then a second --no-git pass over the working tree as it stands — merged and de-duplicated by (rule, file, line); each match flagged High. Both invocations are recorded in the audit trail. Exhaustive; when the tool is absent, or when its output cannot be parsed into the expected shape, the dimension is WITHHELD as an explicit measurement gap on our side — unscored and excluded from the lens, never a hedged middling score.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

11 finding(s): 0 critical, 11 high, 0 medium, 0 low. Remediation for historically-committed secrets is credential rotation — they remain in history regardless of later deletion.

REDACTED
REDACTED
REDACTED

What to do

  1. Resolve the 8 REDACTED finding(s) in Secrets (history) — start with REDACTED (3), REDACTED (2), REDACTED. — One of this dimension's main actionable groups (8 issue-level).
  2. Resolve the 3 High secret finding(s) in Secrets (history) — start with REDACTED, REDACTED, REDACTED. — One of this dimension's main actionable groups (3 issue-level).
  3. Resolve the 1 Rotate the exposed credentials finding(s) in Secrets (history). — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d28_recommendation.md · top locations in Appendix A, every location in findings.md.

D29 · Static Analysis (SAST)0.0 / 10Critical✓ Tool-verified

What it measures: Real static-analysis (SAST) findings — likely security bugs in the code, any language.

Method: Polyglot static analysis via semgrep across the repo using the pinned, image-baked p/security-audit + p/owasp-top-ten rulesets (no scan-time registry fetch); severity rules (ERROR/WARNING/INFO) map to a full-band severity-weighted score. Exhaustive, deterministic; degrades on parse failure.

Coverage: semgrep pattern rules over all files — exhaustive for the rule set, blind to classes of bug without a rule (clean = no rule matched).

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

99 finding(s): 0 critical, 11 high, 77 medium, 11 low. semgrep hit a parse error in 548 file(s) — `.github/scripts/update-canary-pr-body-from-run.test.ts`, `agent-eval/evals/803-edit-component/stories/ReviewCard.stories.tsx` (line 12), `agent-eval/evals/804-write-story-for-existing-component/stories/ReviewCard.stories.tsx` (line 12), `agent-eval/evals/805-non-visual-refactor/stories/ReviewCard.stories.tsx` (line 12), `agent-eval/evals/806-browse-request/stories/ReviewCard.stories.tsx` (line 12), … (+543 more) — so no absence of findings in the named regions is evidence of anything; rows reported elsewhere in those files are real. Fix the syntax error (or exclude the file deliberately) and re-scan to cover them. Separately, one or more rules could not re-parse an embedded snippet in 2 file(s) (e.g. a workflow `run:` block read as shell). Those files WERE scanned and their other rows are unaffected; only those rules' view of those snippets is missing.

REDACTED
REDACTED
REDACTED
REDACTED
REDACTED

+ 15 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 2 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (2). — One of this dimension's main actionable groups (2 issue-level).
  2. Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
  3. Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).

Detailed fixes: d29_recommendation.md · top locations in Appendix A, every location in findings.md.

D30 · Dependency Vulnerabilities0.0 / 10Critical✓ Tool-verified

What it measures: Whether any dependency has a known published vulnerability (CVE), direct or transitive, in ANY ecosystem the repository declares — Dart pub, Elixir and Erlang via Hex, Go modules, Java and Kotlin via Maven/Gradle, JavaScript/npm, .NET/NuGet, PHP/Composer, Python/PyPI, RubyGems, Rust/Cargo and Swift.

Method: Dependency-CVE scan across every ecosystem the repository declares, scored ONCE. Three sources are unioned and deduplicated by advisory identity (rule id + alias closure, CVE<->GHSA) scoped to package+version, keeping the worst severity: `osv-scanner --recursive` over osv.dev for Dart pub, Elixir/Hex (and Erlang, whose `rebar.lock` syft first converts to a CycloneDX SBOM the scanner reads, with rows attributed back to the lock), Go, Java and Kotlin via Maven/Gradle (and Scala, whose sbt build's pinned direct declarations are written into a CycloneDX SBOM the scanner reads, with rows attributed back to the build file), npm, PHP/Composer, Python/PyPI, RubyGems, Rust/Cargo and Swift; `trivy fs --scanners vuln` for npm lockfiles; and `dotnet list package --vulnerable --include-transitive` for NuGet (with per-advisory collapse of the project x target-framework fan-out), plus a DECLARED-dependency arm that resolves a published gem's gemspec against rubygems.org where no Gemfile.lock is committed. `SeverityScore(c,h,m,l, normalizer 8.0)`. NotApplicable only when NO ecosystem is readable; if any applicable ecosystem could not be scanned the findings are REPORTED and the score is withheld. Supersedes the npm and OSV arms, retired 2026-09-05.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Documented

134 finding(s): 19 critical, 74 high, 35 medium, 6 low.

REDACTED
REDACTED
REDACTED
REDACTED
REDACTED

+ 1 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 73 High CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (73). — One of this dimension's main actionable groups (73 issue-level).
  2. Resolve the 16 Critical CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (16). — One of this dimension's main actionable groups (16 issue-level).
  3. Resolve the 3 Critical vulnerability finding(s) in Dependency Vulnerabilities — start with REDACTED (2), REDACTED. — One of this dimension's main actionable groups (3 issue-level).

Detailed fixes: d30_recommendation.md · top locations in Appendix A, every location in findings.md.

D34 · Knowledge Freshness9.8 / 10Exemplary✓ Tool-verified

What it measures: Whether anyone still has living knowledge of each file, or it has been orphaned — last understood long ago by someone now gone quiet. The sibling of the bus factor: D16 asks who owns it, D34 asks whether anyone still knows it.

Method: File orphaning as total living-knowledge decay below one focused-commit's worth within a year, computed per-file from the D16 decay model. Exhaustive, deterministic over fixed history.

Maturity: Documented → Verified → Prevented · effective 9.8 / 10 · rule-coverage 100% · ceiling Documented

22 of 1247 significant source file(s) are orphaned — their living knowledge has decayed to nothing, so no one currently understands them. The largest is code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts. Counted over 1247 of the 4164 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.

Orphaned file · ×22code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts:1
Orphaned files with no living knowledge

✓ On the Gold path — maintain.

Detailed fixes: d34_recommendation.md · top locations in Appendix A, every location in findings.md.

D35 · Change Coupling9.9 / 10Stronggated by 4 serious findings✓ Tool-verified

What it measures: Whether files that change together actually belong together — pairs that repeatedly co-change in git history despite having no explicit code dependency, surfacing the hidden/logical coupling (and boundaries in the wrong place) a static scan can't see.

Method: Pairwise co-occurrence over the per-commit file sets in git history (production source only — tests and generated dropped): Degree-of-Coupling = shared ÷ min individual revisions, reported above noise floors (each file ≥10 revisions, ≥5 shared commits, ≥50% strength); sweeping commits excluded. Deterministic over fixed history.

Coverage: Population: PRODUCTION source files only — test and generated files are dropped before pairing, so a class co-changing with its own test (trivially ~100%) can't drown the real production↔production coupling. Pairs ranked by Degree-of-Coupling. A non-source file is never a coupling PARTICIPANT either: documentation, schemas, config and data files are dropped with the rest, so a code↔docs pair — a command and the reference page that restates it — is not reported however strongly the two co-change; nor is coupling that runs THROUGH a build step or config file.

Maturity: Documented → Verified → Prevented · effective 9.9 / 10 · rule-coverage 100% · ceiling Documented

Strongest change-coupling: REDACTED↔REDACTED 100%; REDACTED↔REDACTED 100%; EVAL.ts↔test-utils.ts 100%

Change coupling: FinalizationCommand.ts ↔ FeatureCompatibilityService.ts · ×2code/lib/create-storybook/src/commands/FinalizationCommand.ts:1
Change coupling clique: REDACTED, REDACTED, preview.tsx, REDACTED, REDACTEDcode/frameworks/angular-vite/src/client/preview.ts
Change-coupling hub: test-utils.ts → EVAL.ts, EVAL.ts, EVAL.ts, EVAL.ts, EVAL.ts, EVAL.tsagent-eval/lib/test-utils.ts

What to do

  1. Resolve the 2 Change coupling finding(s) in Change Coupling — start with FinalizationCommand.ts, EVAL.ts. — One of this dimension's main actionable groups (2 warning-level).
  2. Resolve the 1 Change coupling clique finding(s) in Change Coupling — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 Change-coupling hub finding(s) in Change Coupling — start with test-utils.ts. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d35_recommendation.md · top locations in Appendix A, every location in findings.md.

D36 · Supply-chain Provenance & Signing7.5 / 10Strong✓ Tool-verified

What it measures: Whether the build pipeline provides supply-chain integrity — generated provenance/attestation, signed artifacts (cosign/sigstore), an SBOM, and pinned build actions. Presence of the configuration, not a runtime guarantee.

Method: Supply-chain provenance/signing read deterministically from CI/build config (.github/workflows, .gitlab-ci.yml, azure-pipelines, Jenkinsfile, .circleci) + the release surface: four signals — generated provenance/attestation (SLSA/in-toto/actions-attest), artifact signing (cosign/sigstore/gitsign), an SBOM (syft/sbom-action/*.spdx.json/*.cdx.json), and SHA-pinned build actions — scored 10·present/denom. NotApplicable without a build pipeline. Detects configuration presence, not runtime enforcement.

Maturity: Documented → Verified → Prevented · effective 7.5 / 10 · rule-coverage 100% · ceiling Documented

3/4 supply-chain integrity signals present (provenance, signing, SBOM, pinned actions).

REDACTED
REDACTED
REDACTED

What to do

  1. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
  2. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
  3. Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 recommendation-level).

Detailed fixes: d36_recommendation.md · top locations in Appendix A, every location in findings.md.

D37 · Vulnerability-disclosure Policy10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether the repository publishes a coordinated-vulnerability-disclosure policy (SECURITY.md or security.txt) with a reporting contact, so finders know how to report a vulnerability. Presence of a policy file with a contact, not whether the policy is adequate or honoured.

Method: Vulnerability-disclosure policy read deterministically from the repo: a SECURITY.md (root/.github/docs) or .well-known/security.txt / security.txt, regex-checked for a reporting contact (email / URL / mailto). Present + contact → 10; present without a contact → 4; NotApplicable when no policy file exists (it may live off-repo). Detects the policy file's presence + contact, not its adequacy.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

A vulnerability-disclosure policy (SECURITY.md) is published with a reporting contact.

✓ On the Gold path — maintain.

Detailed fixes: d37_recommendation.md.

D43 · Malicious Dependencies10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether any dependency the repository declares is published as MALICIOUS rather than merely vulnerable — a package that is an attacker's work, in any ecosystem osv-scanner reads. Scored apart from D30 because the answer is binary: there is no safe version to upgrade to, and the fix is to remove the package and rotate every credential it could have read.

Method: The same dependency scan D30 reads, partitioned on the scanner's own classification rather than rescanned: a row is MALICIOUS when its id is in the `MAL-` space (the ossf/malicious-packages feed) OR its `database_specific.cwe_ids` carries `CWE-506` ("Embedded Malicious Code"). Both channels are structural; the summary text is deliberately NOT read, because a malicious-package record whose summary says only "Critical severity vulnerability" is a real shape ([GHSA redacted]) and a text matcher misses it. Scored BINARY: any surviving row is 0, whatever its severity and however many CVEs sit beside it — a hostile dependency is not a quantity. Applicability and degradation are D30's: NotApplicable only when no ecosystem is readable, and an unscannable ecosystem degrades rather than reading clean. SCORED, not informational.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

No dependency in any ecosystem this repository declares is published as malicious.

✓ On the Gold path — maintain.

Detailed fixes: d43_recommendation.md.

D44 · Platform End-of-Life10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether anyone still ships security patches for the platform this repository RUNS ON — the runtime it pins and the framework majors its own constraints hold it to. Separate from D12 because the question differs: a current Django on an end-of-life Python is perfectly up to date and completely unsupported, and the fix is a migration rather than a version bump. What the repository says it merely SUPPORTS is never charged.

Method: End-of-life PLATFORM read from the repository's own declarations and graded against a FROZEN, dated table of vendor support dates — no network, no feed, no API, so this dimension answers identically inside a closed scan fence. Two subjects: a RUNTIME the project pins (a single or all-end-of-life TargetFramework, a .nvmrc or .python-version, a requires-python CAP) and a FRAMEWORK major a dependency constraint cannot move off (a caret, tilde or exact version; `vue@^2.7.16` pins Vue 2). A FLOOR is deliberately never charged — `requires-python = ">=3.8"` states what a package SUPPORTS, not what it runs on — and a multi-target project is charged only when EVERY target is out of support. Runtime 4.0/product capped 8.0, framework 1.5 capped 4.5. The table is safe to freeze because a statement about support that ended in the past cannot become false: it loses recall as it ages, never precision, and a test asserts every entry predates the freeze date. Disjoint from D31 (a container image's OS layer) and D29 (the toolchain a CI workflow installs). Abstains when the repository declares no platform this pass reads — never scores it clean.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

0 end-of-life runtime(s) and 0 end-of-life framework(s), read from 1 platform declaration(s) and 0 dependency declaration(s). This dimension reads what the repository says about ITSELF — a pinned target framework, a version file, a capped requires-python, a Rust toolchain pin, a framework major a constraint cannot move off. A FLOOR is deliberately never charged: `requires-python = ">=3.8"` states what the package SUPPORTS, not what it runs on, and a well-maintained library declares exactly that while running its own CI on a current release. The end-of-life facts are FROZEN and dated, so this dimension needs no network and answers identically inside a closed scan fence; as the table ages it loses recall and never precision, because a statement about support that ended in the past cannot become false. The OS layer of a container image is D31's question and the toolchain a CI workflow installs is D29's; this row is neither.

✓ On the Gold path — maintain.

Detailed fixes: d44_recommendation.md.

Frontend & cross-cutting dimensions

R = React/JS · M = Maturity · P = Readiness.

AC1 · Text alternatives5.5 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether non-text content carries a text alternative — img/area/input[type=image] have alt, a meaningful svg has a title or aria-label, video has a captions track, and object/embed/canvas have a name or fallback content. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: every img/area/input[type=image] checked for alt, svg[role=img] for a title/aria-label, video for a captions <track>. Components skipped, spreads suppressed. Deterministic, hard fact per element.

Coverage: Population: image/media elements — img, area, input[type=image], svg, video, object, embed, canvas — across the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx); components, hidden subtrees and dynamic-attribute elements are skipped. Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is NOT read by any producer, so it contributes no element to this population; where such a frontend is present the card discloses it as an analyzer gap rather than scoring around it.

  • An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative. (×2) — code/frameworks/angular-vite/template/stories/argTypes/doc-button/doc-button.component.html:2, code/frameworks/angular/template/stories/argTypes/doc-button/doc-button.component.html:2

What to do

  • Add a text alternative — alt on images (alt="" for purely decorative ones), a title or aria-label on meaningful svg, an aria-label or inner fallback content on canvas, and a captions <track> on video.
AC2 · Forms & labels6.1 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether form controls have a programmatic label (an associated label, aria-label or aria-labelledby), buttons have text, links have an accessible name, a click handler on a plain element names the control it declares, fieldsets have a non-empty legend, known UI-library field components carry a label prop, and a placeholder isn't used as the only label. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: inputs/selects/textareas checked for an associated label[for]/wrapping label/aria-label/aria-labelledby (per document), buttons for accessible text, fieldsets for a legend; placeholder-only labelling flagged. Deterministic, hard fact per control.

Coverage: Population: form controls, buttons, links, fieldsets and known UI-library field components in the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx); components, hidden subtrees and spread/dynamic-attribute elements are skipped, so a control whose label arrives through a spread or a runtime expression is deliberately not judged. Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.

  • This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed. (×8) — code/addons/a11y/src/components/VisionSimulator.tsx:52, code/addons/pseudo-states/src/manager/PseudoStateTool.tsx:28, code/addons/themes/src/theme-switcher.tsx:94, …
  • A link with no text, aria-label or labelled child (e.g. an icon-only link) has no accessible name, so assistive tech can't say where it goes. Add visible text or an aria-label. (×3) — code/addons/docs/src/blocks/blocks/mdx.tsx:216, code/addons/docs/src/blocks/components/Toolbar.tsx:152, code/core/src/manager/components/sidebar/Menu.tsx:188
  • This control has no associated label. Add a <label htmlFor> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it. (×2) — code/addons/docs/src/blocks/controls/react-editable-json-tree/index.tsx:150, code/addons/docs/src/blocks/controls/react-editable-json-tree/index.tsx:151
  • An <optgroup> groups <option>s but has no label, so assistive tech announces the group with no name. Add a label attribute. — code/core/src/components/components/Form/Select.tsx:136
  • This UI-library field component is named only by a placeholder — a placeholder is not a label (it vanishes as soon as the user types, and many assistive technologies ignore it). Give it a real name whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed. — code/core/src/manager/settings/shortcuts.tsx:334
  • A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one). (×6) — code/frameworks/svelte-vite/template/cli/js/Header.svelte:42, code/frameworks/svelte-vite/template/cli/ts/Header.svelte:40, code/frameworks/sveltekit/template/cli/js/Header.svelte:42, …
  • This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it. (×5) — code/lib/docgen-harness/src/svelte/__testfixtures__/runes-omit-rest-class/Input.svelte:38, code/lib/docgen-harness/src/vue3/__testfixtures__/model-with-runtime-emits/ModelWithRuntimeEmits.vue:10, code/lib/docgen-harness/src/vue3/__testfixtures__/v-model/VModelInput.vue:21, …

What to do

  • Give every control a programmatic label (a <label for> / wrapping <label> / aria-label) and every button text — a placeholder is not a label.
AC3 · Page structure7.0 / 10Strong✓ Tool-verified

Other · Accessibility — Whether pages declare a language (well-formed BCP-47) and a non-empty title, expose exactly one main landmark and a sane heading order with non-empty headings, keep zoom enabled, title their iframes, give data tables header cells, and avoid meta-refresh. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: html lang, document <title>, a main landmark and heading order on full documents only, plus zoom-disabling viewports, untitled iframes and meta-refresh anywhere. Deterministic, per structural checkpoint.

Coverage: Population: the PARSED MARKUP documents (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx). The page-level checks — lang, title, single main landmark — fire ONCE PER FULL DOCUMENT (an <html> root) and never on a partial or component fragment, so a repo of fragments is assessed only on the per-element checks (heading order, table headers, iframe titles, meta-refresh, zoom). Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.

  • The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en"). — code/addons/mcp/src/template.html:2
  • A page with no <title> gives no name in the tab, history or screen-reader page list. Add a descriptive <title> in <head>. — code/addons/mcp/src/template.html:2
  • No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>. (×3) — code/addons/mcp/src/template.html:2, code/builders/builder-webpack5/templates/preview.ejs:2, code/core/assets/server/template.ejs:2
  • An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative. — code/core/assets/server/base-preview-body.html:86

What to do

  • Declare <html lang>, a document <title> and a <main> landmark, keep headings in order, leave zoom enabled, title iframes and drop meta-refresh.
AC4 · Keyboard semantics4.0 / 10Weak✓ Tool-verified

Other · Accessibility — Whether interactive behaviour is keyboard-reachable — no click handler on a non-interactive element lacking a role, tabindex and key handler, no element the repo's own CSS styles `cursor: pointer` without giving it any of the three, no unfocusable element whose only binding is a mouse enter/leave pair or a double-click, no positive tabindex, no href-less anchor, no placeholder-href (#/javascript) link acting as a button. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: click handlers on non-interactive elements lacking role+tabindex+key handler, positive tabindex values, and href-less anchors. Components skipped, spreads suppressed. Deterministic, hard fact per element.

Coverage: Population: elements that pose a keyboard-semantics question, in the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx) — a non-natively-interactive element carrying a click handler, a double-click or hover enter/leave binding, a pointer-only gesture on a tabindex="0" element, or `cursor: pointer` from the repo's own CSS; an href-less or placeholder-href (#, javascript:) anchor; and any element with a positive tabindex. Natively interactive elements used correctly (<button>, <a href>, form controls) are NOT in the population — there is nothing to judge — so a page of nothing but correct controls gives AC4 nothing to measure. Keyboard reachability is judged from the markup, never from a rendered page. ★ An interactive element declared in a tagged-template (html`…`) or hyperscript frontend is NOT in this population — no producer reads either — so an empty population is reported as an analyzer gap, never as "this repository has no interactive elements".

  • A click handler on a plain element isn't keyboard-operable. Use a <button>, or add role + tabIndex={0} + a key handler. (×2) — code/addons/docs/src/blocks/controls/react-editable-json-tree/JsonNodes.tsx:639, code/addons/docs/src/blocks/controls/react-editable-json-tree/JsonNodes.tsx:1502

What to do

  • Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.
AC5 · ARIA correctness6.5 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether ARIA is used correctly — valid non-abstract roles, the ARIA state a role requires, valid (non-misspelled) aria-* attribute names, in-enum values for token-typed aria-* attributes, and no aria-hidden on (or wrapping) a focusable element. Static markup readiness, not a WCAG conformance claim.

Method: Static markup-model scan: role values checked against the WAI-ARIA role set (abstract/invalid flagged), required ARIA state for a role, and aria-hidden on a focusable element. Deterministic, role/attribute level.

Coverage: Population: elements in the PARSED MARKUP files (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx) that carry a role or an aria-* attribute; roles and token values are checked against the ARIA enums exhaustively within that set. An expression-valued (dynamic) role or aria-* value is skipped rather than guessed, and markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.

  • aria-hidden="true" here hides the subtree from assistive tech, but a focusable descendant stays in the tab order — a keyboard user can land on a control screen readers can't see. Add inert, take the descendants out of the tab order (tabindex="-1"), or drop aria-hidden. — code/core/assets/server/base-preview-body.html:17

What to do

  • Use valid, non-abstract roles, supply the ARIA state each role requires, and never put aria-hidden on a focusable element.
AC6 · Visual & motion safety6.8 / 10Adequate✓ Tool-verified

Other · Accessibility — Whether focus outlines aren't removed without a replacement, motion respects prefers-reduced-motion, and literal CSS colour pairs meet contrast — PARTIAL: inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS literals are read (hex/rgb/hsl/named), never computed/runtime/external-CDN colour. Static markup readiness, not a WCAG conformance claim.

Method: Static markup/CSS scan: inline outline:none/0, literal inline colour/background contrast against the 4.5:1 AA floor, and <style>-block animation without a prefers-reduced-motion guard. Deterministic but PARTIAL — only inline styles and in-repo CSS literals are visible.

Coverage: Population: styled elements in the PARSED MARKUP files (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx), plus in-repo <style> blocks, in-repo .css files and CSS-in-JS literals. Colour contrast is computed from LITERAL colour pairs only (hex/rgb/hsl/named, including var() tokens and Tailwind neutral utilities) — computed, runtime-themed and external-CDN colour is never resolved, so this is a partial read of contrast by construction. Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.

  • `.sb-loader` moves (`animation: sb-rotate360 0.7s linear infinite`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce. — code/core/assets/server/base-preview-head.html:288
  • `.storybook-button--primary` sets color: white on background-color: #1ea7fd — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. (×4) — test-storybooks/portable-stories-kitchen-sink/vue3/stories/button.css:10, test-storybooks/portable-stories-kitchen-sink/svelte/stories/button.css:10, test-storybooks/portable-stories-kitchen-sink/react/stories/button.css:10, …
  • `button` sets color: white on background-color: #1ea7fd — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them. — code/addons/pseudo-states/src/stories/nested.css:1
  • `.button` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. (×2) — code/renderers/svelte/src/svelte-csf/__tests__/stories/Example.svelte:28, code/renderers/svelte/src/sample/MockButton.svelte:34
  • `.card span` moves (`transition: transform 200ms`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce. — test-storybooks/portable-stories-kitchen-sink/nextjs/styles/Home.module.css:59

What to do

  • Keep a visible focus style (don't remove the outline without a replacement), guard animation with prefers-reduced-motion, and raise low-contrast colour pairs to at least 4.5:1.
AC7 · A11y enforcement8.0 / 10Strong✓ Tool-verified

Other · Accessibility — Whether accessibility is ENFORCED in the toolchain — an accessibility checker configured over the markup (an a11y lint rule set, e.g. eslint-plugin-jsx-a11y or vuejs-accessibility where the project lints JavaScript) and an automated accessibility assertion wired into tests or CI (axe/pa11y/Lighthouse or an equivalent) — on the Documented→Verified→Prevented ladder.

Method: Repo config/CI scan: an accessibility checker configured over the markup (an a11y lint rule set such as eslint-plugin-jsx-a11y / vuejs-accessibility where JavaScript is linted) and an automated accessibility assertion in tests or CI (axe/pa11y/Lighthouse or equivalent), graded on the Documented→Verified→Prevented rungs. Deterministic, presence/rung detection.

Coverage: Population: the repository's own tooling configuration — lint config, test and CI files — NOT the markup. It is read for a configured accessibility checker and an automated accessibility assertion (axe/pa11y/Lighthouse, or a native-toolkit equivalent), and it credits an INVOCATION, never a mention: a licence filename, an import comment or a doc reference earns no rung. Enforcement configured entirely outside the repository leaves no evidence here and cannot be credited.

  • Accessibility checks run in tests (Verified) but aren't gated in CI — run the suite that holds those checks in your pipeline so an accessibility regression blocks the merge (Prevented). What was searched, so you can tell an absence from a miss: the 697 markup file(s) this pass actually assessed, the linter configuration checked in beside them, and this repository's test and CI files — matched by name against the accessibility checkers this dimension carries. An audit run outside the repository, a hosted scanner, or a check whose name is not one of those, is not seen here.

What to do

  • Accessibility linting is already configured — run the suite that already asserts accessibility in CI so a regression blocks the merge.
AX10 · Code composition10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — How the codebase splits by code ROLE — domain, application, infrastructure, test, generated. The significance map behind the knowledge/coupling weighting, and a DDD signal in its own right: a thin domain core under fat infrastructure is the anemic-domain smell, quantified. How each file's role is decided, because the split is only as good as that: a generated name or a build-output tree makes it Generated, a test project makes it Test, and otherwise the file's NAMESPACE and PATH words are matched against fixed vocabularies in a fixed ORDER — domain, then infrastructure, then application — so a file whose words hit two layers is counted under the earlier one. A production file matching none of them counts as application, so that share reads 'application or unclassified' rather than a measured application layer. Roles come from naming convention, never from what the code does. On this repository the split was taken from the source tree on disk rather than from a loaded .NET workspace, so a file's role is decided by its PATH segments alone — no declared namespace was available to add to the evidence — and generated output is excluded from the census entirely rather than counted as a generated share.

Method: Roslyn line-count by code ROLE: every source file classified Domain/Application/Infrastructure/Test/Generated by namespace + path convention (the shared CodeRoleClassifier), then significant lines summed per role. Deterministic; the advisory score is the business-logic (domain+application) share of production code.

Coverage: Population: ALL source files, each bucketed into ONE of five roles (Domain/Application/Infrastructure/Test/Generated) by namespace + path convention — a file whose layer isn't named in the convention falls to Application (the neutral default), and the split is line-count, not semantic depth or business value.

What to do

  • The domain core is a small share of production code, but most of the rest matched no layer vocabulary at all — so this is not yet an anemic-domain finding. The namespace/path convention could not place that code, which makes the composition above a statement about the naming, not about the design. Name the layers (or check that the repository's conventions differ from the ones this check knows) before reading a thin domain into it.
AX3 · Project dependency cycles7.2 / 10Strong✓ Tool-verified

Other · Architecture — Whether the project-reference graph is acyclic (cycles block independent build/deploy and signal eroding boundaries).

Method: Project reference cycles via elementary-DFS over real .csproj references, using the engine shared with D5/D7; cyclic versus acyclic. Exhaustive, deterministic.

  • The projects @storybook/builder-webpack5 → storybook → @storybook/react-webpack5 → @storybook/builder-webpack5 (one cycle inside a mutually-dependent group of 6 projects) form a reference cycle. Cyclic dependencies prevent independent build/test/deploy, blur ownership, and tend to grow into a big ball of mud. Break the cycle by extracting the shared types into a separate project both can reference. — code/builders/builder-webpack5/package.json:82

What to do

  • Break project reference cycles by extracting shared abstractions into a separate project; keep the graph a DAG.
AX4 · Dependency direction10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether dependencies point inward (Domain ← Application ← Infrastructure/Web) — the clean-architecture dependency rule, checked across the project graph.

Method: Layer violations by name-segment inference (Domain/Core to Application to Infrastructure/Web) over the project-reference graph. Exhaustive over all projects, deterministic.

AX6 · Interface segregation9.9 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether interfaces stay focused rather than fat — the Interface-Segregation principle (SOLID 'I').

Method: Roslyn scan: public interface declared-member counts (accessors fold into their property/event); fat-interface threshold (over 15 declared members) flagged per type. Each finding also reports the distinct-OPERATION count — members counted by name, so an overload group counts once — which decides whether it states the caller-side ISP harm or the implementer-side burden of an overload set. TypeScript: exported interfaces that declare behaviour, counted over their REQUIRED operations (method signatures and function-typed properties with no `?`, once per signature) — data-shape interfaces and ambient .d.ts declarations are outside the population; JavaScript declares no interfaces and is not applicable. Deterministic, type-level.

  • `SubAPI` declares 16 required operations: `toggleFullscreen`, `togglePanel`, `togglePanelPosition`, `toggleNav`, `setMobileNavigation`, `toggleToolbar`, `setOptions`, `setSizes`, `getIsFullscreen`, `getIsPanelShown`, `getIsNavShown`, `getNavAvailability`, `getShowToolbarWithCustomisations`, `getShowPanelWithCustomisations`, `getNavSizeWithCustomisations`, `focusOnUIElement`. Counted over its REQUIRED operations — a method signature or a function-typed property with no `?`, once per signature; optional members and data properties are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — code/core/src/manager-api/modules/layout.ts:50
  • `SubAPI` declares 32 required operations: `resolveStory`, `selectFirstStory`, `selectStory`, `getCurrentStoryData`, `getIndex`, `setIndex`, `jumpToSubtree`, `jumpToStory`, `getData`, `isPrepared`, `getParameters`, `getCurrentParameter`, `updateStoryArgs`, `resetStoryArgs`, `findLeafEntry`, `findLeafStoryId`, `findAllLeafStoryIds`, `findSiblingStoryId`, `fetchIndex`, `updateStory`, `updateDocs`, `setPreviewInitialized`, `setFilter`, `setFilters`, `resetTagFilters`, `setAllTagFilters`, `addTagFilters`, `removeTagFilters`, `resetStatusFilters`, `setAllStatusFilters`, `addStatusFilters`, `removeStatusFilters`. Counted over its REQUIRED operations — a method signature or a function-typed property with no `?`, once per signature; optional members and data properties are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — code/core/src/manager-api/modules/stories.ts:137
  • `Presets` declares 20 required operations under just 1 distinct name(s): `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`. Counted over its REQUIRED operations — a method signature or a function-typed property with no `?`, once per signature; optional members and data properties are not counted, because no implementer is forced to write them. That is an OVERLOAD SET, not 20 separate responsibilities: a caller binds to 1 operation(s) and uses the overload it selected, so the Interface-Segregation harm does NOT apply on the caller's side and splitting this into role-interfaces would scatter one operation without relieving anything. The burden that does remain is the IMPLEMENTER's — all 20 signatures must be written and kept in step. Reduce it by collapsing overloads (optional or default parameters, or an options object) rather than by segregating the interface. — code/core/src/types/modules/core-common.ts:98

What to do

  • Split fat interfaces into focused role-interfaces so clients depend only on what they use.
  • Where the width is an overload set rather than separate responsibilities, collapse the overloads instead — segregating those relieves no caller.
AX8 · Test isolation10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether production projects stay free of references to test projects — tests may depend on production, never the reverse.

Method: Csproj graph: each production project checked for references to test projects (identified by test-framework presence, not name). Zero violations is clean. Deterministic.

C2 · Access Controls7.0 / 10Strong✓ Tool-verified

Other · Security — Whether access is authorized by default — a framework authorization attribute/decorator or policy, or imperative guard methods (throw-on-violation) called from handlers.

Method: Roslyn scan: [Authorize] usage and authorization policies, plus imperative throw-on-violation guard methods detected via syntax. Deterministic.

  • Authorization IS enforced here (by route guards, auth middleware or checks that refuse a caller) — this is NOT a claim that endpoints are unprotected. What's missing is a NAMED rule set: who may do what is encoded inline where it is checked, so the rules can't be listed, reviewed or tested apart from the code that applies them. Recommendation, not a defect.

What to do

  • Name the access rules — roles/permissions declared once (a @Roles/@Permissions decorator with its guard, a CASL ability, a casbin model, or Supabase CREATE POLICY) and consulted where access is checked, so the rule set is reviewable and testable on its own.
GD1 · Unfinished & placeholder code10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Unreviewed-generation residue in this repository's JavaScript/TypeScript: functions whose whole body still throws a "not implemented" error, and placeholder text (lorem ipsum, changeme/replace_me…) left in strings and JSX of non-test, non-generated code. Scored as a quality signature, never as a claim about authorship.

Method: Roslyn syntax scan: NotImplementedException throws and placeholder string literals in non-test, non-generated shipped code. Deterministic, code-shape signature.

IC1 · Incompleteness & stubs6.5 / 10Adequate✓ Tool-verified

Other · Code Health — Unfinished work detected by code SHAPE, not keywords, in this repository's JavaScript/TypeScript: functions that only throw a "not implemented" error, functions that take inputs and return a constant or do nothing, async functions that never await, dead `if (false)` branches, and skeleton classes most of whose methods are holes.

Method: Roslyn syntax scan: incompleteness by code shape (constant-returning methods, async-never-await, #if false branches, guards that return what the code already falls through to, tests an earlier guard already decided, comparisons against NaN, skeleton types), not keyword-gated. Deterministic, code-shape heuristic.

  • `nameSession` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — agent-eval/lib/mcp/codex-browser-client-mock.mjs:824
  • The guard above `return 'image/png';` also returns `'image/png'`, so no input can make it matter. Implement the distinction that was intended, or delete the guard. — agent-eval/lib/mcp/node-repl-mock.mjs:120
  • `postinstall` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/addons/themes/src/postinstall.ts:16
  • `setupWatchers` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/addons/vitest/src/node/vitest-manager.ts:604
  • `generateAddonSetupCode` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/builders/builder-vite/src/codegen-set-addon-channel.ts:1
  • `cliStoriesTargetPath` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/cli/helpers.ts:107
  • `isModuleGraphSupported` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/cli/skills/availability.ts:61
  • `startChangeDetectionInProcess` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/cli/tools/sdk/local-runtime.ts:100
  • `copyUsingWorkAround` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/components/components/syntaxhighlighter/clipboard.ts:13
  • `dispose` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/core-server/change-detection/change-detection-service.ts:271
  • `register` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/mocking-utils/mocker-runtime.js:17
  • `delete` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/mocking-utils/mocker-runtime.js:21
  • `invalidate` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/mocking-utils/mocker-runtime.js:25
  • `addReport` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/preview-api/modules/store/reporter-api.ts:11
  • `setupPreviewNavigator` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/core/src/preview/preview-navigator.ts:91
  • `loaders` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. (×2) — code/frameworks/nextjs-vite/src/preview.tsx:67, code/frameworks/nextjs/src/preview.tsx:64
  • `beforeEach` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/frameworks/sveltekit/src/preview.ts:24
  • `run` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. (×2) — code/lib/cli-storybook/src/automigrate/fixes/upgrade-storybook-related-dependencies.ts:107, scripts/get-sandbox-dir.ts:14
  • `transform` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/lib/codemod/src/transforms/find-implicit-spies.ts:69
  • `clear` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/lib/docgen-harness/src/web-components/__testfixtures__/stencil-props/stencil-props.tsx:42
  • `reactDocgenLoader` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/presets/react-webpack/src/loaders/react-docgen-loader.ts:71
  • `render` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it. — code/renderers/server/src/render.ts:46
  • `createAppendix` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — code/renderers/svelte/src/svelte-csf/compiler/post-transform/create-appendix.ts:28
  • The guard above `return 'npm';` also returns `'npm'`, so no input can make it matter. Implement the distinction that was intended, or delete the guard. — scripts/eval/lib/package-manager.ts:24
  • `ready` looks like it should compute a result but its body just returns a constant — a placeholder return that was never filled in. (×5) — scripts/tasks/bench.ts:13, scripts/tasks/check-sandbox.ts:8, scripts/tasks/check.ts:45, …
  • A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something. (×8) — code/core/src/common/presets.test.ts:610, code/core/src/core-server/build-index.test.ts:6, code/core/src/csf-tools/CsfFile.test.ts:1681, …
  • `gitStateCallback` has an empty body — confirm it's an intentional no-op and not an unfinished method. — code/core/src/core-server/change-detection/GitDiffProvider.ts:34

What to do

  • Finish or delete the unfinished stubs (functions that throw "not implemented", or whose body is empty or a bare constant) — they are dead surface that looks live.
  • Clear the softer debt: re-enable or delete skipped tests, decide whether each empty function is a deliberate no-op (and say so in a comment), and replace blanket `eslint-disable` / `@ts-nocheck` with targeted, justified suppressions.
M1 · Documentation (README)8.3 / 10Strong✓ Tool-verified

Maturity · Maturity — Whether the repo and its projects have a README, and whether it's substantive and current.

Method: Filesystem scan: README presence, word count, and headings for depth; git history for staleness. Exhaustive across root and project dirs, deterministic.

What to do

  • Add an 'Architecture' / 'How it works' section to the root README — the high-level shape.
  • Add a README to the 56 of 109 project(s) that lack one — worth up to 1 pts.
M2 · Architecture documentation5.0 / 10Adequate✓ Tool-verified

Maturity · Maturity — Whether key decisions (ADRs) and the high-level shape (C4/diagrams) are written down.

Method: Filesystem scan: ADR folder/naming conventions or content, plus Mermaid/PlantUML/C4/architecture.md discovery. Exhaustive, deterministic.

  • No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.

What to do

  • Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them.
M3 · Folder & project structure10.0 / 10Exemplary✓ Tool-verified

Maturity · Maturity — Whether the repo is organised deliberately — src/test separation and consistent project naming.

Method: Filesystem scan: src/test folder separation and namespace-prefix consistency (majority RootNamespace agreement). Exhaustive across projects, deterministic.

M4 · Documentation accuracy8.0 / 10Strong✓ Tool-verified

Maturity · Maturity — Whether the README actually describes the code that exists (LLM-judged, advisory).

Method: Judged by language model at low temperature: README accuracy versus actual projects, within a disclosed tolerance. Advisory, not a measured number.

  • CONTRIBUTING.md names TypeScript 7, but the manifest declares `typescript` ^6.0.3. Checked without a model against the repository: its files and folders, the scripts and dependencies of every REDACTED, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — CONTRIBUTING.md:63

What to do

  • Reconcile the README with reality: CONTRIBUTING.md names TypeScript 7, but the manifest declares `typescript` ^6.0.3.
P1 · CI/CD gates10.0 / 10Exemplary○ Nothing flagged

Readiness · Readiness — Whether an automated pipeline builds and tests every change.

Method: Filesystem scan: CI workflow files (.github/workflows, .gitlab-ci.yml, etc.) for build and test stages. Exhaustive, deterministic.

P10 · Library API & versioning10.0 / 10Exemplary○ Nothing flagged

Readiness · Readiness — For a library: a deliberate (small) public API surface and explicit semantic versioning so consumers can depend on it safely.

Method: Roslyn scan: public API surface area and semantic-versioning markers (SemVer attributes, changelog entries) for libraries; off .NET, a library is the ecosystem's publication act (an npm package that is not private and names an entry point, a PyPI distribution with a build system, a Rust library crate, a Maven/Gradle module that publishes, a Go module with no package main, a gemspec, a Composer library, a SwiftPM library product, a pub.dev or Hex package), its surface is the share of types the language model records as public (Rust, Swift, Java, Kotlin, Go, Dart; not measured where the model records no type visibility or, as in TypeScript, only module-level export), and its version is read from the manifest, a semver CHANGELOG, release tooling or semver git tags. Exhaustive, deterministic.

P2 · Observability9.5 / 10Exemplary✓ Tool-verified

Readiness · Readiness — Whether the code is diagnosable in production — structured logging, tracing/metrics, health checks.

Method: Filesystem/Roslyn scan: structured-logging frameworks (Serilog, NLog), OpenTelemetry, and health-check endpoint patterns. Exhaustive, deterministic.

  • Only 23/28 runnable modules use logging (modules with no entry point or server are excluded — they are libraries a runnable module hosts). Silent: `agent-eval`, `code/frameworks/nextjs-vite`, `code/frameworks/sveltekit`, `code/lib/cli-sb`, `code/lib/vite-plugin-storybook-nextjs`.
  • `code/core/src/toolbar/components/ToolbarMenuSelect.tsx` reports through `console.*` at line 58 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/toolbar/components/ToolbarMenuSelect.tsx:58
  • `code/core/src/shared/utils/module.ts` reports through `console.*` at line 22 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/shared/utils/module.ts:22
  • `code/core/src/shared/open-service/sync-test/remote-command/server.ts` reports through `console.*` at line 22 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/shared/open-service/sync-test/remote-command/server.ts:22
  • `code/core/src/shared/open-service/sync-test/remote-command/server.ts` reports through `console.*` at line 26 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/shared/open-service/sync-test/remote-command/server.ts:26
  • `code/core/src/shared/open-service/sync-test/local-command/server.ts` reports through `console.*` at line 12 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/shared/open-service/sync-test/local-command/server.ts:12
  • `code/core/src/shared/open-service/sync-test/local-command/server.ts` reports through `console.*` at line 14 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/shared/open-service/sync-test/local-command/server.ts:14
  • `code/core/src/shared/open-service/sync-test/concurrent-writes/server.ts` reports through `console.*` at line 12 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/shared/open-service/sync-test/concurrent-writes/server.ts:12
  • `code/core/src/shared/open-service/sync-test/concurrent-writes/server.ts` reports through `console.*` at line 14 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/shared/open-service/sync-test/concurrent-writes/server.ts:14
  • `code/core/src/preview-api/modules/store/StoryStore.ts` reports through `console.*` at line 312 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/store/StoryStore.ts:312
  • `code/core/src/preview-api/modules/store/StoryStore.ts` reports through `console.*` at line 361 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/store/StoryStore.ts:361
  • `code/core/src/preview-api/modules/preview-web/render/StoryRender.ts` reports through `console.*` at line 369 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/preview-web/render/StoryRender.ts:369
  • `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 521 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/addons/hooks.ts:521
  • `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 552 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/addons/hooks.ts:552
  • `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 553 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/addons/hooks.ts:553
  • `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 581 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/addons/hooks.ts:581
  • `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 605 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/addons/hooks.ts:605
  • `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 642 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/preview-api/modules/addons/hooks.ts:642
  • `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 126 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/node-logger/logger/console.ts:126
  • `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 159 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/node-logger/logger/console.ts:159
  • `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 202 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/node-logger/logger/console.ts:202
  • `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 214 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/node-logger/logger/console.ts:214
  • `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 296 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/node-logger/logger/console.ts:296
  • `code/core/src/node-logger/logger/logger.ts` reports through `console.*` at line 178 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/node-logger/logger/logger.ts:178
  • `code/core/src/node-logger/logger/logger.ts` reports through `console.*` at line 195 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/node-logger/logger/logger.ts:195
  • `code/core/src/manager/provider.ts` reports through `console.*` at line 13 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/manager/provider.ts:13
  • `code/core/src/manager/components/panel/Panel.tsx` reports through `console.*` at line 45 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/manager/components/panel/Panel.tsx:45
  • `code/core/src/manager/components/panel/Panel.tsx` reports through `console.*` at line 46 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/manager/components/panel/Panel.tsx:46
  • `code/core/src/manager/components/panel/Panel.tsx` reports through `console.*` at line 47 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/manager/components/panel/Panel.tsx:47
  • `code/core/src/manager/components/error-boundary/ManagerErrorBoundary.tsx` reports through `console.*` at line 196 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/manager/components/error-boundary/ManagerErrorBoundary.tsx:196
  • `code/core/src/manager/components/error-boundary/ManagerErrorBoundary.tsx` reports through `console.*` at line 197 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/manager/components/error-boundary/ManagerErrorBoundary.tsx:197
  • `code/core/src/core-server/build-dev.ts` reports through `console.*` at line 197 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/core-server/build-dev.ts:197
  • `code/core/src/core-server/build-dev.ts` reports through `console.*` at line 198 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/core-server/build-dev.ts:198
  • `code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts` reports through `console.*` at line 45 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/core-server/utils/warnWhenUsingArgTypesRegex.ts:45
  • `code/core/src/core-server/utils/save-story/getDiff.ts` reports through `console.*` at line 12 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/core-server/utils/save-story/getDiff.ts:12
  • `code/core/src/components/components/Tabs/Tabs.tsx` reports through `console.*` at line 169 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/components/components/Tabs/Tabs.tsx:169
  • `code/core/src/components/components/Tabs/Tabs.tsx` reports through `console.*` at line 170 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/components/components/Tabs/Tabs.tsx:170
  • `code/core/src/components/components/Tabs/Tabs.tsx` reports through `console.*` at line 171 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/components/components/Tabs/Tabs.tsx:171
  • `code/core/src/common/utils/log-config.ts` reports through `console.*` at line 4 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/common/utils/log-config.ts:4
  • `code/core/src/common/utils/process-ancestry.ts` reports through `console.*` at line 62 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline. — code/core/src/common/utils/process-ancestry.ts:62

What to do

  • Extend structured logging to the remaining runnable modules so everything you run is diagnosable in production.
  • Route service-code `console.*` output through the module's structured logger (with named fields), so delivery outcomes and failures reach the log pipeline with a level.
P3 · Security & performance tooling7.0 / 10Strong✓ Tool-verified

Readiness · Readiness — Whether SAST, secret/dependency scanning and performance benchmarking are wired in (presence, not runtime).

Method: Filesystem scan: SAST configuration, dependency-update automation, secret scanning, and a benchmark harness or benchmark step — in this repository's own ecosystem. Exhaustive, deterministic.

What to do

  • Dependabot is configured but does not watch `github-actions` — add that `package-ecosystem` entry to .github/dependabot.yml so those dependencies get the same automatic update and advisory pressure as the ones it already covers.
  • Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
P4 · Deployment & Rollback8.0 / 10Strong✓ Tool-verified

Readiness · Readiness — Whether releases are automated and safely reversible (probes, rolling updates, approval gates) — from manifests/pipeline files, not the live environment.

Method: Filesystem scan: deployment manifests/IaC (K8s YAML, Helm, Terraform) for rolling updates, probes, approval gates, migration hooks. Exhaustive, deterministic.

What to do

  • Make sure a person approves each release. The release job names an environment, but its approval rules live in the code host's settings, where Watchdog can't see them. Check that a reviewer must approve each release, or publish releases as drafts first, so a bad build can be stopped before anyone downloads it.
P6 · Release Hygiene10.0 / 10Exemplary✓ Tool-verified

Readiness · Readiness — Whether releases are traceable — a maintained changelog and explicit version stamping.

Method: Filesystem scan: changelog file presence and version tags in csproj or git tags. Exhaustive, deterministic.

P7 · Outbound HTTP resilience3.0 / 10Weak✓ Tool-verified

Readiness · Readiness — Whether outbound HTTP calls are wrapped in resilience (retry/timeout/circuit-breaker) so a failing dependency doesn't cascade.

Method: Source scan: outbound HTTP clients and what bounds them — resilience handlers (Polly, AddStandardResilienceHandler) on .NET; on Go, the JVM, Python, JavaScript/TypeScript, Ruby, PHP, Rust, Elixir, Swift, Dart and Erlang, a timeout, deadline, retry or breaker beside each call, or a process-wide client default (a framework-wide deadline such as Drupal core's, Laravel's or actix's awc counts). Exhaustive, deterministic.

  • `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout. (×13) — code/core/src/cli/dirs.ts:38, code/core/src/common/utils/get-storybook-refs.ts:49, code/core/src/common/utils/get-storybook-refs.ts:55, …

What to do

  • Bound every outbound call: pass `signal: AbortSignal.timeout(ms)` to `fetch`, set `timeout` on the axios instance (`axios.create({ timeout })`), and add retries with back-off (`axios-retry`, `p-retry`) and a breaker (`opossum`, `cockatiel`) around dependencies that fail.
PF3 · Async & latency hygiene6.0 / 10Adequate✓ Tool-verified

Readiness · Performance — Whether asynchronous code stays responsive — it avoids sync-over-async blocking (a .NET .Wait()/.GetAwaiter().GetResult(), a time.sleep or blocking HTTP call inside a Python coroutine, a *Sync call inside an async JavaScript function, block_on inside a Rust async fn, runBlocking inside a Kotlin suspend function, block() inside a Reactor publisher) that stalls a thread or event loop and risks deadlock, and, where the code is a reusable library on .NET, awaits with ConfigureAwait(false) so it never captures and stalls its caller's context.

Method: Production-source scan: sync-over-async blocking counted everywhere — .Wait()/.GetAwaiter().GetResult() in .NET; off .NET, read from the language model, a blocking call inside an async function (Python, TS/JS, Rust, Kotlin, Swift, Dart) or inside a Java method returning a Reactor Mono/Flux or a Scala method returning a Future or effect — and, for a .NET library with ≥5 awaits, the share of awaits using ConfigureAwait(false). Deterministic, syntax/text detection.

  • `mkdirSync` in `loadOrBuildBaselineAnalysis` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — agent-eval/lib/post-analysis/baseline.ts:213
  • `writeFileSync` in `loadOrBuildBaselineAnalysis` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — agent-eval/lib/post-analysis/baseline.ts:227
  • `spawnSync` in `postinstall` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/addons/themes/src/postinstall.ts:20
  • `existsSync` in `startVitest` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/addons/vitest/src/node/vitest-manager.ts:104
  • `readFileSync` in `startVitest` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/addons/vitest/src/node/vitest-manager.ts:106
  • `existsSync` in `callback to dependencies.map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/addons/vitest/src/node/vitest-manager.ts:580
  • `readFileSync` in `load` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/builders/builder-vite/src/plugins/code-generator-plugin.ts:97
  • `existsSync` in `callback to map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — REDACTED:82
  • `existsSync` in `resolveVitePublicDir` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/builders/builder-vite/src/vite-config.ts:134
  • `existsSync` in `callback to filter` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/scripts/generate-source-files.ts:136
  • `existsSync` in `callback to outputFiles.map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/builder-manager/utils/files.ts:20
  • `existsSync` in `callback to entrypoints.map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/builder-manager/utils/managerEntries.ts:60
  • `existsSync` in `detectLanguage` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. (×2) — code/core/src/cli/detectLanguage.ts:20, code/core/src/cli/detectLanguage.ts:35
  • `existsSync` in `cliStoriesTargetPath` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/cli/helpers.ts:108
  • `existsSync` in `templatePath` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. (×4) — code/core/src/cli/helpers.ts:140, code/core/src/cli/helpers.ts:144, code/core/src/cli/helpers.ts:148, …
  • `readFileSync` in `getModulePackageJSON` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. (×5) — REDACTED:127, code/core/src/common/js-package-manager/NPMProxy.ts:117, code/core/src/common/js-package-manager/PNPMProxy.ts:227, …
  • `mkdirSync` in `temporaryDirectory` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/common/utils/cli.ts:20
  • `existsSync` in `callback to results.filter` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/core-server/presets/common-preset.ts:125
  • `existsSync` in `managerHead` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/core-server/presets/common-preset.ts:299
  • `existsSync` in `callback to find` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/core-server/utils/StoryIndexGenerator.ts:880
  • `existsSync` in `getPreviewBuilder` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/core-server/utils/get-builders.ts:20
  • `readFileSync` in `getPreviewBuilder` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/core-server/utils/get-builders.ts:23
  • `existsSync` in `runStoryTests` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/core-server/utils/ghost-stories/run-story-tests.ts:92
  • `existsSync` in `callback to staticDirs.map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — REDACTED:127
  • `statSync` in `callback to staticDirs.map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — REDACTED:127
  • `existsSync` in `hashMainConfig` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/core/src/telemetry/storybook-metadata.ts:326
  • `readFileSync` in `anonymous function` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. (×2) — code/frameworks/angular-vite/src/builders/build-storybook/index.ts:125, code/frameworks/angular-vite/src/builders/start-storybook/index.ts:149
  • `writeFileSync` in `callback to withFileLock` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/frameworks/angular-vite/src/compodoc/ensure-documentation.ts:76
  • `mkdirSync` in `generateDocumentation` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/frameworks/angular-vite/src/compodoc/generate-documentation.ts:151
  • `mkdtempSync` in `generateDocumentation` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/frameworks/angular-vite/src/compodoc/generate-documentation.ts:154
  • `existsSync` in `generateDocumentation` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs. — code/frameworks/angular-vite/src/compodoc/generate-documentation.ts:177

What to do

  • TypeScript/JavaScript: use the promise APIs (fs/promises, a promisified child_process.execFile, the async zlib/crypto functions) and await them instead of the *Sync variants.
R1 · Type Safety10.0 / 10Exemplary✓ Tool-verified

React / JS · Code Health — How much of the frontend is typed TypeScript vs untyped JavaScript.

Method: Frontend file inventory: the share of typed TypeScript vs untyped JavaScript across the source tree. Deterministic, exhaustive over frontend files.

R10 · Code Duplication9.3 / 10Exemplary✓ Tool-verified

React / JS · Code Health — Near-exact copy-pasted blocks of substantial extent across the frontend (the D4 clone algorithm over JS/TS tokens, D-386): a block is reported only where its copies still agree on most of their own identifiers and literals, or were renamed as they were pasted but kept most of their constants, and where the copies carry enough code to stand on their own or the copied extent reaches 30 lines — so a re-implementation sharing neither names nor values, and a small pasted declaration, are both found and deliberately not reported, and a clean R10 is not a claim that nothing was copied.

Method: Near-exact copy-pasted blocks of substantial extent across the frontend (the D4 clone algorithm run over JS/TS tokens). Masking finds the candidates; a block is reported when its copies still agree on most of their own identifiers and literals, or when a renamed copy still agrees on most of its constants, AND the copies carry enough code to stand on their own — or when the copied extent reaches 30 lines. So a re-implementation sharing neither names nor values, and a small pasted declaration, are deliberately not counted. Deterministic.

  • code/frameworks/angular-vite/src/client/renderer/ and code/frameworks/angular/src/client/angular-beta/ are near-verbatim copies of each other: 11 files are byte-identical under the same relative paths (~1029 lines; the trees hold 22 and 23 files). That is one structural fact, not 11 local ones: every edit made to one tree and not the other drifts silently, which is the failure whole-tree forks guarantee. Pick one tree as the single source and produce the other from it (generated, copied at build or release time, or re-exported) — or, if the copy is a stale snapshot nothing produces any more, delete it. Check first whether the copy is a deliberately published deliverable (a template consumers copy verbatim, a released sample frozen at a version); where it is, keep it produced from the source tree rather than edited in place. — code/frameworks/angular-vite/src/client/renderer/StorybookModule.test.ts:1
  • code/frameworks/nextjs/template/stories_nextjs-default-ts/ and code/frameworks/nextjs/template/stories_nextjs-prerelease/ are near-verbatim copies of each other: 6 files are byte-identical under the same relative paths (~330 lines; the trees hold 6 and 6 files). That is one structural fact, not 6 local ones: every edit made to one tree and not the other drifts silently, which is the failure whole-tree forks guarantee. Pick one tree as the single source and produce the other from it (generated, copied at build or release time, or re-exported) — or, if the copy is a stale snapshot nothing produces any more, delete it. Check first whether the copy is a deliberately published deliverable (a template consumers copy verbatim, a released sample frozen at a version); where it is, keep it produced from the source tree rather than edited in place. — code/frameworks/nextjs/template/stories_nextjs-default-ts/ServerActions.stories.tsx:1
  • code/frameworks/angular/template/stories_angular-cli-default-ts/ and code/frameworks/angular/template/stories_angular-cli-prerelease/ are near-verbatim copies of each other: 5 files are byte-identical under the same relative paths (~224 lines; the trees hold 6 and 6 files). That is one structural fact, not 5 local ones: every edit made to one tree and not the other drifts silently, which is the failure whole-tree forks guarantee. Pick one tree as the single source and produce the other from it (generated, copied at build or release time, or re-exported) — or, if the copy is a stale snapshot nothing produces any more, delete it. Check first whether the copy is a deliberately published deliverable (a template consumers copy verbatim, a released sample frozen at a version); where it is, keep it produced from the source tree rather than edited in place. — code/frameworks/angular/template/stories_angular-cli-default-ts/model-signal/color-picker.stories.ts:1
  • 98 duplicated blocks under code/frameworks/ have copies in at least two of the sibling directories angular, angular-vite, ember, html-vite, nextjs, nextjs-vite (+10 more sibling(s) not listed) — 72 of them are reported below, and 26 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 98 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 98 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 98 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts:1
  • 92 duplicated blocks under code/ have copies in at least two of the sibling directories .storybook, addons, builders, core, frameworks, lib (+2 more sibling(s) not listed) — 74 of them are reported below, and 18 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 92 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 92 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 92 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — code/frameworks/html-vite/template/cli/ts/Page.ts:8
  • 22 duplicated blocks under code/renderers/ have copies in at least two of the sibling directories html, preact, react, server, svelte, vue3 (+1 more sibling(s) not listed) — 14 of them are reported below, and 8 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 22 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 22 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 22 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — code/renderers/svelte/src/parsers/svelteImportParser.ts:92
  • 21 duplicated blocks under code/core/src/ have copies in at least two of the sibling directories actions, backgrounds, cli, client-logger, common, component-testing (+14 more sibling(s) not listed) — 13 of them are reported below, and 8 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 21 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 21 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 21 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — code/core/src/preview-api/modules/preview-web/parseArgsParam.ts:9
  • 16 duplicated blocks under agent-eval/evals/ have copies in at least two of the sibling directories 801-create-accessible-component, 802-create-component, 803-edit-component, 804-write-story-for-existing-component, 805-non-visual-refactor, 806-browse-request (+15 more sibling(s) not listed) — 13 of them are reported below, and 3 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 16 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 16 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 16 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — agent-eval/evals/803-edit-component/src/components/ReviewCard.tsx:9
  • 7 duplicated blocks under code/renderers/react/template/stories/docgen-components/ have copies in at least two of the sibling directories js-class-component, js-function-component, js-function-component-inline-defaults, js-function-component-inline-defaults-no-propTypes, js-proptypes, jsdoc (+4 more sibling(s) not listed) — 4 of them are reported below, and 3 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 7 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 7 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 7 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — code/renderers/react/template/stories/docgen-components/ts-react-fc/input.tsx:4
  • 6 duplicated blocks under code/lib/create-storybook/src/generators/ have copies in at least two of the sibling directories ANGULAR, EMBER, HTML, NEXTJS, NUXT, PREACT (+8 more sibling(s) not listed) — 2 of them are reported below, and 4 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 6 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 6 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 6 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — code/lib/create-storybook/src/generators/ANGULAR/index.ts:22
  • 5 duplicated blocks under code/core/src/manager/ have copies in at least two of the sibling directories components, settings — 1 of them are reported below, and 4 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 5 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 5 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 5 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — code/core/src/manager/components/sidebar/SearchResults.tsx:241
  • 5 duplicated blocks under code/lib/ have copies in at least two of the sibling directories angular-cm, angular-compodoc, cli-storybook, codemod, create-storybook — 3 of them are reported below, and 2 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 5 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 5 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 5 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — code/lib/angular-cm/src/extract-arg-types.ts:95
  • REDACTED:33 · code/core/src/common/js-package-manager/NPMProxy.ts:36 — the two spans are one implementation copied and then locally edited — 1635 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — REDACTED:33
  • code/lib/angular-cm/src/extract-arg-types.ts:95 · code/lib/angular-compodoc/src/extract-arg-types.ts:89 — the two spans are one implementation copied and then locally edited — 1242 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — code/lib/angular-cm/src/extract-arg-types.ts:95
  • code/core/src/common/js-package-manager/PNPMProxy.ts:480 · code/core/src/common/js-package-manager/Yarn2Proxy.ts:211 — the two spans are one implementation copied and then locally edited — 1023 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — code/core/src/common/js-package-manager/PNPMProxy.ts:480
  • agent-eval/lib/agentic-reference/metrics/complexity-cognitive.ts:21 · agent-eval/lib/agentic-reference/metrics/complexity-jsx.ts:46 — the two spans are one implementation copied and then locally edited — 833 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — agent-eval/lib/agentic-reference/metrics/complexity-cognitive.ts:21
  • code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts:1 · code/frameworks/angular/src/client/angular-beta/AbstractRenderer.ts:1 — these 2 files are line-for-line copies of one another — 104 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts:1
  • code/frameworks/react-native-web-vite/template/cli/js/Page.jsx:1 · code/frameworks/react-native-web-vite/template/cli/ts/Page.tsx:1 — these 2 files are line-for-line copies of one another — 104 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — code/frameworks/react-native-web-vite/template/cli/js/Page.jsx:1
  • code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts:1 · code/frameworks/angular/src/client/angular-beta/utils/NgComponentAnalyzer.ts:1 — these 2 files are line-for-line copies of one another — 103 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts:1
  • code/frameworks/angular-vite/src/builders/build-storybook/index.ts:86 · code/frameworks/angular-vite/src/builders/start-storybook/index.ts:98 — the two spans are one implementation copied and then locally edited — 434 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — code/frameworks/angular-vite/src/builders/build-storybook/index.ts:86
  • code/frameworks/angular/src/builders/build-storybook/index.ts:35 · code/frameworks/angular/src/builders/start-storybook/index.ts:36 — the two spans are one implementation copied and then locally edited — 497 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — code/frameworks/angular/src/builders/build-storybook/index.ts:35
  • code/lib/angular-cm/src/extract-arg-types.ts:434 · code/lib/angular-compodoc/src/extract-arg-types.ts:430 — the two spans are one implementation copied and then locally edited — 664 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — code/lib/angular-cm/src/extract-arg-types.ts:434
  • code/frameworks/angular-vite/src/client/renderer/utils/PropertyExtractor.ts:1 · code/frameworks/angular/src/client/angular-beta/utils/PropertyExtractor.ts:1 — these 2 files are line-for-line copies of one another — 91 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — code/frameworks/angular-vite/src/client/renderer/utils/PropertyExtractor.ts:1
  • code/frameworks/html-vite/template/cli/ts/Page.ts:8 · code/renderers/html/template/cli/ts/Page.ts:8 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — code/frameworks/html-vite/template/cli/ts/Page.ts:8
  • code/frameworks/nextjs-vite/src/routing/app-router-provider.tsx:1 · code/frameworks/nextjs/src/routing/app-router-provider.tsx:6 — these 2 files are line-for-line copies of one another — 88 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — code/frameworks/nextjs-vite/src/routing/app-router-provider.tsx:1
  • code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts:1 · code/frameworks/angular/src/client/angular-beta/StorybookWrapperComponent.ts:1 — these 2 files are line-for-line copies of one another — 85 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts:1
  • REDACTED:1 · REDACTED:1 — these 2 files are line-for-line copies of one another — 85 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — REDACTED:1
  • scripts/build-package.ts:31 · scripts/check-package.ts:20 — the two spans are one implementation copied and then locally edited — 575 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — scripts/build-package.ts:31
  • code/core/src/components/components/Tabs/StatelessTabList.tsx:68 · code/core/src/components/components/Tabs/TabList.tsx:158 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — code/core/src/components/components/Tabs/StatelessTabList.tsx:68
  • code/renderers/react/template/stories/docgen-components/ts-react-fc/input.tsx:4 · code/renderers/react/template/stories/docgen-components/ts-types/input.tsx:8 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are. — code/renderers/react/template/stories/docgen-components/ts-react-fc/input.tsx:4
  • code/frameworks/angular-vite/src/client/decorators.ts:11 · code/frameworks/angular/src/client/decorators.ts:11 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are. — code/frameworks/angular-vite/src/client/decorators.ts:11
  • code/frameworks/angular-vite/src/client/preview.ts:95 · code/frameworks/angular/src/client/preview.ts:95 · code/renderers/web-components/src/preview.ts:108 — the 3 copies are spread across 3 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are. — code/frameworks/angular-vite/src/client/preview.ts:95
  • code/frameworks/angular-vite/src/client/preview.ts:1 · code/frameworks/angular/src/client/preview.ts:1 — these 2 files are line-for-line copies of one another — 64 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — code/frameworks/angular-vite/src/client/preview.ts:1
  • code/frameworks/nextjs-vite/template/cli/ts/Page.tsx:10 · code/frameworks/nextjs/template/cli/ts/Page.tsx:10 · code/frameworks/react-vite/template/cli/ts/Page.tsx:10 · code/frameworks/react-webpack5/template/cli/ts/Page.tsx:10 · +1 more site(s) not listed — the 5 copies are spread across 5 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. There is one copy in each of 5 separate files rather than several in one place, so check first whether these are sibling modules that each declare their own version of one shape — one per entity, per provider, per language. Where they are, no single extracted module collapses them: each module still has to be written, and what recurs is the TEMPLATE. The moves that do collapse a template are to generate these modules from the set they enumerate, or to replace the repeated construction with one factory each site calls with its own values — and where the set is the point, each module pinning one distinct thing, the repetition IS the enumeration and there is nothing to delete. — code/frameworks/nextjs-vite/template/cli/ts/Page.tsx:10
  • code/core/src/preview-api/modules/preview-web/render/CsfDocsRender.ts:48 · code/core/src/preview-api/modules/preview-web/render/MdxDocsRender.ts:53 — the two spans are one implementation copied and then locally edited — 399 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — code/core/src/preview-api/modules/preview-web/render/CsfDocsRender.ts:48
  • agent-eval/lib/mcp/claude-browser-mock.mjs:2007 · agent-eval/lib/mcp/node-repl-mock.mjs:299 — the two spans are one implementation copied and then locally edited — 377 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — agent-eval/lib/mcp/claude-browser-mock.mjs:2007
  • code/core/src/cli/skills/content/setup-prompts/monorepo-optimized-tests-relaxed-limits-no-story-deletion.ts:40 · code/core/src/cli/skills/content/setup-prompts/monorepo.ts:40 — the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it. — code/core/src/cli/skills/content/setup-prompts/monorepo-optimized-tests-relaxed-limits-no-story-deletion.ts:40
  • code/core/src/preview-api/modules/preview-web/parseArgsParam.ts:9 · code/core/src/router/utils.ts:80 — the two spans are one implementation copied and then locally edited — 342 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — code/core/src/preview-api/modules/preview-web/parseArgsParam.ts:9
  • code/frameworks/nextjs-vite/src/preview.tsx:21 · code/frameworks/nextjs/src/preview.tsx:22 — the two spans are one implementation copied and then locally edited — 302 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — code/frameworks/nextjs-vite/src/preview.tsx:21
  • code/frameworks/react-native-web-vite/template/cli/js/Button.jsx:2 · code/frameworks/react-native-web-vite/template/cli/ts/Button.tsx:2 — these 2 files are line-for-line copies of one another — 54 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — code/frameworks/react-native-web-vite/template/cli/js/Button.jsx:2

What to do

  • Act on each finding's own remediation rather than one rule: the move depends on what recurs. Where the copies are executable blocks, give the shared part one home and call it from each site; where they are declarations, a listing, a specialisation already delegating to its base, or one shape repeated per entity, there is no call site and the move is a shared type, a generated set or a factory — sometimes there is nothing to extract.
R11 · Import Boundaries5.7 / 10Adequate✓ Tool-verified

React / JS · Architecture — Conformance to the detected frontend architecture layout (feature-sliced / layered src) plus cross-package deep-import rules (D-386).

Method: Conformance to the detected frontend layout (feature-sliced / layered src) plus cross-package deep-import rules, over the module graph. Deterministic.

  • agent-eval/scripts/eval-gate-thread.ts:20 reaches into another package with a relative path (../../scripts/utils/gh.ts) — import the package by name instead. — agent-eval/scripts/eval-gate-thread.ts:20
  • code/addons/mcp/scripts/generate-tools-api-doc.ts:18 imports code/addons/mcp/src/test-support/register-core-toolsets.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on. — code/addons/mcp/scripts/generate-tools-api-doc.ts:18
  • code/addons/onboarding/src/Onboarding.tsx:9 reaches into another package with a relative path (../../../core/src/manager/components/TourGuide/HighlightElement.tsx) — import the package by name instead. — code/addons/onboarding/src/Onboarding.tsx:9
  • code/addons/onboarding/src/Onboarding.tsx:10 reaches into another package with a relative path (../../../core/src/manager/components/TourGuide/TourGuide.tsx) — import the package by name instead. — code/addons/onboarding/src/Onboarding.tsx:10
  • code/addons/onboarding/src/features/IntentSurvey/IntentSurvey.tsx:7 reaches into another package with a relative path (../../../../../.storybook/isChromatic.ts) — import the package by name instead. — code/addons/onboarding/src/features/IntentSurvey/IntentSurvey.tsx:7
  • code/addons/vitest/src/constants.ts:5 reaches into another package with a relative path (../../../core/src/component-testing/constants.ts) — import the package by name instead. — code/addons/vitest/src/constants.ts:5
  • code/addons/vitest/src/constants.ts:6 reaches into another package with a relative path (../../../addons/a11y/src/constants.ts) — import the package by name instead. — code/addons/vitest/src/constants.ts:6
  • code/addons/vitest/src/custom-matchers.d.ts:3 reaches into another package with a relative path (../../../core/src/shared/utils/toHaveLiveRegion) — import the package by name instead. — code/addons/vitest/src/custom-matchers.d.ts:3
  • code/addons/vitest/src/node/boot-test-runner.ts:17 reaches into another package with a relative path (../../../../core/src/shared/utils/module.ts) — import the package by name instead. — code/addons/vitest/src/node/boot-test-runner.ts:17
  • code/addons/vitest/src/postinstall.ts:33 reaches into another package with a relative path (../../../lib/cli-storybook/src/add.ts) — import the package by name instead. — code/addons/vitest/src/postinstall.ts:33
  • code/addons/vitest/src/vitest-plugin/agent-telemetry-reporter.ts:11 reaches into another package with a relative path (../../../../core/src/shared/utils/ai-checklist-flags.ts) — import the package by name instead. — code/addons/vitest/src/vitest-plugin/agent-telemetry-reporter.ts:11
  • code/addons/vitest/src/vitest-plugin/index.ts:44 reaches into another package with a relative path (../../../../builders/builder-vite/src/utils/without-vite-plugins.ts) — import the package by name instead. — code/addons/vitest/src/vitest-plugin/index.ts:44
  • code/builders/builder-vite/src/plugins/code-generator-plugin.ts:9 reaches into another package with a relative path (../../../../core/src/shared/utils/module.ts) — import the package by name instead. — code/builders/builder-vite/src/plugins/code-generator-plugin.ts:9
  • code/core/src/component-testing/components/Panel.tsx:24 reaches into another package with a relative path (../../../../addons/vitest/src/constants.ts) — import the package by name instead. — code/core/src/component-testing/components/Panel.tsx:24
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:8 imports react-syntax-highlighter/dist/esm/create-element, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:8
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:9 imports react-syntax-highlighter/dist/esm/languages/prism/bash, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:9
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:10 imports react-syntax-highlighter/dist/esm/languages/prism/css, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:10
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:11 imports react-syntax-highlighter/dist/esm/languages/prism/graphql, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:11
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:13 imports react-syntax-highlighter/dist/esm/languages/prism/js-extras, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:13
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:14 imports react-syntax-highlighter/dist/esm/languages/prism/json, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:14
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:15 imports react-syntax-highlighter/dist/esm/languages/prism/jsx, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:15
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:16 imports react-syntax-highlighter/dist/esm/languages/prism/markdown, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:16
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:17 imports react-syntax-highlighter/dist/esm/languages/prism/markup, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:17
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:18 imports react-syntax-highlighter/dist/esm/languages/prism/tsx, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:18
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:19 imports react-syntax-highlighter/dist/esm/languages/prism/typescript, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:19
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:20 imports react-syntax-highlighter/dist/esm/languages/prism/yaml, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:20
  • code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:22 imports react-syntax-highlighter/dist/esm/prism-light, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead. — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:22
  • code/core/src/core-server/stores/test-provider.ts:1 imports code/core/src/shared/test-provider-store/index.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on. — code/core/src/core-server/stores/test-provider.ts:1
  • code/core/src/core-server/stores/test-provider.ts:2 imports code/core/src/shared/test-provider-store/index.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on. — code/core/src/core-server/stores/test-provider.ts:2
  • code/core/src/core-server/utils/manifests/render-components-manifest.ts:9 reaches into another package with a relative path (../../../../../renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts) — import the package by name instead. — code/core/src/core-server/utils/manifests/render-components-manifest.ts:9
  • code/core/src/core-server/utils/warnOnIncompatibleAddons.ts:4 reaches into another package with a relative path (../../../../lib/cli-storybook/src/doctor/getIncompatibleStorybookPackages.ts) — import the package by name instead. — code/core/src/core-server/utils/warnOnIncompatibleAddons.ts:4
  • code/core/src/csf/core-annotations.ts:13 imports code/core/src/test/preview.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on. — code/core/src/csf/core-annotations.ts:13
  • code/core/src/manager-api/stores/test-provider.ts:1 imports code/core/src/shared/test-provider-store/index.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on. — code/core/src/manager-api/stores/test-provider.ts:1
  • code/core/src/manager-api/stores/test-provider.ts:2 imports code/core/src/shared/test-provider-store/index.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on. — code/core/src/manager-api/stores/test-provider.ts:2
  • code/core/src/manager/manager-stores.mock.ts:20 imports code/core/src/shared/test-provider-store/index.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on. — code/core/src/manager/manager-stores.mock.ts:20
  • code/core/src/manager/manager-stores.mock.ts:21 imports code/core/src/shared/test-provider-store/index.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on. — code/core/src/manager/manager-stores.mock.ts:21
  • code/core/src/shared/checklist-store/checklistData.tsx:25 reaches into another package with a relative path (../../../../addons/a11y/src/constants.ts) — import the package by name instead. — code/core/src/shared/checklist-store/checklistData.tsx:25
  • code/core/src/shared/checklist-store/checklistData.tsx:26 reaches into another package with a relative path (../../../../addons/onboarding/src/constants.ts) — import the package by name instead. — code/core/src/shared/checklist-store/checklistData.tsx:26
  • code/core/src/shared/checklist-store/checklistData.tsx:30 reaches into another package with a relative path (../../../../addons/vitest/src/constants.ts) — import the package by name instead. — code/core/src/shared/checklist-store/checklistData.tsx:30
  • REDACTED:6 reaches past another workspace package's public entry into its internals with a relative path (../lib/cli-storybook/src/sandbox-templates.ts) — the test is coupled to a file layout that package makes no promise about, so a refactor behind its entry point breaks the suite. Import the package by name instead. — REDACTED:6

What to do

  • Fix the listed violations: import through the target package's declared public entry rather than a deep path into its internals or a relative path into its directory (184 rows); move the shared test helper into a source directory production code may depend on (9 rows); declare the workspace packages these files import in the importing package's own REDACTED dependencies (2 rows) — those imports are already bare package specifiers, so the import statements do not change, only the manifest.
R2 · Cyclomatic Complexity8.0 / 10Strong✓ Tool-verified

React / JS · Code Health — Per-function cyclomatic/cognitive complexity from the token-level function scanner (D-386) — real branching, not a regex heuristic.

Method: Per-function cyclomatic/cognitive complexity from a token-level function scanner (real branching, not a regex heuristic), computed over every frontend function. Deterministic.

  • (anonymous) has cyclomatic complexity 85 and cognitive complexity 95; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/csf-tools/estree/scope.ts:569
  • _visitExportNamed has cyclomatic complexity 58 and cognitive complexity 142; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — REDACTED:891
  • handleShortcutFeature has cyclomatic complexity 51 and cognitive complexity 50; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/manager-api/modules/shortcuts.ts:291
  • (anonymous) has cyclomatic complexity 48 and cognitive complexity 70; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/csf-tools/ConfigObject.ts:81
  • renderComponentCard has cyclomatic complexity 48 and cognitive complexity 46; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/core-server/utils/manifests/render-components-manifest.ts:973
  • TestProviderRender has cyclomatic complexity 47 and cognitive complexity 43; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/addons/vitest/src/components/TestProviderRender.tsx:98
  • groupValues has cyclomatic complexity 45 and cognitive complexity 77; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/csf-tools/CsfObject.ts:692
  • buildDevStandalone has cyclomatic complexity 45 and cognitive complexity 60; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/core-server/build-dev.ts:75
  • upgrade has cyclomatic complexity 44 and cognitive complexity 71; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/lib/cli-storybook/src/upgrade.ts:352
  • runComputerAction has cyclomatic complexity 43 and cognitive complexity 53; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — agent-eval/lib/mcp/claude-browser-mock.mjs:1429
  • (anonymous) has cyclomatic complexity 41 and cognitive complexity 93; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/csf-tools/ConfigFile.ts:539
  • transformDirective has cyclomatic complexity 40 and cognitive complexity 45; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:520
  • generateDummyValueFromSBType has cyclomatic complexity 40 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/core-server/utils/get-dummy-args-from-argtypes.ts:146
  • readForwardableSetup has cyclomatic complexity 39 and cognitive complexity 52; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts:90
  • serializeComponentDoc has cyclomatic complexity 38 and cognitive complexity 60; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1404
  • postInstall has cyclomatic complexity 37 and cognitive complexity 68; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/addons/vitest/src/postinstall.ts:58
  • runFixes has cyclomatic complexity 37 and cognitive complexity 65; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/lib/cli-storybook/src/automigrate/index.ts:253
  • scanShellWords has cyclomatic complexity 37 and cognitive complexity 63; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — agent-eval/lib/shell-parse.ts:438
  • parseToolsTokens has cyclomatic complexity 35 and cognitive complexity 58; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/core/src/cli/tools/tool-tokens.ts:44
  • (anonymous) has cyclomatic complexity 35 and cognitive complexity 43; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — code/frameworks/angular-vite/src/docgen/story-docs-args.ts:125

What to do

  • Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5.
R3 · Large Files8.5 / 10Strong✓ Tool-verified

React / JS · Code Health — How many source files exceed the large-file threshold.

Method: Components/modules exceeding the large-file threshold, counted exhaustively across the frontend source tree. Deterministic.

  • agent-eval/lib/agentic-reference/comparison/html-report.ts has 3345 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — agent-eval/lib/agentic-reference/comparison/html-report.ts:1
  • agent-eval/lib/mcp/claude-browser-mock.mjs has 1966 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — agent-eval/lib/mcp/claude-browser-mock.mjs:1
  • code/core/src/csf-tools/estree/editor.ts has 1732 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/csf-tools/estree/editor.ts:1
  • code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts has 1678 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1
  • scripts/eval/collect-pr-data.ts has 1423 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — scripts/eval/collect-pr-data.ts:1
  • REDACTED has 1382 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — REDACTED:1
  • code/core/src/core-server/utils/manifests/render-components-manifest.ts has 1364 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/core-server/utils/manifests/render-components-manifest.ts:1
  • code/core/src/components/components/Select/Select.stories.tsx has 1319 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/components/components/Select/Select.stories.tsx:1
  • code/core/src/shared/checklist-store/checklistData.tsx has 1297 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/shared/checklist-store/checklistData.tsx:1
  • code/core/src/manager/components/sidebar/Tree.stories.tsx has 1276 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/manager/components/sidebar/Tree.stories.tsx:1
  • code/core/src/manager-api/modules/stories.ts has 1263 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/manager-api/modules/stories.ts:1
  • code/core/src/server-errors.ts has 1192 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/server-errors.ts:1
  • scripts/tasks/sandbox-parts.ts has 1187 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — scripts/tasks/sandbox-parts.ts:1
  • agent-eval/lib/test-utils.ts has 1140 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — agent-eval/lib/test-utils.ts:1
  • code/lib/cli-storybook/src/sandbox-templates.ts has 1140 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/lib/cli-storybook/src/sandbox-templates.ts:1
  • agent-eval/lib/templates.ts has 1080 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — agent-eval/lib/templates.ts:1
  • code/core/src/components/components/Modal/Modal.stories.tsx has 1074 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/components/components/Modal/Modal.stories.tsx:1
  • code/core/src/shared/open-service/query-runtime.ts has 1059 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/shared/open-service/query-runtime.ts:1
  • code/core/src/csf-tools/ConfigFile.ts has 1054 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/csf-tools/ConfigFile.ts:1
  • scripts/eval/lib/baseline-template-files.ts has 1041 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — scripts/eval/lib/baseline-template-files.ts:1
  • code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts has 1005 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:1
  • code/core/src/csf-tools/CsfObject.ts has 936 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/csf-tools/CsfObject.ts:1
  • agent-eval/lib/mcp/codex-browser-client-mock.mjs has 916 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — agent-eval/lib/mcp/codex-browser-client-mock.mjs:1
  • code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts has 891 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:1
  • code/core/src/types/modules/core-common.ts has 873 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/types/modules/core-common.ts:1
  • code/core/src/common/js-package-manager/JsPackageManager.ts has 846 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/common/js-package-manager/JsPackageManager.ts:1
  • code/core/src/csf-tools/estree/scope.ts has 841 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/csf-tools/estree/scope.ts:1
  • code/core/src/core-server/utils/StoryIndexGenerator.ts has 811 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/core-server/utils/StoryIndexGenerator.ts:1
  • code/core/src/manager/components/sidebar/Tree.tsx has 802 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/manager/components/sidebar/Tree.tsx:1
  • agent-eval/lib/agentic-reference/post-analysis.ts has 768 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — agent-eval/lib/agentic-reference/post-analysis.ts:1
  • code/core/src/csf-tools/story-shape/resolve-members.ts has 764 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/csf-tools/story-shape/resolve-members.ts:1
  • scripts/eval/run-batch.ts has 755 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — scripts/eval/run-batch.ts:1
  • code/core/src/instrumenter/instrumenter.ts has 743 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/instrumenter/instrumenter.ts:1
  • code/core/src/common/js-package-manager/PNPMProxy.ts has 736 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/common/js-package-manager/PNPMProxy.ts:1
  • code/core/src/manager/components/review/ReviewPage.stories.tsx has 736 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/manager/components/review/ReviewPage.stories.tsx:1
  • code/lib/cli-storybook/src/util.ts has 736 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/lib/cli-storybook/src/util.ts:1
  • code/core/src/csf-tools/CsfObjectDiscovery.ts has 722 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/csf-tools/CsfObjectDiscovery.ts:1
  • code/core/src/cli/skills/content/setup-prompts/pattern-copy-play.ts has 679 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/cli/skills/content/setup-prompts/pattern-copy-play.ts:1
  • scripts/ci/common-jobs.ts has 658 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — scripts/ci/common-jobs.ts:1
  • code/core/src/shared/open-service/service-transport.ts has 651 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — code/core/src/shared/open-service/service-transport.ts:1

What to do

  • Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.
R4 · Test Coverage8.7 / 10Strong✓ Tool-verified

React / JS · Readiness — Static test reachability (D-386): the share of production files reachable from any test via the import graph — measured without running anything.

Method: Static test reachability: the share of production files reachable from any test via the import graph — measured without running anything. Deterministic.

  • agent-eval/evals/821-upgrade-from-sb9/stories/Button.stories.tsx:2 imports '../src/components/Button', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — agent-eval/evals/821-upgrade-from-sb9/stories/Button.stories.tsx:2
  • agent-eval/evals/822-upgrade-from-stable/stories/Button.stories.tsx:2 imports '../src/components/Button', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — agent-eval/evals/822-upgrade-from-stable/stories/Button.stories.tsx:2
  • agent-eval/evals/823-setup-outdated-storybook/stories/Button.stories.tsx:2 imports '../src/components/Button', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — agent-eval/evals/823-setup-outdated-storybook/stories/Button.stories.tsx:2
  • code/core/src/csf-tools/__corpus__/inputs/core-interleavedExports.stories.ts:3 imports './import', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/core/src/csf-tools/__corpus__/inputs/core-interleavedExports.stories.ts:3
  • code/core/src/csf-tools/__corpus__/inputs/edge-legacy.stories.tsx:3 imports './Button', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/core/src/csf-tools/__corpus__/inputs/edge-legacy.stories.tsx:3
  • code/core/src/csf-tools/__corpus__/inputs/react-js-argtypes.stories.jsx:10 imports './docgen-components/9586-js-react-memo/input.jsx', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either (3 further unresolvable import(s) in the same file). The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/core/src/csf-tools/__corpus__/inputs/react-js-argtypes.stories.jsx:10
  • code/core/src/csf-tools/__corpus__/inputs/react-test-fn.stories.tsx:7 imports './preview', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/core/src/csf-tools/__corpus__/inputs/react-test-fn.stories.tsx:7
  • code/core/src/csf-tools/__corpus__/inputs/shapes-angular-button.stories.ts:5 imports './templates.ts', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/core/src/csf-tools/__corpus__/inputs/shapes-angular-button.stories.ts:5
  • code/lib/docgen-harness/src/svelte/server-metadata.test.ts:18 imports './story-docs/__fixtures__/legacy-metadata/', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/lib/docgen-harness/src/svelte/server-metadata.test.ts:18
  • code/renderers/svelte/src/docgen/component-docgen/__testfixtures__/subcomponents/plain.stories.ts:3 imports './Missing.svelte', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/renderers/svelte/src/docgen/component-docgen/__testfixtures__/subcomponents/plain.stories.ts:3
  • code/renderers/svelte/src/docgen/component-docgen/__testfixtures__/unresolved/missing.stories.ts:1 imports './Missing.svelte', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/renderers/svelte/src/docgen/component-docgen/__testfixtures__/unresolved/missing.stories.ts:1
  • code/renderers/vue3/src/docgen/component-docgen/__testfixtures__/MissingImportComponent.stories.ts:1 imports './DoesNotExist.vue', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — code/renderers/vue3/src/docgen/component-docgen/__testfixtures__/MissingImportComponent.stories.ts:1
  • test-storybooks/ember-cli/app/app.js:4 imports './config/environment', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — test-storybooks/ember-cli/app/app.js:4
  • test-storybooks/ember-cli/app/router.js:3 imports './config/environment', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing. — test-storybooks/ember-cli/app/router.js:3
  • No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one. (×26) — scripts/snippets/codemod.ts:1, scripts/task.ts:1, agent-eval/scripts/run-plan.ts:1, …

What to do

  • Add tests that import the unreached modules (directly or through their public entry).
R6 · Tooling10.0 / 10Exemplary✓ Tool-verified

React / JS · Readiness — Whether the project wires up test, lint and typecheck — detected from each REDACTED script's COMMAND (eslint / tsc / vitest / jest / playwright), not just its name, and corroborated against CI-workflow invocations so a tool run only in CI still counts.

Method: REDACTED scanned for test/lint/typecheck script wiring. Deterministic presence check.

  • This repository declares test tooling, and the ✓ above records that declaration — but agent-eval/evals/821-upgrade-from-sb9/stories/Button.stories.tsx and 13 other test file(s) in this workspace cannot be loaded at all: it imports a module that names no file in this repository, so the runner throws while collecting it and none of its cases execute. The wiring is present and the suite it points at does not run as written, which is why the tooling tick must not be read as a statement that the tests pass. Fix the unloadable file(s) — each one is reported with its failing import under Test Coverage — then the declared script exercises what it claims to. — agent-eval/evals/821-upgrade-from-sb9/stories/Button.stories.tsx:2
R7 · Dead Code7.6 / 10Strong✓ Tool-verified

React / JS · Code Health — Files unreachable from every application/tooling/test entry point, and exports nothing imports (module-graph reachability, D-386).

Method: Dead code: files unreachable from every application/tooling/test entry point plus exports nothing imports, via module-graph reachability. Deterministic, exhaustive over the import graph.

  • 2 file(s) (~72 LoC) were excluded from dead-code analysis — declare main/module/exports or a conventional entry (src/index.*, an index.html script) so reachability can see this package.
  • 1 file(s) (~9 LoC) were excluded from dead-code analysis — declare main/module/exports or a conventional entry (src/index.*, an index.html script) so reachability can see this package. (×2) — agent-eval/evals/701-new-ui-flow, agent-eval/evals/702-rework-ui-flow
  • Unreachable from the 901 application, 230 tooling and 2121 test entry point(s) detected in this repo. Gate removals on `yarn run typecheck` — an undetected custom entry would make these reachable.
  • no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make (×27) — agent-eval/lib/mcp/codex-browser-client-mock.mjs, code/renderers/react/template/stories/docgen-components/js-proptypes/input.jsx, scripts/display-review.ts, …
  • no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/frameworks/ember/src/client/preview/config.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it (×2) — code/frameworks/ember/src/client/preview/render.ts, code/frameworks/ember/src/client/preview/jsondoc.ts
  • no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (code/renderers/vue3/template/stories_vue3-vite-default-ts/component-meta/reference-type-props/component-js-setup.vue, code/renderers/vue3/template/stories_vue3-vite-default-ts/component-meta/reference-type-props/component-js.vue) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — code/renderers/vue3/template/stories_vue3-vite-default-ts/component-meta/reference-type-props/my-props.ts
  • no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/renderers/web-components/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it (×2) — code/renderers/web-components/template/components/Form.js, code/renderers/web-components/template/components/Button.js
  • no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/renderers/vue3/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — code/renderers/vue3/template/components/Button.vue
  • no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/frameworks/angular-vite/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — code/frameworks/angular-vite/template/components/button.component.ts
  • no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/frameworks/angular/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — code/frameworks/angular/template/components/button.component.ts
  • no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/renderers/react/template/stories/docgen-components/js-re-exported-component/input.jsx) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — code/renderers/react/template/stories/docgen-components/js-function-component/input.jsx

What to do

  • Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value.
R8 · Dependency Hygiene0.0 / 10Critical✓ Tool-verified

React / JS · Readiness — npm dependency truthfulness (D-386): unused dependencies, imports not declared anywhere, and type-/test-only packages shipped as production deps.

Method: npm dependency truthfulness: unused dependencies, imports declared nowhere, and type-/test-only packages shipped as production deps — from the manifest + import graph. Deterministic.

  • Imported but not declared in any reachable REDACTED — installs work only by hoisting accident. (×24) — agent-eval/app/compare/page.tsx:1, agent-eval/evals/803-edit-component/src/components/ReviewCard.tsx:1, agent-eval/evals/804-write-story-for-existing-component/src/components/AlertBanner.tsx:2, …
  • Imported only as a TYPE and declared in no reachable REDACTED. The import is erased at compile time, so nothing is installed and no runtime resolution depends on it — but type-checking a clean clone will fail. Declare the typings it resolves through (or the package itself) in the owning REDACTED. — code/addons/mcp/src/tools/toolset-tools.ts:9
  • Declared in code/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
  • Declared in code/addons/a11y/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
  • Declared in code/addons/vitest/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
  • Every import is type-only — move it to devDependencies. — code/renderers/svelte/src/preview.ts:26

What to do

  • Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.
R9 · Circular Imports0.0 / 10Critical✓ Tool-verified

React / JS · Architecture — Import cycles in the module graph (D-386) — files that can only be understood and changed together.

Method: Import cycles in the module graph, detected exhaustively over JS/TS imports (the same cycle detection as the .NET coupling dimension). Deterministic.

  • agent-eval/lib/agentic-reference/cases.ts → agent-eval/lib/agentic-reference/experiment.ts → agent-eval/lib/agentic-reference/post-analysis.ts → agent-eval/lib/agentic-reference/comparability.ts → agent-eval/lib/agentic-reference/identity.ts → agent-eval/lib/agentic-reference/cases.ts — agent-eval/lib/agentic-reference/cases.ts:13
  • code/addons/links/src/index.ts → code/addons/links/src/preview.ts → code/addons/links/src/index.ts — code/addons/links/src/index.ts:3
  • code/builders/builder-vite/src/preset.ts → code/builders/builder-vite/src/vite-config.ts → code/builders/builder-vite/src/preset.ts — code/builders/builder-vite/src/preset.ts:13
  • code/core/src/actions/addArgs.ts → code/core/src/actions/addArgsHelpers.ts → code/core/src/actions/runtime/action.ts → code/core/src/preview-api/index.ts → code/core/src/preview-api/modules/store/csf/index.ts → code/core/src/preview-api/modules/store/csf/composeConfigs.ts → code/core/src/preview-api/modules/store/csf/beforeAll.ts → code/core/src/csf/index.ts → code/core/src/csf/core-annotations.ts → code/core/src/actions/preview.ts → code/core/src/actions/addArgs.ts (one verified cycle inside a mutually-dependent group of 48 files) — code/core/src/actions/addArgs.ts:3
  • code/core/src/builder-manager/index.ts → code/core/src/builder-manager/utils/data.ts → code/core/src/builder-manager/index.ts — code/core/src/builder-manager/index.ts:22
  • code/core/src/common/index.ts → code/core/src/common/utils/get-story-id.ts → code/core/src/common/index.ts (one verified cycle inside a mutually-dependent group of 9 files) — code/core/src/common/index.ts:49
  • code/core/src/common/js-package-manager/JsPackageManager.ts → code/core/src/common/js-package-manager/util.ts → code/core/src/common/js-package-manager/JsPackageManager.ts — code/core/src/common/js-package-manager/JsPackageManager.ts:23
  • code/core/src/common/utils/get-framework-name.ts → code/core/src/common/utils/get-storybook-info.ts → code/core/src/common/utils/get-framework-name.ts (one verified cycle inside a mutually-dependent group of 3 files) — code/core/src/common/utils/get-framework-name.ts:5
  • code/core/src/components/components/Modal/Modal.styled.tsx → code/core/src/components/components/Modal/Modal.tsx → code/core/src/components/components/Modal/Modal.styled.tsx — code/core/src/components/components/Modal/Modal.styled.tsx:15
  • code/core/src/components/components/Select/Select.tsx → code/core/src/components/components/Select/SelectOption.tsx → code/core/src/components/index.ts → code/core/src/components/components/Select/Select.tsx — code/core/src/components/components/Select/Select.tsx:19
  • REDACTED → code/core/src/csf-tools/CsfObjectDiscovery.ts → REDACTED — REDACTED:29
  • code/core/src/manager-api/index.mock.ts → code/core/src/manager-api/stores/__mocks__/status.ts → code/core/src/manager-api/index.mock.ts (one verified cycle inside a mutually-dependent group of 3 files) — code/core/src/manager-api/index.mock.ts:12
  • code/core/src/manager-api/root.tsx → code/core/src/manager-api/modules/globals.ts → code/core/src/manager-api/lib/events.ts → code/core/src/manager-api/modules/refs.ts → code/core/src/manager-api/lib/stories.ts → code/core/src/manager-api/root.tsx (one verified cycle inside a mutually-dependent group of 10 files) — code/core/src/manager-api/root.tsx:55
  • code/core/src/manager/components/sidebar/Sidebar.tsx → code/core/src/manager/components/sidebar/Explorer.tsx → code/core/src/manager/components/sidebar/Refs.tsx → code/core/src/manager/components/sidebar/Sidebar.tsx (one verified cycle inside a mutually-dependent group of 10 files) — code/core/src/manager/components/sidebar/Sidebar.tsx:19
  • code/core/src/mocking-utils/extract.ts → code/core/src/mocking-utils/resolve.ts → code/core/src/mocking-utils/extract.ts — code/core/src/mocking-utils/extract.ts:13
  • code/lib/cli-storybook/src/autoblock/block-dependencies-versions.ts → code/lib/cli-storybook/src/autoblock/utils.ts → code/lib/cli-storybook/src/util.ts → code/lib/cli-storybook/src/autoblock/index.ts → code/lib/cli-storybook/src/autoblock/block-dependencies-versions.ts (one verified cycle inside a mutually-dependent group of 10 files) — code/lib/cli-storybook/src/autoblock/block-dependencies-versions.ts:4
  • code/lib/eslint-plugin/src/configs/flat/addon-interactions.ts → code/lib/eslint-plugin/src/index.ts → code/lib/eslint-plugin/src/configs/flat/addon-interactions.ts (one verified cycle inside a mutually-dependent group of 5 files) — code/lib/eslint-plugin/src/configs/flat/addon-interactions.ts:1
  • code/renderers/react/src/componentManifest/getComponentImports.ts → code/renderers/react/src/componentManifest/reactDocgen.ts → code/renderers/react/src/componentManifest/getComponentImports.ts — code/renderers/react/src/componentManifest/getComponentImports.ts:17
  • code/renderers/web-components/src/docgen/story-docs/html-tree.ts → code/renderers/web-components/src/docgen/story-docs/print-element.ts → code/renderers/web-components/src/docgen/story-docs/html-tree.ts — code/renderers/web-components/src/docgen/story-docs/html-tree.ts:1
  • scripts/ci/utils/helpers.ts → scripts/ci/utils/types.ts → scripts/ci/utils/helpers.ts — scripts/ci/utils/helpers.ts:3
  • scripts/sandbox/utils/getPort.ts → scripts/task.ts → scripts/tasks/bench.ts → scripts/tasks/dev.ts → scripts/sandbox/utils/getPort.ts (one verified cycle inside a mutually-dependent group of 7 files) — scripts/sandbox/utils/getPort.ts:2

What to do

  • Break each cycle by extracting the shared piece into a module both sides can import.
S1 · Web-Security Posture6.0 / 10Adequate✓ Tool-verified

Other · Security — Read from this repository's JavaScript/TypeScript source: cryptographic hygiene (weak hash or cipher, key material fixed in the source) and outbound TLS (certificate validation, protocol version) — facts about code that hold whether or not it serves anything itself. This repository commits the configuration that serves its own HTTP surface, so that configuration was read in full for the security response headers it sets. The server controls — HTTPS enforcement, HSTS, cookie flags, input validation — are NOT assessed for JavaScript/TypeScript: each is scored as an absence, an absence is only reportable over the production HTTP server, and in this ecosystem the file that opens the port is build output or a framework launcher rather than a file in the source tree. Their absence here is not a finding about this repository. Its Node HTTP listeners were read for HTTPS enforcement alone — TLS served, a redirect to https:// or HSTS, or a TLS-terminating proxy configuration committed beside the server — each judged per server package.

Method: Roslyn plus filesystem scan: HSTS/security headers, secure cookies, input validation, middleware order, weak crypto (MD5/SHA1/DES); HTTPS-metadata context-aware. On a repository with no .NET source it reads JavaScript/TypeScript, Dart, Ruby, Scala, Rust or Elixir source itself (test, vendored, generated and minified paths not) for the arms that hold whether or not the code serves HTTP: a weak hash or cipher, key material fixed in the source, a TLS client that accepts any certificate, and (JavaScript/TypeScript, Ruby, Scala, Rust and Elixir) an obsolete TLS version; the server controls are not assessed there, and a Dart, Ruby, Scala, Rust or Elixir repository that serves no HTTP of its own is N/A on them. Deterministic.

  • MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`createHash("sha256")`) for content integrity, or a KDF (bcrypt/Argon2/scrypt) for password storage. If it only derives a non-security identifier (a cache key, an avatar URL, an ETag), collision resistance carries no security consequence here; make that intent explicit instead — a non-cryptographic hash such as xxhash or murmurhash says it in code — since the algorithm alone cannot distinguish the two uses. Where a protocol this code does not own fixes the digest (a k-anonymity range query, a legacy signature format), the protocol decides; say so beside the call. — agent-eval/lib/checkout-registry-server.mjs:34
  • `server.listen(…)` serves plain HTTP on a network address, and nothing in its package enforces HTTPS: no TLS served (`https.createServer`, Fastify `https`, Nest `httpsOptions`), no redirect of plain requests to `https://`, no `Strict-Transport-Security` (helmet sends it by default), and no TLS-terminating proxy configuration committed beside it — so a browser may talk to it in clear text. (−2.0 on this card.) — scripts/event-log-collector.ts:118
  • `proxy.listen(…)` serves plain HTTP on a network address, and nothing in its package enforces HTTPS: no TLS served (`https.createServer`, Fastify `https`, Nest `httpsOptions`), no redirect of plain requests to `https://`, no `Strict-Transport-Security` (helmet sends it by default), and no TLS-terminating proxy configuration committed beside it — so a browser may talk to it in clear text. (−2.0 on this card.) — scripts/run-registry.ts:93
  • `app.listen(…)` serves plain HTTP on a network address, and nothing in its package enforces HTTPS: no TLS served (`https.createServer`, Fastify `https`, Nest `httpsOptions`), no redirect of plain requests to `https://`, no `Strict-Transport-Security` (helmet sends it by default), and no TLS-terminating proxy configuration committed beside it — so a browser may talk to it in clear text. (−2.0 on this card.) — scripts/run-registry.ts:109

What to do

  • Review each MD5/SHA1 use by what it protects: replace it with SHA-256+ (or a KDF for passwords) where the digest is security-relevant, and switch it to a non-cryptographic hash (xxhash, murmurhash) where it only derives an identifier such as a cache key.
  • Enforce HTTPS on each listed server: serve TLS itself, or redirect plain requests to `https://` and send `Strict-Transport-Security` (`helmet()` does by default) behind the TLS-terminating proxy — and commit that proxy's configuration beside the service. A server only this machine reaches should bind `127.0.0.1`.
X1 · Async correctness7.9 / 10Strong✓ Tool-verified

Other · Code Health — Whether the code avoids sync-over-async (deadlock-prone blocking on tasks) and async void.

Method: Roslyn syntax scan: async methods scanned for .Wait()/.GetAwaiter().GetResult() and async-void outside event handlers. Deterministic, hard fact per invocation.

  • `forEach` ignores what its callback returns, so the Promise each `async` call returns is dropped: nothing can await it, the code after this loop runs before any of the awaited work has finished (a function that `await`s around this loop still returns early), and a rejection is never handled — in Node.js an unhandled rejection terminates the process by default, and in a browser it is lost. Iterate with `for (const item of items) { await … }` when the work must run in order, or `await Promise.all(items.map(async (item) => { … }))` when it may run concurrently, so the enclosing function finishes only when the work does and its failures reach the caller. Where firing and forgetting is genuinely intended, make the callback's whole body a `try { … } catch (e) { … }` that handles the failure, so it cannot escape. (×3) — scripts/build-package.ts:172, scripts/check-package.ts:192, scripts/snippets/codemod.ts:453
  • The function passed to `new Promise(…)` is `async`. The constructor ignores what its executor returns, so anything this executor throws — every throw inside an `async` function, including after an `await` — rejects a Promise nobody holds instead of the one being constructed: the outer Promise never settles, whoever awaits it hangs, and the error is reported nowhere. If the body needs `await`, it does not need `new Promise` at all: make the enclosing function `async` and `return` the value (or `throw`) directly. If it wraps a callback API, keep the executor synchronous — call the API and `resolve`/`reject` from its callback — and do the awaiting outside it. (×3) — code/renderers/react/src/renderToCanvas.tsx:118, code/core/src/manager-api/modules/refs.ts:384, code/addons/vitest/src/node/vitest-manager.ts:189

What to do

  • `async` callback passed to `forEach`
X12 · Unreachable branch10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether any branch is dead by construction — a switch arm whose label can never equal a case-normalised subject, or an `else if` whose predicate the arm above has already swallowed.

Method: Roslyn syntax + semantics: switch labels compared against the subject's own case normaliser, and if/else-if chains checked for a literal an earlier arm's containment test already swallows. Deterministic, provable per finding. Advisory.

X13 · Undrained process stream5.4 / 10Adequate✓ Tool-verified

Other · Code Health — Whether a child process that has BOTH standard streams redirected drains both — reading one to the end while the other is never read deadlocks once the child fills the unread pipe.

Method: Roslyn syntax + semantics: ProcessStartInfo launches with both streams redirected, checked for a drain of each stream across the enclosing type. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same rule: a `spawn` imported from `child_process` whose stdout and stderr are both pipes (no options, no `stdio`, or `stdio` of `'pipe'`), bound to a local that never leaves its scope, where exactly one of the two streams is read, the other never, and the child’s `close`/`exit` (or the read stream’s end) is awaited; a shell redirect in the call’s arguments or a `kill` of the child suppresses it. The same rule reads Python’s `subprocess.Popen`, Dart’s `Process.start`, Ruby’s `Open3.popen3`, and Scala’s JDK process starts (`new ProcessBuilder(…).start()` with no `redirectErrorStream`/`redirectError`/`redirectOutput`/`inheritIO`, `Runtime.getRuntime.exec`) where one of `getInputStream`/`getErrorStream` is read and the other never while `waitFor()` is called or the read stream is read to its end. Deterministic, provable per finding. Advisory.

  • `spawn` pipes `stderr` here — it is given no `stdio` option, or `'pipe'` — but nothing in this scope ever reads `cleaningProcess.stderr`, while `cleaningProcess.stdout` is read and the child's end is awaited. Node holds an unread pipe's output only up to its buffer: once the child writes more than that to stderr (measured on Linux: about 128 KB — the 64 KB pipe plus Node's 64 KB read-ahead — and less elsewhere), the child blocks on the write, never exits, and the `close`/`exit` this code waits for never fires. Nothing fails loudly: the promise never settles, the request never returns, and the stuck child holds its resources until something kills it. Consume both streams (`cleaningProcess.stderr.on('data', …)`, or `cleaningProcess.stderr.resume()` to discard it), or stop piping the one you do not want — `stdio: ['pipe', 'pipe', 'inherit']` or `'ignore'` in that slot. — scripts/reset.js:12

What to do

  • Each finding names the span that makes the branch dead and the span it is dead because of. Confirm from the two, then delete the dead arm or fix the predicate that was meant to be reachable.
X14 · Bypassable address classification10.0 / 10Exemplary○ Nothing flagged

Other · Security — Whether a hand-rolled public/private IP check can be walked past — a method that unwraps IPv4-mapped IPv6 but returns the opposite verdict for the same host written as IPv4-compatible, 6to4 or NAT64.

Method: Roslyn syntax + semantics: methods that unwrap IPv4-mapped IPv6 and hand-roll IPv4 range carve-outs, checked for whether the IPv6 branch also accounts for the IPv4-compatible, 6to4 and NAT64 embeddings. Deterministic, provable per finding. Advisory.

X15 · Unvalidated length from an untrusted reader10.0 / 10Exemplary○ Nothing flagged

Other · Security — Whether a length read out of the stream being parsed is bounded before it is allocated or read — an unchecked count taken from the input lets the input choose the allocation.

Method: Roslyn syntax + semantics: integer lengths read from a BinaryReader and spent on a bulk read or an array allocation, checked for any comparison or bounding call on the value anywhere in the method. Deterministic, provable per finding. Advisory.

X16 · Unfloored truncation loop10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a loop that shortens a string until it fits a length budget has a floor — one with none grinds the value down to the empty string, or past it into a negative-length `Substring`.

Method: Roslyn syntax + semantics: while/do loops whose body's only effect on a string is to drop its last character, checked for whether anything — a direct comparison on the length, a body guard, a break — bounds that length below. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same rule: a `while`/`do` loop whose body’s one assignment to a value is `x = x.slice(0, -1)` or `x = x.slice|substring|substr(0, x.length - 1)`, driven by a condition that reads `x.length` only as a term of a larger expression — never compared directly, never tested for truthiness, and with no other read of `x` — and whose body has no `break`, `return`, `throw` or `if` naming `x`. Deterministic, provable per finding. Advisory.

X17 · Uncapped recursion over a caller-supplied document1.9 / 10Critical✓ Tool-verified

Other · Security — Whether a walk that recurses through a JSON/XML tree handed in by its caller bounds how deep it will go — an uncapped walk lets the document's nesting choose the stack depth, and the resulting StackOverflowException cannot be caught.

Method: Roslyn syntax + semantics: methods that take a JSON/XML document node and call themselves with a child of it, reachable from an externally-callable member of the same type that accepts a document, checked for any depth parameter, descent counter or threaded arithmetic anywhere in the walk. On a repository with no .NET source it reads TypeScript off the engine’s own token stream (test, vendored, generated and minified paths and `.d.ts` not) with the same rule: a function or method with a parameter typed as a document value — `unknown`, `any`, `object`, `Record<string, unknown|any>`, a JSON alias (`JsonValue`, `JSONObject`, …) or a DOM node global the file does not rebind — that calls itself (bare, or through `this` for a method, or hands itself to a call over the value as in `value.map(walk)`) with something it took out of that value and never through an ancestor accessor such as `closest()` or `parentElement`, that is exported or reached from an exported function (a public method of the same exported class) taking such a value, and that names no depth, level, nesting, recursion, remaining or budget anywhere and threads no `+`/`-` arithmetic through a self-call. Plain JavaScript is not read: with no annotation nothing tells a parsed document from a tree the code built itself. Deterministic, provable per finding. Advisory.

  • `stableStringify` is exported, takes a document from its caller (line 3) and hands it to `sortKeys`, which calls itself at line 6 (`sortKeys`) with a piece of `input` (and at line 12) — and nowhere in `sortKeys` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `sortKeys` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/lib/docgen-harness/src/sandbox-baselines/stable-stringify.ts:6
  • `deepEqual` is exported and takes `a: unknown` from its caller, and it calls itself at line 13 (`deepEqual`) with a piece of `a` (and at line 30) — and nowhere in `deepEqual` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `deepEqual` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/lib/docgen-harness/src/compare/deep-equal.ts:13
  • `isTanStackStartPlugin` is exported, takes a document from its caller (line 15) and hands it to `matchesPluginName`, which calls itself at line 3 (`matchesPluginName`) with a piece of `p` — and nowhere in `matchesPluginName` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `matchesPluginName` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/frameworks/tanstack-react/src/plugins/incompatible-plugins.ts:3
  • `formatInputValue` is exported, takes a document from its caller (line 50) and hands it to `formatJsonValue`, which calls itself at line 37 (`formatJsonValue`) with a piece of `value` (and at line 42) — and nowhere in `formatJsonValue` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `formatJsonValue` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/frameworks/angular-vite/src/template-grammar.ts:37
  • `deepMerge` is exported and takes `target: JsonObject` from its caller, and it calls itself at line 108 (`deepMerge`) with a piece of `target` — and nowhere in `deepMerge` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `deepMerge` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/frameworks/angular/src/server/framework-preset-angular-cli.ts:108
  • `serializeError` is exported, takes a document from its caller (line 86) and hands it to `toTransportSafe`, which calls itself at line 53 (`toTransportSafe`) with a piece of `value` (and at line 59) — and nowhere in `toTransportSafe` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `toTransportSafe` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/core/src/shared/open-service/service-error-serialization.ts:53
  • `applyStatePatch` is exported, takes a document from its caller (line 137) and hands it to `mergeInto`, which calls itself at line 163 (`mergeInto`) with a piece of `target` — and nowhere in `mergeInto` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `mergeInto` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/core/src/shared/open-service/service-sync.ts:163
  • `errorToErrorLike` is exported and takes `error: unknown` from its caller, and it calls itself at line 62 (`errorToErrorLike`) with a piece of `error` — and nowhere in `errorToErrorLike` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `errorToErrorLike` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/core/src/shared/open-service/services/module-graph/types.ts:62
  • `deepDiff` is exported and takes `value: any` from its caller, and it calls itself at line 57 (`deepDiff`) with a piece of `value` (and at line 72) — and nowhere in `deepDiff` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `deepDiff` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/core/src/router/utils.ts:57
  • `combineArgs` is exported and takes `value: any` from its caller, and it calls itself at line 91 (`combineArgs`) with a piece of `value` (and at line 104) — and nowhere in `combineArgs` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `combineArgs` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/core/src/preview-api/modules/store/args.ts:91
  • `deepDiff` is exported and takes `value: any` from its caller, and it calls itself at line 180 (`deepDiff`) with a piece of `value` (and at line 195) — and nowhere in `deepDiff` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `deepDiff` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/core/src/preview-api/modules/store/args.ts:180
  • `printValue` is exported and takes `value: unknown` from its caller, and it calls itself at line 605 (`printValue`) with a piece of `value` (and at line 612) — and nowhere in `printValue` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `printValue` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/core/src/csf-tools/estree/editor.ts:605
  • `nodeWithoutParse` is exported and takes `value: unknown` from its caller, and it calls itself at line 106 (`nodeWithoutParse`) with a piece of `value` — and nowhere in `nodeWithoutParse` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `nodeWithoutParse` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack. — code/core/src/csf-tools/estree/values.ts:106

What to do

  • Each finding names the externally-callable member that accepts the document and the self-call that descends, and states that no depth parameter or counter exists anywhere in the walk. Confirm from the two, then thread a depth argument through the walk and reject documents past a fixed maximum, or rewrite it with an explicit stack.
X18 · Disposal-pattern correctness10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a type's disposal matches what it OWNS — releasing what it created, leaving alone what it was handed, and not declaring a finalizer for state that has nothing unmanaged to finalize.

Method: Roslyn syntax + semantics: every assignment to a disposable field is read to decide whether the type CREATED the value or was handed it, and the type's disposal is checked against that answer — an injected interface it disposes, a value it constructed and never releases, a finalizer on a type holding nothing unmanaged, and a disposable local whose every reference is a plain member read. A value handed to a container that disposes its contents (a parent control's `Controls` collection, a component `IContainer`) is released by that container and is not reported; generated code is out of population. On a repository with no .NET source the same ownership questions are read in JavaScript/TypeScript off the engine’s own token stream (test, vendored, generated and minified paths not): a class declaring `dispose()`, `[Symbol.dispose]()` or `[Symbol.asyncDispose]()` that disposes a field it was handed through a constructor parameter typed as a repository interface or resolved by a dependency-injection container; that assigns a field only ever from `new X(…)` of a disposable class and neither releases it anywhere in the class nor names it in its disposal member or a method that member calls, nor hands it to anything else; and a `const`/`let` local built from literals only whose every reference opens a statement operating on a non-release member of it. A class is disposable when every repository declaration of its name declares or inherits a disposal member, or when it is a documented library disposable (`vscode` EventEmitter, CancellationTokenSource and Disposable; three.js geometries, materials, textures, render targets, renderers, controls and composers). The finalizer arm has no JavaScript counterpart: a class cannot declare one. Dart is read for the owned-and-never-released arm: a Flutter `State` (or a class declaring `dispose()`/`close()`) whose library-private field is written only with direct creations of a framework controller, `FocusNode`, `StreamController` or periodic `Timer` (or a `.listen(…)` into a field declared `StreamSubscription`), which nothing in the class or its library releases (`dispose`/`close`/`cancel`) and which is never handed on except as a named argument. Ruby is read for the owned-and-never-released arm and the abandoned-local arm: a class declaring an instance `close`, `dispose`, `shutdown`, `stop`, `disconnect` or `terminate` whose instance variable is written only with a blockless core descriptor creation (`File.open`/`new`, `Tempfile`, `Dir.open`, `IO.popen`, the `socket` and `openssl` socket classes) that no method of the class closes and that is never handed on (passed, returned, stored, exposed by `attr_reader`, delegated) — a class whose superclass or mixin lies outside the repository is not judged — and a blockless creation read through and dropped (`File.open(path).read`) or held in a local that is never closed, returned, passed or stored (a `&:read` block-pass, an `autoclose: false` borrow and a `fileno` hand-over are not abandonment). PHP is read for the same two arms: a class (not a trait, and not one using a trait) declaring an instance `close`, `dispose`, `shutdown`, `stop`, `disconnect` or `terminate` whose `private` property (or a `final` class's `protected` one) is written only with a direct core `fopen`, `tmpfile`, `popen`, `proc_open`, `fsockopen`, `stream_socket_client`/`server` or `opendir` that nothing in the class closes (`fclose`, `pclose`, `closedir`, `unset`, a reset to `null`) and that is never handed on, and a handle held in a function's local, or read through as the argument of a reader, that is never closed, returned, passed, captured or stored; a `php://` stream, `curl_init`, `SplFileObject`, `PDO` and a function the repository declares under the core name are not read. Deterministic, provable per finding. Advisory.

X19 · Unrestored process-global state5.1 / 10Adequate✓ Tool-verified

Other · Code Health — Whether a method that temporarily changes state belonging to the whole process — the working directory, an environment variable — puts it back on EVERY path: a restore reached only when nothing throws leaks the change to the rest of the process.

Method: Roslyn syntax + semantics: method bodies that write the process working directory or an environment variable and write it back in the same body, checked for whether that restore sits in a `finally`/`catch` or only on the straight-line path. On a repository with no .NET source the same rule reads production JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not): `process.chdir`, `process.env.NAME =`/`["NAME"] =` and `delete process.env.NAME`, and Deno’s `Deno.chdir`/`Deno.env.set`/`Deno.env.delete`, paired per function body (a nested function or arrow is its own body, and module top-level code is none), where the last write puts back a local the body captured from the same global or deletes a variable the first write set, with at least one statement between them; a write in a `catch`/`finally` of that body silences it. Deterministic, provable per finding. Advisory.

  • `sandbox` changes state that belongs to the whole PROCESS and changes it back at the end of the same body — the process working directory (changed at line 223, put back at line 234) — which says the change was meant to last no longer than this call. But the restore is an ordinary statement on the straight-line path, not a `finally`, so it is skipped by any exception thrown in between — or by a promise that rejects at an `await`, and while this function is suspended at one every other callback the event loop runs sees the moved value too: the process then keeps the overwritten value for the rest of its life, and every later relative path, child-process launch or config read in ANY module resolves against it. That failure is silent and remote from its cause — the function that breaks is not the function that moved the directory. The durable fix is not to widen the restore but to stop mutating the global: pass the value to the operation that needs it — the `cwd` and `env` options of `child_process.spawn`/`exec`/`execSync` (or `Deno.Command`) scope both to the CHILD — or build absolute paths with `path.resolve`. Where the global genuinely must move, wrap it `try`/`finally` so the restore runs on every path. — code/lib/cli-storybook/src/sandbox.ts:35
  • this arrow function changes state that belongs to the whole PROCESS and changes it back at the end of the same body — the `__NEXT_PRIVATE_RENDER_WORKER` environment variable (set at line 48, put back at line 55) — which says the change was meant to last no longer than this call. But the restore is an ordinary statement on the straight-line path, not a `finally`, so it is skipped by any exception thrown in between: the process then keeps the overwritten value for the rest of its life, and every later relative path, child-process launch or config read in ANY module resolves against it. That failure is silent and remote from its cause — the function that breaks is not the function that moved the directory. The durable fix is not to widen the restore but to stop mutating the global: pass the value to the operation that needs it — the `cwd` and `env` options of `child_process.spawn`/`exec`/`execSync` (or `Deno.Command`) scope both to the CHILD — or build absolute paths with `path.resolve`. Where the global genuinely must move, wrap it `try`/`finally` so the restore runs on every path. — REDACTED:38

What to do

  • Each finding names the statement that changes the process-global value and the statement that puts it back. Confirm from the two that nothing between them is protected — then prefer removing the mutation over widening the restore: a working directory or an environment variable passed to the operation that needs it (the `cwd` and `env` options of `child_process`, or of `Deno.Command`) is scoped to that operation, which is what the save-and-restore was trying to approximate. Where the global genuinely must move, a `try`/`finally` is the least that makes the restore unconditional. In Python the same holds for `os.chdir`, `os.environ` and `sys.stdout`: pass `cwd=`/`env=` to `subprocess`, or use `contextlib.chdir`/`redirect_stdout`, rather than moving the global by hand.
X2 · Cancellation propagation6.4 / 10Adequate✓ Tool-verified

Other · Code Health — Whether async functions that make a cancellable request accept or pass on an AbortSignal (adoption curve).

Method: Roslyn scan: every async method (excluding framework-fixed overrides/Blazor handlers) checked for CancellationToken parameter presence. Deterministic, adoption percentage. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same question: every named async function that itself makes a request an AbortSignal can cancel (global `fetch`, axios and its file-local instances, ky, ofetch) counts, and it is compliant when its parameters or body name a signal or it hands one of its own parameters to the request as options; signatures a framework fixes (JSX event handlers, route and lifecycle exports, request-first handlers, `override`, `'use server'` modules, TanStack `mutationFn`) are exempt unless they take a signal. Deterministic, adoption percentage.

  • Only 12/30 async functions that make a cancellable request (fetch, axios, ky, ofetch) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, an unmounted component, a timed-out job. Take a `signal` (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
  • `run` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — scripts/event-log-checker.ts:20
  • `uploadToGithub` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — scripts/upload-bench.ts:83
  • `FetchStoryHtmlType` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/renderers/server/src/render.ts:13
  • `manifestProvider` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. (×2) — code/lib/mcp/bin.ts:65, code/lib/mcp/serve.ts:10
  • `getStoryIndexFromServer` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/core/src/preview-api/modules/preview-web/Preview.tsx:203
  • `maybeSetupPreviewNavigator` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/core/src/preview/preview-navigator.ts:16
  • `checkRef` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. (×3) — code/core/src/manager-api/modules/refs.ts:229, code/core/src/common/utils/get-storybook-refs.ts:47, code/addons/mcp/src/auth/composition-auth.ts:289
  • `updateCheck` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/core/src/core-server/utils/update-check.ts:11
  • `resolveUsingBranchInstall` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/core/src/cli/dirs.ts:23
  • `fetchManifest` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/addons/mcp/src/auth/composition-auth.ts:240
  • `checkMcpAuth` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/addons/mcp/src/auth/composition-auth.ts:320
  • `isMcpUnauthorized` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/addons/mcp/src/auth/composition-auth.ts:330
  • `parseAuthFromResponse` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — code/addons/mcp/src/auth/composition-auth.ts:344
  • `resolveDistTagVersion` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — agent-eval/lib/templates.ts:891
  • `packument` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`. — agent-eval/lib/checkout-registry-server.mjs:92

What to do

  • Thread an AbortSignal through async functions that make requests, so the work stops when its caller gives up.
X21 · Side-effecting pattern guard10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a `when` guard is free of side effects — a guard that increments a counter or assigns while deciding whether its arm matches applies that change during PATTERN MATCHING, on an arm that may not be selected, and skips it entirely when a short-circuit to its left answers first.

Method: Roslyn syntax: `when` guards on case labels and switch-expression arms, read for a mutation (`++`/`--`/assignment) sitting in a position the guard's own `&&`/`||`/`??`/`?:`/`?.` can skip. Deterministic, provable per finding. Advisory.

X22 · Contradicted release guard10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a method that TAKES a lock or semaphore and gives it back from a flag-guarded `finally` returns the value that flag implies — reporting success while the guard hands the primitive back admits a second caller the exclusion was there to keep out, and reporting failure while the guard keeps it leaves nothing to ever give it back.

Method: Roslyn syntax: `try` statements whose `finally` releases a synchronisation primitive under a bare local-bool guard, where the method also TOOK that same primitive before the `try`, checked for a `return` of a bool literal whose value disagrees with the flag state the method's own straight-line assignments put it in. Deterministic, provable per finding. Advisory.

X23 · Unguarded diagnostic materialisation6.8 / 10Adequate✓ Tool-verified

Other · Code Health — Whether the work a diagnostic log line costs is paid only when that line is wanted — C# evaluates a call's arguments BEFORE the call, so a trace/debug message joined or projected out of a collection is built in full on every pass, and then discarded by a sink the shipped configuration leaves switched off.

Method: Roslyn syntax: log calls at a diagnostic level (a `Log`-prefixed method naming Trace/Debug/Verbose, or a bare `Debug`/`Trace`/`Verbose` on a receiver named for a logger), whose argument list is read for a call whose cost scales with a sequence — a LINQ operator, a materialisation, `string.Join`, a serializer — with no enclosing level check or conditional-compilation region. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same rule: a `debug`/`trace`/`verbose` call on a receiver named for a logger, or a `log`-prefixed method naming the level, whose argument calls an array operator (`map`/`filter`/`reduce`/`sort`/…), `Array.from`, `Object.keys/values/entries`, `JSON.stringify`/`util.inspect` over anything but a literal, or an array `join` — outside any arrow or function passed as an argument, which the logger calls only when the level is on — with no enclosing `if`, `&&` or `?:` whose condition names a level, a level string, or the `NODE_ENV`/`__DEV__`/`DEV` build switch. Deterministic, provable per finding. Advisory.

  • `debug` at line 62 is called with an argument built by `skippedRegex.join(', ')` (line 63), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/core/src/shared/open-service/services/module-graph/engine/dependency-graph/resolver-factory.ts:62
  • `debug` at line 130 is called with an argument built by `faviconPaths.join(', ')` (line 133), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/core/src/core-server/presets/common-preset.ts:130
  • `debug` at line 79 is called with an argument built by `args.join(' ')` (line 79), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/core/src/common/utils/command.ts:79
  • `debug` at line 193 is called with an argument built by `pattern.join(', ')` (line 193), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/core/src/common/js-package-manager/NPMProxy.ts:193
  • `debug` at line 211 is called with an argument built by `pattern.join(', ')` (line 211), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/core/src/common/js-package-manager/PNPMProxy.ts:211
  • `debug` at line 147 is called with an argument built by `pattern.join(', ')` (line 147), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/core/src/common/js-package-manager/Yarn1Proxy.ts:147
  • `debug` at line 173 is called with an argument built by `pattern.join(', ')` (line 173), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/core/src/common/js-package-manager/Yarn2Proxy.ts:173
  • `debug` at line 177 is called with an argument built by `pattern.join(', ')` (line 177), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/core/src/common/js-package-manager/Yarn2Proxy.ts:177
  • `debug` at line 31 is called with an argument built by `Object.keys(index.entries)` (line 31), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch. — code/addons/mcp/src/utils/get-story-index.ts:31

What to do

  • Each finding names the diagnostic call and the expression inside its argument whose cost scales with a collection. Confirm from the two that the argument is built before the call — that is JavaScript's evaluation order, not a guess — then put the construction behind the level check the logger offers (`if (logger.isLevelEnabled('debug'))` for pino and winston, `isDebugEnabled()` for log4js, the repository's own debug flag where it has one), or hand the logger the object and a format string (`logger.debug({ payload }, 'raw request')`) so the serialising happens only when the line is written. Moving the call is not the fix: it is the join/projection/stringify in the argument that is paid, wherever the call sits.
X24 · Document value interpolated into markup unescaped5.2 / 10Adequate✓ Tool-verified

Other · Security — Whether text read out of the document being converted is escaped before it is written into generated markup — a value the document's author chose, interpolated into an attribute the surrounding literal delimits, can close that attribute and open another.

Method: Roslyn semantic model over the whole compilation: a string-typed `Value`/`InnerText`/`InnerXml`/`Text` member declared inside `DocumentFormat.OpenXml` or `System.Xml` is a taint SOURCE, propagated through assignments, returns, arguments, tuple elements and string composition to its transitive closure, then read at interpolated-string holes that sit in a markup position the surrounding literal itself delimits. Escaper/encoder calls and enclosing validator conditions cut the flow. Flow- and container-insensitive by construction. A second arm needs no provenance at all and reports a type that CONTRADICTS ITSELF — the same expression escaped at one delimited markup hole and interpolated raw at another hole in the same markup position of the same type, which the type's own escaping proves is a defect without knowing where the value came from. On a repository with no .NET source it reads JavaScript/TypeScript off the token stream with the same rule: a DOM read of raw document text (`getAttribute`, `textContent`, `innerText`, `nodeValue`) is the source, propagated through local bindings and string composition, and judged at template-literal and concatenation holes in the same two delimited markup positions; escapers and validating conditions cut it, and documentation-site, test, vendored and minified scripts are not read. Deterministic, provable per finding. Advisory.

  • `tip` is text this program did not author, and it is written into an unquoted attribute through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. HTML text encoding does not help in an unquoted attribute — whitespace ends it; quote the attribute and encode the value. — agent-eval/lib/agentic-reference/comparison/html-report.ts:920
  • `wfAttr` is text this program did not author, and it is written into an unquoted attribute through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. HTML text encoding does not help in an unquoted attribute — whitespace ends it; quote the attribute and encode the value. (×3) — agent-eval/lib/agentic-reference/comparison/html-report.ts:2012, agent-eval/lib/agentic-reference/comparison/html-report.ts:2232, agent-eval/lib/agentic-reference/comparison/html-report.ts:2257
  • `filterDefs` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/addons/a11y/src/components/VisionSimulator.tsx:64
  • `filterDefs` is text this program did not author, and it is written into the text of an element through `insertAdjacentHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/addons/a11y/src/withVisionSimulator.ts:43
  • `label` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. (×2) — code/addons/pseudo-states/src/stories/ShadowRoot.tsx:38, code/addons/pseudo-states/src/stories/ShadowRootWithPart.tsx:15
  • `head` is text this program did not author, and it is written into the text of an element through EJS's raw `<%- %>` output with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/core/assets/server/template.ejs:52
  • `(globals[varName])` is text this program did not author, and it is written into a script or style context through EJS's raw `<%- %>` output with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. A script or style context needs its own escaping (or a JSON serialiser that escapes `<`); better, pass the value through a data attribute. — code/core/assets/server/template.ejs:71
  • `css` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. (×6) — code/core/src/backgrounds/utils.ts:35, code/core/src/backgrounds/utils.ts:40, code/core/src/backgrounds/utils.ts:53, …
  • `filter.toHtml(paragraphs[0])` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — REDACTED:225
  • `filter.toHtml(printSerializedError(caughtException))` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — REDACTED:195
  • `filter.toHtml(line)` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/core/src/component-testing/components/MatcherResult.tsx:139
  • `e instanceof Error?e.stack:String(e)` is text this program did not author, and it is written into the text of an element through `res.end` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — REDACTED:453
  • `keyframes` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/core/src/highlight/useHighlights.ts:157
  • `` .__floater__arrow { container-type: size; } .__floater__arrow span { background: ${color.secondary}; } …` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/core/src/manager/components/TourGuide/TourTooltip.tsx:115
  • `title` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. (×2) — code/core/src/manager/components/sidebar/Brand.tsx:48, code/core/src/manager/components/sidebar/Brand.tsx:50
  • `ansiConverter.toHtml(header)` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/core/src/preview-api/modules/preview-web/WebView.ts:181
  • `ansiConverter.toHtml(detail)` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/core/src/preview-api/modules/preview-web/WebView.ts:182
  • `this.content` is text this program did not author, and it is written into the text of an element through Angular's `bypassSecurityTrustHtml` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. (×2) — code/frameworks/angular-vite/template/components/html.component.ts:23, code/frameworks/angular/template/components/html.component.ts:25
  • `user.name` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. (×4) — code/frameworks/html-vite/template/cli/js/Header.js:29, code/frameworks/html-vite/template/cli/ts/Header.ts:36, code/renderers/html/template/cli/js/Header.js:29, …
  • `element` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. (×2) — code/renderers/html/src/render.ts:51, code/renderers/server/src/render.ts:76
  • `args.label` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/renderers/html/template/components/Button.js:4
  • `content` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. (×2) — REDACTED:1, REDACTED:3
  • `content` is text this program did not author, and it is written into the text of an element through Vue's `v-html` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/renderers/vue3/template/components/Html.vue:2
  • `String(value)` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup. — code/renderers/web-components/src/bind-args.ts:111
  • `lines.join('\n')` is text this program did not author, and it is written into a script or style context through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. A script or style context needs its own escaping (or a JSON serialiser that escapes `<`); better, pass the value through a data attribute. — code/renderers/web-components/src/docgen/story-docs/print-element.ts:60

What to do

  • Each finding names the expression, the attribute it lands in and the line. Confirm the value's origin from the read this analyzer traced, then escape it at the sink or validate it against the shape the attribute accepts before interpolating.
X25 · Inert configuration knob10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a value the caller is invited to supply is the value the type actually uses — a constructor parameter stored in a private field that nothing ever reads while the default it was given is spelled out a second time at the site that should have read it, a keyed lookup that falls back to a different setting than the one its key names while the same type falls back to the matching one for that same key, or a culture-sensitive parse given no format provider by a type that feeds its own settable culture to the same kind of parse elsewhere, or a number an entry point writes to standard output under the host's culture while the same entry point formats with the invariant culture elsewhere. Either way, every caller who supplies a value silently gets something else.

Method: Roslyn syntax: private instance fields of a non-partial type assigned in a constructor from one of its own parameters with a `??` fallback, checked for whether anything in the type body reads the field and whether that same fallback expression is spelled out again outside the constructor; and `??` fallbacks onto a member access from a lookup call carrying exactly one string literal, grouped by that key across the type and checked for a fallback member whose folded name disagrees with the key while a sibling site for the same key agrees with it. On a repository with no .NET source the first two arms read JavaScript/TypeScript off the engine’s own token stream (tests included, bundles and vendored paths not): a `#x`, `private` or `private` parameter-property instance field filled in the constructor from a parameter (or one member of one) through `??`/`||` or a parameter default, never read anywhere in the file by name, whose constructed default is spelled again in the class body; and `lookup("key") ?? s.member` grouped by key per class, or per module outside every class. The culture arm has no JavaScript counterpart: its parses take no locale. Deterministic, provable per finding. Advisory.

X26 · Unsynchronised callback handoff10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a value handed from a callback to the body that waits on it crosses on something built to be crossed — a `Queue<T>`/`List<T>`/`Dictionary<K,V>` written inside an event handler and read back outside it is mutated by two flows at once, and the semaphore or completion source beside it orders how MANY items exist while leaving the collection's own head, tail and backing array unprotected.

Method: Roslyn syntax: method, accessor, local-function and lambda bodies that declare BOTH a non-thread-safe generic collection (`Queue`/`Stack`/`List`/`Dictionary`/`HashSet`/`Sorted*`/`LinkedList`) and a synchronisation primitive (`SemaphoreSlim`/`TaskCompletionSource`/`ManualResetEvent(Slim)`/`AutoResetEvent`/`CountdownEvent`) as locals, then read for a `+=`-registered lambda that raises that primitive while the body outside every lambda waits on it — and, in that scope, a mutating call on the collection inside the lambda paired with a mention of it outside. Any `lock` in the scope abstains it. On a repository with no .NET source the same handoff is read in Java off the engine’s own token stream (test source sets, vendored and demonstration paths not): an `ArrayList`/`LinkedList`/`ArrayDeque`/`PriorityQueue`/`Hash*`/`LinkedHash*`/`Tree*` local and a `CountDownLatch`/`Semaphore`/`CompletableFuture` local, a lambda or anonymous class that raises the primitive and mutates the collection, and a wait outside it; any `synchronized` or `lock()` abstains the body. Because each of those primitives orders what the callback wrote before raising it, only a touch that provably overlaps the callback is convicted: one after the registration and before the next wait, or one in a loop registered-before, waiting on every pass and not declaring the collection. Deterministic, provable per finding. Advisory.

X27 · Collection changed while being enumerated10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a `for` loop leaves the `dict`, `set` or `deque` it is walking alone — CPython's iterators over those check that the collection has not changed size since the loop began, so a body that removes from (or empties) the very collection the loop is walking makes the next step raise `RuntimeError: dictionary changed size during iteration` and the remaining items are never seen.

Method: Roslyn syntax + semantics: `foreach` statements whose body calls a structural mutator (`Add`/`Remove`/`Clear`/`Insert`/…) on the very expression the loop is enumerating. Two arms. ARM A — the source is a concrete fragile BCL collection, or a live `Keys`/`Values` view over one, and the mutator resolves to that same collection's own member; concurrent and immutable collections and arrays are outside the population by construction, since their enumerators survive a structural change. ARM B — the source is an argument-less accessor CALL on a receiver whose body is in source: the accessor must return a stored field VERBATIM and a sibling member must structurally change that same field, both read off the implementations rather than from the members' names. A mutation the loop provably exits immediately after (`break`/`return`/`throw`/`goto`), or one written inside a nested loop or a lambda, is counted and never reported. Deterministic, provable per finding. Advisory.

X28 · Index access outside its own emptiness guard10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a condition that tests a value for emptiness indexes that same value only where the test holds — an `||` written one parenthesis too far to the left leaves an index access outside the guard beside it, so the empty case the guard exists to anticipate reaches the index and throws.

Method: Roslyn syntax only, no semantic model: the OUTERMOST `&&`/`||` of every boolean condition, read for a symbol the condition tests for emptiness (`string.IsNullOrEmpty`/`IsNullOrWhiteSpace`, a `Length`/`Count` comparison against a literal, `Any()`, a `Length`/`Count` pattern, or a comparison against `""`) and ALSO indexes. Each `symbol[...]` access is placed by a boolean-reachability walk from the access up to the outermost connective: an access is COVERED when some enclosing step has it in the right operand and the left operand, under the truth value that step forces, proves the symbol non-empty — a recursion over `&&`/`||` whose true- and false-directions are asymmetric. A finding needs BOTH an uncovered access and a covered one on the same symbol in the same condition, which is the agreeing twin that separates a misplaced parenthesis from an unrelated length test. Bare index accesses with no emptiness test in the condition are neither counted nor reported; a non-identifier receiver and a lambda nested inside the condition are outside the population. Deterministic, provable per finding. Advisory.

X29 · Per-element action decided by a fixed element10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a decision taken once per element is taken ABOUT that element — a test inside a counted loop that reads a fixed subscript of the very collection its guarded statement indexes by the loop variable applies element zero's answer to all of them, so the elements that differ from it are all handled wrongly, and in the same direction.

Method: Roslyn syntax only, no semantic model: every `for` statement declaring exactly ONE loop variable, and every `if` inside its body that is not under a nested loop or a lambda. A site enters the population when the `if`’s condition never mentions the loop variable while the statement it guards indexes some collection by that variable ALONE (`c[i]`; `c[i + 1]` and `c[i, j]` are outside it). A finding additionally needs the AGREEING TWIN at the same-collection grain: the condition must read THAT SAME collection at a subscript that does not move — written into the condition, or reached through a local declared BEFORE the loop, so an alias bound inside the body is not followed. Both collection expressions must be simple identifiers. On a repository with no .NET source the same rule reads JavaScript/TypeScript off the engine’s own token stream (tests included, bundles and vendored paths not): a `for (let|var|const x = …; …; …)` with one declarator and a braced body, an alias followed only when it is declared before the loop in a block that encloses it and never assigned inside the loop. Deterministic, provable per finding. Advisory.

X3 · Exception handling5.2 / 10Adequate✓ Tool-verified

Other · Code Health — Whether exceptions are handled rather than silently swallowed or rethrown with lost stack traces.

Method: Roslyn syntax scan: every catch clause counted; empty catches and bare rethrows flagged. Population is all catch clauses, not estimated. Deterministic, hard fact.

  • `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it. (×7) — scripts/run-registry.ts:153, code/lib/eslint-plugin/scripts/update-lib-flat-configs.ts:74, code/lib/create-storybook/src/initiate.ts:203, …
  • An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it. (×27) — scripts/utils/preapprove-local-packages.ts:39, scripts/eval/lib/utils.ts:211, code/renderers/web-components/src/index.ts:31, …
  • `catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. (×5) — code/renderers/svelte/src/docgen/component-docgen/build-docgen.ts:59, code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts:209, code/renderers/react/src/componentManifest/componentMeta/ComponentMetaProject.ts:281, …
  • `catch (err)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter. — code/lib/cli-storybook/src/automigrate/index.ts:423

What to do

  • Swallowed exception (empty catch)
X30 · Support guard that admits what it rejects10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a guard written as a NEGATED `||` says what its author meant — `!(a || b || x != k)` is `!a && !b && x == k` by De Morgan, so a bail-out that mixes capabilities the code needs with a fault it refuses turns inside out: it fires only where the capabilities are ABSENT, and lets every value the fault term names walk straight into the body that cannot handle it.

Method: Roslyn syntax only, no semantic model: every logical-not whose operand is a parenthesised `||` chain of two or more disjuncts, flattened (a left-nested `a || b || c` read once would see `(a || b)` as one disjunct). A site enters the population on that shape alone. A finding additionally needs the disjuncts to DISAGREE in polarity: at least one bare boolean read — an identifier or member access, never an invocation, which is a predicate rather than a capability flag — and at least one `x != <constant>`, the only form that negates into an exact-value pin (`== null` negates into a looser requirement and is outside the fault set). Consistently-polarised disjunctions, all-fault or all-capability, are counted and never reported; a negated `&&` is outside the population entirely. No same-receiver gate: it was measured to cost a real defect and remove no false positive. Deterministic, provable per finding. Advisory.

X5 · Nullable reference types6.9 / 10Adequate✓ Tool-verified

Other · Code Health — Whether strict null checking is enabled and not undermined by heavy `!` assertion — TypeScript's `strictNullChecks` (which `strict` turns on) is what makes `string` exclude `null` and `undefined`, and the postfix `!` is the operator that silences it.

Method: Roslyn compiler-options scan: NullableContextOptions per project; null-forgiving (!) suppression density per 1k syntax nodes. Deterministic, adoption plus suppression penalty.

  • 84/127 of this repository's type-checking configuration(s) turn on strict null checking (`"strict": true`, or `"strictNullChecks": true`). A configuration that states neither is counted as OFF, because off is tsc's own default; a solution-style one whose `"files"` is empty and whose `"references"` point at other projects is in neither number, because it checks no source itself. Where it is off, `string` admits `null` and `undefined`: passing a value that is null compiles silently and throws on the first property access.
  • ~1.2 `!` null assertions per 1k TypeScript source lines — 413 assertion(s) across the 335151 source line(s) of the 2829 TypeScript file(s) read, which is the only code the operator asserts anything in (a `!` in a `.js` file is not this operator and was not counted, and one in a file whose null checking is off silences nothing). Densest: code/core/src/csf-tools/estree/editor.ts (23), agent-eval/lib/agentic-reference/comparison/html-report.ts (16), code/addons/vitest/src/node/vitest-manager.ts (13). Each one tells the compiler to trust the author about null, suppressing the very diagnostic `strictNullChecks` exists to produce.

What to do

  • The findings name the configuration each number was taken from and, for the assertions, the files that hold them. Turn null checking on where it is off — `"strict": true` in the base tsconfig that the others extend switches `strictNullChecks` on with the rest of the family — and then resolve the assertions rather than adding to them. A `!` on a value the checker could show to be null is a promise the author cannot check from where they are standing, and each one is a `TypeError: Cannot read properties of null` waiting for the path that makes it true; where the value genuinely cannot be null, say something the checker can see instead (narrow it with a test, make the property required, drop the `?`).

WCAG coverage — what static analysis assessed

Statically assessed 15 of 55 WCAG 2.2 Level A/AA success criteria (27%; ≈30% of the 50 WCAG 2.1 AA criteria for EN 301 549). The other 40 require runtime or manual evaluation. Partial signal only (a clean result is necessary, not sufficient; static analysis fully verifies none). This is accessibility readiness, not a conformance claim — a WCAG conformance claim requires manual evaluation (WCAG-EM 1.0).

DimensionWCAG 2.2 A/AA criteriaCoverage
AC1 · Text alternatives1.1.1, 1.2.2, 1.2.5Partial signal
AC2 · Forms & labels1.3.1, 3.3.2, 4.1.2Partial signal
AC3 · Page structure1.4.4, 2.2.1, 2.4.1, 2.4.2, 3.1.1, 4.1.2Partial signal
AC4 · Keyboard semantics2.1.1, 2.4.3Partial signal
AC5 · ARIA correctness4.1.2Partial signal
AC6 · Visual & motion safety1.4.3, 2.4.7Partial — literal CSS only
AC7 · A11y enforcementenforcement — no page criterionEnforcement posture (process)

Not statically assessed — these 40 Level A/AA criteria need runtime or manual evaluation (WCAG-EM): 1.2.1, 1.2.3, 1.2.4, 1.3.2, 1.3.3, 1.3.4, 1.3.5, 1.4.1, 1.4.2, 1.4.5, 1.4.10, 1.4.11, 1.4.12, 1.4.13, 2.1.2, 2.1.4, 2.2.2, 2.3.1, 2.4.4, 2.4.5, 2.4.6, 2.4.11, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.5.7, 2.5.8, 3.1.2, 3.2.1, 3.2.2, 3.2.3, 3.2.4, 3.2.6, 3.3.1, 3.3.3, 3.3.4, 3.3.7, 3.3.8, 4.1.3.

Reference — by lens

The score is the rank-weighted fold of these lenses (worst-heaviest), each including its meta-dimensions; a lens with a Critical contributor is capped at Fair (its band reads "gated by …") and is never the strongest area however high its average.

LensScoreRatingImpact
Code Health65%Adequate — gated by D2Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Architecture60%Adequate — gated by R9Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Maturity75%StrongStrongest area.
Readiness47%Weak — gated by R8, P7Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Security60%Adequate — gated by D28, D29, D30Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Accessibility56%AdequateAcceptable, with room to improve.
Performance60%AdequateAcceptable, with room to improve.
Unscored — 2 check(s) recorded observations but carry no score

These checks ran and found something, but they do not carry a score — either by design (an advisory check reports evidence rather than grading it) or because they could not be scored here. They are excluded from the score for that reason, not because there was nothing to see.

  • X10 Duplicated predicate — 25 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
  • X7 Silent fallback defaults — 23 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 1 control(s) we could not find positive evidence for

These checks grade a working control, and the repository shows no evidence of one. That is deliberately not scored as a zero: a repository cannot show an ops runbook, a database TTL or an infrastructure-side audit log, so absence of evidence here is not evidence the control is missing. It is also not a statement that the check is irrelevant to this codebase — the thing it grades applies; we just could not see it. Excluded from the score either way.

  • P5 DR & Backup — not evidenced — repo shows no backup/RTO/RPO controls; absence of evidence is not evidence of a working control
Not included — 41 check(s) not relevant to this codebase

These checks had nothing to measure here (no tests, no git history, the codebase is small, or the architecture style doesn't apply), so they're omitted above rather than scored low.

  • AX1 Captive dependencies — Not applicable: Angular's root injector cannot see a component-level provider, so a root service asking for one fails with NullInjectorError instead of capturing it.
  • AX2 Stateful singletons — No container singleton was found, so there is no shared instance for concurrent requests to race on. No function in this Python code is served by a threaded web framework (a Flask, Bottle or FastAPI route, a Django or Pyramid view), so no module is shared between request threads. TypeScript/JavaScript runs each process's requests on one event loop, so no two requests write a shared object at the same instant (interleaving across an await is a different defect).
  • AX5 Architecture & structure — not assessed — architecture style/structure is computed from a project graph (projects, types, module namespaces) that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
  • AX7 Slice cohesion — not applicable — not a vertical-slice architecture
  • AX9 CQS / query purity — no CQRS query handlers detected — query purity is not applicable to this codebase
  • AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • AXR1 Runtime accessibility — the dev server did not expose a crawlable HTTP endpoint in time — no runtime evidence This is a statement about this run, not a statement about your application: nothing here says the surface is inaccessible, only that it was never rendered.
  • C1 Data Protection — No personal data detected in a persisted data model — no PII-named field (email, firstName, dateOfBirth, phoneNumber, …) or stored credential on a TypeORM/MikroORM/sequelize-typescript/NestJS-Mongoose entity, a Mongoose schema, a Sequelize or Drizzle table, a Knex migration or a Prisma model — and no database or data-store client in the source either, so this repository keeps no data at rest for these controls to protect. If it does persist personal data (through a hosted backend configured outside this repository, for instance), the controls belong to wherever that data is stored.
  • C3 Audit Trail — No personal data detected in a persisted data model — no PII-named field (email, firstName, dateOfBirth, phoneNumber, …) or stored credential on a TypeORM/MikroORM/sequelize-typescript/NestJS-Mongoose entity, a Mongoose schema, a Sequelize or Drizzle table, a Knex migration or a Prisma model — and no database or data-store client in the source either, so this repository keeps no sensitive data whose changes an audit trail would record. If it does (through a hosted backend configured outside this repository, for instance), the trail belongs to wherever that data is stored.
  • C4 Data Retention — No personal data detected in a persisted data model — no PII-named field (email, firstName, dateOfBirth, phoneNumber, …) or stored credential on a TypeORM/MikroORM/sequelize-typescript/NestJS-Mongoose entity, a Mongoose schema, a Sequelize or Drizzle table, a Knex migration or a Prisma model — and no database or data-store client in the source either, so this repository keeps no personal data whose lifetime a retention limit would bound. If it does (through a hosted backend configured outside this repository, for instance), the limit belongs wherever that data is stored.
  • C5 Data-Subject Rights — No personal data detected in a persisted data model — no PII-named field (email, firstName, dateOfBirth, phoneNumber, …) or stored credential on a TypeORM/MikroORM/sequelize-typescript/NestJS-Mongoose entity, a Mongoose schema, a Sequelize or Drizzle table, a Knex migration or a Prisma model — and no database or data-store client in the source either, so this repository keeps no personal data for a data subject to erase, export or consent over. If it does (through a hosted backend configured outside this repository, for instance), the rights are served wherever that data is stored.
  • D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
  • D21 Naming Consistency — Naming consistency is measured on C# only; JavaScript, Python, TypeScript, html not measured.
  • D22 Internal API Consistency — API consistency is measured on C# only; the exposed JavaScript, TypeScript surface was not measured.
  • D24 Comment Value — D24 reads C# and Visual Basic comments only — this repository's production source is .py, .ts, .tsx, which was left unread. Not scored: this is a gap in the analyzer, not a verdict about this repository.
  • D25 ADR Conformance — no ADRs to check
  • D27 Navigability — D27 counts a call into the standard library or a dependency as unresolved for this repository's language (.ts,.tsx), so too few call sites counted as resolved to assess navigability. Not scored: this is a gap in the analyzer, not a verdict about this repository.
  • D31 IaC & Container Security — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.
  • D32 Data Compliance (PII/GDPR) — 307 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
  • D39 IL Efficiency — D39 measures the IL emitted by a .NET build; this repository has no .NET solution or project files, so the dimension does not apply.
  • D4 Code Duplication — This repository's production source (.ts, .tsx) is not read by D4's token comparison, which compares .NET source: duplication in it is measured by R10 Code Duplication, the frontend lens's card running the same clone algorithm over the JS/TS token stream. Not scored here — read the R10 card for this repository's duplication.
  • D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
  • D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
  • D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
  • D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
  • DM1 Domain Modelling — not scored — this repository shows only 1 of the 3 signals this lens looks for (4 domain event(s); its domain events are published by services or handlers — no domain entity raises one)
  • ED1 Event-Driven — not scored — this repository shows none of the 3 signals this lens looks for
  • ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
  • ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
  • P12 CI test-gate honesty — Reported, not scored — and nothing was matched here. The coverage check applies to any stack, and the automatic-re-run check to any GitHub-Actions workflow, but the checks for excluded tests, skipped tests and sleep-based synchronisation currently recognise only some ecosystems' test-runner idioms, so on a repository built with another stack the zeros below mean 'not checked', not 'clean'.
  • P8 Schema migrations — no ORM, schema-migration tool or schema auto-create was found in this repository's dependency manifests or source, so there is no database schema for this check to judge
  • P9 Domain vs controller coverage — coverage data present for 869 file(s), but no domain-layer files were identified: no covered file's path contains any of the markers this check keys on (/domain/, /aggregates/, /valueobjects/, /domainmodel/, .domain/, /entities/), which are matched case-insensitively anywhere in the path. With no domain partition there is nothing to compare the web/controller layer against — if this repository keeps its business rules under a folder named none of those, that naming is what the check cannot see, not the domain logic.
  • PF1 Benchmark discipline — Not applicable: no benchmark suite was found. This check searched for tinybench, mitata, benchmark.js, benny or vitest `bench(...)` calls in files that import them (or `*.bench.*` files), or one of those in a REDACTED, and for a `*benchmark*` script that this repository's CI runs. Benchmarks are credited as a bonus, so their absence is neither scored nor deducted.
  • PF2 Allocation hygiene — Not applicable: TypeScript/JavaScript runs on a garbage-collected runtime that gives a program no allocation-control idiom to choose on a hot path — no pools, stack allocation or value types — so allocation awareness is not something this code can be rated on.
  • R5 Dependency Freshness — uses a yarn lockfile — dependency freshness not measured here; JS/npm CVEs are scored in D30 (Dependency Vulnerabilities), which answers every ecosystem
  • SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • X20 Mistyped argument guard — This check asks whether an argument guard reports an EMPTY value as a NULL one, which needs a language that throws a null-specific argument exception — .NET's ArgumentNullException, the JVM's NullPointerException, Dart's ArgumentError.notNull. This repository contains none of those languages: the ones it is written in have a single exception for a bad argument, so there is no pair of exceptions to confuse and nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
  • X32 Type resolved by simple name across every loaded assembly — This check is about how a .NET program searches the assemblies loaded into its process for a type, and this repository contains no .NET source, so there is nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
  • X4 Structured logging — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
  • X6 Hand-rolled structured-format parsing — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • X9 Subsumed condition operand — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.

Appendix A — Findings (grouped)

The findings behind the scores, grouped by severity, then by dimension and kind. The high-severity issues are enumerated in full below; items per group are capped at 25 with any overflow stated explicitly per group, never silently truncated. The complete machine-readable list of every finding (all severities) is the companion findings.md in this report's bundle.

Critical — 213 finding(s)
D30 · Dependency Vulnerabilities · High CVE · ×73
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • + 48 more in this group — see findings.md.
D10 · Test Quality · No assertions (empty test) · ×24
  • No assertions (empty test): stories override meta args and infer callback parameters code/renderers/web-components/src/csf-factories.test.ts:381 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): stories override meta args and infer callback parameters code/renderers/vue3/src/csf-factories.test.ts:385 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): snippet props are args code/renderers/svelte/src/csf-factories.test.ts:182 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): stories override meta args and infer callback parameters code/renderers/svelte/src/csf-factories.test.ts:367 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): rejects wrong arg types, a missing name, and template together with children code/renderers/svelte/src/svelte-csf/index.test.ts:88 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): Component type can be overridden code/renderers/react/src/csf-factories.test.tsx:247 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): Correct args are inferred when type is added in renderer code/renderers/react/src/csf-factories.test.tsx:266 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): meta.input also contains play code/renderers/react/src/csf-factories.test.tsx:465 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): stories override meta args and infer callback parameters code/renderers/react/src/csf-factories.test.tsx:568 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): generic components code/renderers/react/src/csf-factories.test.tsx:609 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): without a route code/frameworks/tanstack-react/src/csf-factories.test.tsx:16 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): with a route code/frameworks/tanstack-react/src/csf-factories.test.tsx:44 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): accepts mocks that return nothing, as the docs show code/frameworks/sveltekit/src/csf-factories.test.ts:40 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): is typed in the preview, the meta and the story code/frameworks/sveltekit/src/csf-factories.test.ts:71 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): Component type can be overridden code/frameworks/angular-vite/src/client/csf-factories.test.ts:201 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): Correct args are inferred when type is added in renderer code/frameworks/angular-vite/src/client/csf-factories.test.ts:229 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): Correct args are inferred when render arg type is required code/frameworks/angular-vite/src/client/csf-factories.test.ts:255 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): stories override meta args and infer callback parameters code/frameworks/angular-vite/src/client/csf-factories.test.ts:511 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): Component type can be overridden code/frameworks/angular/src/client/csf-factories.test.ts:201 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): Correct args are inferred when type is added in renderer code/frameworks/angular/src/client/csf-factories.test.ts:229 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): Correct args are inferred when render arg type is required code/frameworks/angular/src/client/csf-factories.test.ts:255 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): stories override meta args and infer callback parameters code/frameworks/angular/src/client/csf-factories.test.ts:511 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): do not collapse preview types when used without factory addons code/core/src/csf/csf-factories.test.ts:87 — Test method has an empty body — it asserts nothing and exercises no code.
  • No assertions (empty test): uncalled addon factories are rejected code/core/src/csf/csf-factories.test.ts:96 — Test method has an empty body — it asserts nothing and exercises no code.
D30 · Dependency Vulnerabilities · Critical CVE · ×16
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
R9 · Circular Imports · Import cycle (2 files) · ×14
  • Import cycle (2 files) code/addons/links/src/index.ts:3 — code/addons/links/src/index.ts → code/addons/links/src/preview.ts → code/addons/links/src/index.ts
  • Import cycle (2 files) code/builders/builder-vite/src/preset.ts:13 — code/builders/builder-vite/src/preset.ts → code/builders/builder-vite/src/vite-config.ts → code/builders/builder-vite/src/preset.ts
  • Import cycle (2 files) code/core/src/builder-manager/index.ts:22 — code/core/src/builder-manager/index.ts → code/core/src/builder-manager/utils/data.ts → code/core/src/builder-manager/index.ts
  • Import cycle (2 files) code/core/src/common/index.ts:49 — code/core/src/common/index.ts → code/core/src/common/utils/get-story-id.ts → code/core/src/common/index.ts (one verified cycle inside a mutually-dependent group of 9 files)
  • Import cycle (2 files) code/core/src/common/js-package-manager/JsPackageManager.ts:23 — code/core/src/common/js-package-manager/JsPackageManager.ts → code/core/src/common/js-package-manager/util.ts → code/core/src/common/js-package-manager/JsPackageManager.ts
  • Import cycle (2 files) code/core/src/common/utils/get-framework-name.ts:5 — code/core/src/common/utils/get-framework-name.ts → code/core/src/common/utils/get-storybook-info.ts → code/core/src/common/utils/get-framework-name.ts (one verified cycle inside a mutually-dependent group of 3 files)
  • Import cycle (2 files) code/core/src/components/components/Modal/Modal.styled.tsx:15 — code/core/src/components/components/Modal/Modal.styled.tsx → code/core/src/components/components/Modal/Modal.tsx → code/core/src/components/components/Modal/Modal.styled.tsx
  • Import cycle (2 files) REDACTED:29 — REDACTED → code/core/src/csf-tools/CsfObjectDiscovery.ts → REDACTED
  • Import cycle (2 files) code/core/src/manager-api/index.mock.ts:12 — code/core/src/manager-api/index.mock.ts → code/core/src/manager-api/stores/__mocks__/status.ts → code/core/src/manager-api/index.mock.ts (one verified cycle inside a mutually-dependent group of 3 files)
  • Import cycle (2 files) code/core/src/mocking-utils/extract.ts:13 — code/core/src/mocking-utils/extract.ts → code/core/src/mocking-utils/resolve.ts → code/core/src/mocking-utils/extract.ts
  • Import cycle (2 files) code/lib/eslint-plugin/src/configs/flat/addon-interactions.ts:1 — code/lib/eslint-plugin/src/configs/flat/addon-interactions.ts → code/lib/eslint-plugin/src/index.ts → code/lib/eslint-plugin/src/configs/flat/addon-interactions.ts (one verified cycle inside a mutually-dependent group of 5 files)
  • Import cycle (2 files) code/renderers/react/src/componentManifest/getComponentImports.ts:17 — code/renderers/react/src/componentManifest/getComponentImports.ts → code/renderers/react/src/componentManifest/reactDocgen.ts → code/renderers/react/src/componentManifest/getComponentImports.ts
  • Import cycle (2 files) code/renderers/web-components/src/docgen/story-docs/html-tree.ts:1 — code/renderers/web-components/src/docgen/story-docs/html-tree.ts → code/renderers/web-components/src/docgen/story-docs/print-element.ts → code/renderers/web-components/src/docgen/story-docs/html-tree.ts
  • Import cycle (2 files) scripts/ci/utils/helpers.ts:3 — scripts/ci/utils/helpers.ts → scripts/ci/utils/types.ts → scripts/ci/utils/helpers.ts
D28 · Secrets (history) · REDACTED · ×8
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
R8 · Dependency Hygiene · Unlisted import 'reshaped' · ×7
  • Unlisted import 'reshaped' agent-eval/evals/803-edit-component/src/components/ReviewCard.tsx:1 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
  • Unlisted import 'reshaped' agent-eval/evals/804-write-story-for-existing-component/src/components/AlertBanner.tsx:2 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
  • Unlisted import 'reshaped' agent-eval/evals/805-non-visual-refactor/src/components/ReviewCard.tsx:1 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
  • Unlisted import 'reshaped' agent-eval/evals/806-browse-request/src/components/ReviewCard.tsx:1 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
  • Unlisted import 'reshaped' agent-eval/evals/807-docs-request/src/components/ReviewCard.tsx:1 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
  • Unlisted import 'reshaped' agent-eval/evals/814-write-stories-for-fetching-component/src/components/OrderHistory.tsx:2 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
  • Unlisted import 'reshaped' agent-eval/evals/906-existing-component-edit-story-reshaped-detailed/src/components/PlanCard.tsx:2 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
AC2 · Forms & labels · <input> without a programmatic label · ×6
  • <input> without a programmatic label code/addons/docs/src/blocks/controls/react-editable-json-tree/index.tsx:150 — This control has no associated label. Add a <label htmlFor> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label code/lib/docgen-harness/src/svelte/__testfixtures__/runes-omit-rest-class/Input.svelte:38 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label code/lib/docgen-harness/src/vue3/__testfixtures__/model-with-runtime-emits/ModelWithRuntimeEmits.vue:10 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label code/lib/docgen-harness/src/vue3/__testfixtures__/v-model/VModelInput.vue:21 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label code/lib/docgen-harness/src/vue3/__testfixtures__/v-model/VModelInput.vue:25 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
  • <input> without a programmatic label code/lib/docgen-harness/src/vue3/story-docs/__testfixtures__/no-component/InputField.vue:8 — This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
AC2 · Forms & labels · <button> with no accessible text · ×6
  • <button> with no accessible text code/frameworks/svelte-vite/template/cli/js/Header.svelte:42 — A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
  • <button> with no accessible text code/frameworks/svelte-vite/template/cli/ts/Header.svelte:40 — A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
  • <button> with no accessible text code/frameworks/sveltekit/template/cli/js/Header.svelte:42 — A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
  • <button> with no accessible text code/frameworks/sveltekit/template/cli/ts/Header.svelte:40 — A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
  • <button> with no accessible text code/renderers/svelte/template/cli/js/Header.svelte:42 — A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
  • <button> with no accessible text code/renderers/svelte/template/cli/ts/Header.svelte:40 — A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
D11 · Test Reliability · Test suite cannot be installed from its own lockfile · ×4
  • Test suite cannot be installed from its own lockfile: test-storybooks/mcp/ — The vitest suite in test-storybooks/mcp/ was never exercised because its dependency install refused the committed lockfile — the dependency install for test-storybooks/mcp/ refused the committed lockfile (➤ YN0000: · Yarn 4.18.0), so the suite never ran. The suite is declared and committed but cannot be installed from what the repository ships, so neither this scan nor a new contributor can run it. The ask is the one the owner performs: run the install locally and commit the lockfile it writes.
  • Test suite cannot be installed from its own lockfile: test-storybooks/portable-stories-kitchen-sink/nextjs/ — The jest suite in test-storybooks/portable-stories-kitchen-sink/nextjs/ was never exercised because its dependency install refused the committed lockfile — the dependency install for test-storybooks/portable-stories-kitchen-sink/nextjs/ refused the committed lockfile (➤ YN0000: · Yarn 4.18.0), so the suite never ran. The suite is declared and committed but cannot be installed from what the repository ships, so neither this scan nor a new contributor can run it. The ask is the one the owner performs: run the install locally and commit the lockfile it writes.
  • Test suite cannot be installed from its own lockfile: test-storybooks/portable-stories-kitchen-sink/react/ — The vitest suite in test-storybooks/portable-stories-kitchen-sink/react/ was never exercised because its dependency install refused the committed lockfile — the dependency install for test-storybooks/portable-stories-kitchen-sink/react/ refused the committed lockfile (➤ YN0000: · Yarn 4.18.0), so the suite never ran. The suite is declared and committed but cannot be installed from what the repository ships, so neither this scan nor a new contributor can run it. The ask is the one the owner performs: run the install locally and commit the lockfile it writes.
  • Test suite cannot be installed from its own lockfile: test-storybooks/portable-stories-kitchen-sink/svelte/ — The vitest suite in test-storybooks/portable-stories-kitchen-sink/svelte/ was never exercised because its dependency install refused the committed lockfile — the dependency install for test-storybooks/portable-stories-kitchen-sink/svelte/ refused the committed lockfile (➤ YN0000: · Yarn 4.18.0), so the suite never ran. The suite is declared and committed but cannot be installed from what the repository ships, so neither this scan nor a new contributor can run it. The ask is the one the owner performs: run the install locally and commit the lockfile it writes.
AC2 · Forms & labels · Link with no accessible name · ×3
  • Link with no accessible name code/addons/docs/src/blocks/blocks/mdx.tsx:216 — A link with no text, aria-label or labelled child (e.g. an icon-only link) has no accessible name, so assistive tech can't say where it goes. Add visible text or an aria-label.
  • Link with no accessible name code/addons/docs/src/blocks/components/Toolbar.tsx:152 — A link with no text, aria-label or labelled child (e.g. an icon-only link) has no accessible name, so assistive tech can't say where it goes. Add visible text or an aria-label.
  • Link with no accessible name code/core/src/manager/components/sidebar/Menu.tsx:188 — A link with no text, aria-label or labelled child (e.g. an icon-only link) has no accessible name, so assistive tech can't say where it goes. Add visible text or an aria-label.
D28 · Secrets (history) · High secret · ×3
  • REDACTED
  • REDACTED
  • REDACTED
D30 · Dependency Vulnerabilities · Critical vulnerability · ×3
  • REDACTED
  • REDACTED
  • REDACTED
AC1 · Text alternatives · <img> without a text alternative · ×2
  • <img> without a text alternative code/frameworks/angular-vite/template/stories/argTypes/doc-button/doc-button.component.html:2 — An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative.
  • <img> without a text alternative code/frameworks/angular/template/stories/argTypes/doc-button/doc-button.component.html:2 — An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative.
AC4 · Keyboard semantics · Click handler on a non-interactive <span> · ×2
  • Click handler on a non-interactive <span> code/addons/docs/src/blocks/controls/react-editable-json-tree/JsonNodes.tsx:639 — A click handler on a plain element isn't keyboard-operable. Use a <button>, or add role + tabIndex={0} + a key handler.
  • Click handler on a non-interactive <span> code/addons/docs/src/blocks/controls/react-editable-json-tree/JsonNodes.tsx:1502 — A click handler on a plain element isn't keyboard-operable. Use a <button>, or add role + tabIndex={0} + a key handler.
D29 · Static Analysis (SAST) · REDACTED
  • REDACTED
  • REDACTED
R8 · Dependency Hygiene · Unlisted import 'lodash-es' · ×2
  • Unlisted import 'lodash-es' code/.storybook/preview.tsx:49 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
  • Unlisted import 'lodash-es' code/core/template/stories/test/NodeModuleMocking.stories.js:4 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import 'valibot' · ×2
  • Unlisted import 'valibot' code/.storybook/open-service-debug-service.ts:1 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
  • Unlisted import 'valibot' code/addons/vitest/src/node/toolset/definition.test.ts:5 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R9 · Circular Imports · Import cycle (5 files) · ×2
  • Import cycle (5 files) agent-eval/lib/agentic-reference/cases.ts:13 — agent-eval/lib/agentic-reference/cases.ts → agent-eval/lib/agentic-reference/experiment.ts → agent-eval/lib/agentic-reference/post-analysis.ts → agent-eval/lib/agentic-reference/comparability.ts → agent-eval/lib/agentic-reference/identity.ts → agent-eval/lib/agentic-reference/cases.ts
  • Import cycle (5 files) code/core/src/manager-api/root.tsx:55 — code/core/src/manager-api/root.tsx → code/core/src/manager-api/modules/globals.ts → code/core/src/manager-api/lib/events.ts → code/core/src/manager-api/modules/refs.ts → code/core/src/manager-api/lib/stories.ts → code/core/src/manager-api/root.tsx (one verified cycle inside a mutually-dependent group of 10 files)
R9 · Circular Imports · Import cycle (3 files) · ×2
  • Import cycle (3 files) code/core/src/components/components/Select/Select.tsx:19 — code/core/src/components/components/Select/Select.tsx → code/core/src/components/components/Select/SelectOption.tsx → code/core/src/components/index.ts → code/core/src/components/components/Select/Select.tsx
  • Import cycle (3 files) code/core/src/manager/components/sidebar/Sidebar.tsx:19 — code/core/src/manager/components/sidebar/Sidebar.tsx → code/core/src/manager/components/sidebar/Explorer.tsx → code/core/src/manager/components/sidebar/Refs.tsx → code/core/src/manager/components/sidebar/Sidebar.tsx (one verified cycle inside a mutually-dependent group of 10 files)
R9 · Circular Imports · Import cycle (4 files) · ×2
  • Import cycle (4 files) code/lib/cli-storybook/src/autoblock/block-dependencies-versions.ts:4 — code/lib/cli-storybook/src/autoblock/block-dependencies-versions.ts → code/lib/cli-storybook/src/autoblock/utils.ts → code/lib/cli-storybook/src/util.ts → code/lib/cli-storybook/src/autoblock/index.ts → code/lib/cli-storybook/src/autoblock/block-dependencies-versions.ts (one verified cycle inside a mutually-dependent group of 10 files)
  • Import cycle (4 files) scripts/sandbox/utils/getPort.ts:2 — scripts/sandbox/utils/getPort.ts → scripts/task.ts → scripts/tasks/bench.ts → scripts/tasks/dev.ts → scripts/sandbox/utils/getPort.ts (one verified cycle inside a mutually-dependent group of 7 files)
AC2 · Forms & labels · <textarea> without a programmatic label · ×1
  • <textarea> without a programmatic label code/addons/docs/src/blocks/controls/react-editable-json-tree/index.tsx:151 — This control has no associated label. Add a <label htmlFor> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
AC3 · Page structure · <html> without a lang · ×1
  • <html> without a lang code/addons/mcp/src/template.html:2 — The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en").
AC3 · Page structure · Document without a <title> · ×1
  • Document without a <title> code/addons/mcp/src/template.html:2 — A page with no <title> gives no name in the tab, history or screen-reader page list. Add a descriptive <title> in <head>.
AC5 · ARIA correctness · aria-hidden hides a focusable element · ×1
  • aria-hidden hides a focusable element code/core/assets/server/base-preview-body.html:17 — aria-hidden="true" here hides the subtree from assistive tech, but a focusable descendant stays in the tab order — a keyboard user can land on a control screen readers can't see. Add inert, take the descendants out of the tab order (tabindex="-1"), or drop aria-hidden.
AX3 · Project dependency cycles · Project dependency cycle · ×1
  • Project dependency cycle code/builders/builder-webpack5/package.json:82 — The projects @storybook/builder-webpack5 → storybook → @storybook/react-webpack5 → @storybook/builder-webpack5 (one cycle inside a mutually-dependent group of 6 projects) form a reference cycle. Cyclic dependencies prevent independent build/test/deploy, blur ownership, and tend to grow into a big ball of mud. Break the cycle by extracting the shared types into a separate project both can reference.
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D30 · Dependency Vulnerabilities · High vulnerability · ×1
  • REDACTED
D5 · Coupling · Circular dependency · ×1
  • Circular dependency code/builders/builder-webpack5/package.json:82 — @storybook/builder-webpack5 → storybook → @storybook/react-webpack5 → @storybook/builder-webpack5 (one cycle inside a mutually-dependent group of 6 modules)
R8 · Dependency Hygiene · Unlisted import '@/app' · ×1
  • Unlisted import '@/app' agent-eval/app/compare/page.tsx:1 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import '@react-aria/live-announcer' · ×1
  • Unlisted import '@react-aria/live-announcer' code/addons/vitest/src/components/TestProviderRender.stories.tsx:7 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import 'picocolors' · ×1
  • Unlisted import 'picocolors' code/builders/builder-vite/src/logger.ts:3 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import 'pathe' · ×1
  • Unlisted import 'pathe' code/builders/builder-webpack5/src/change-detection-adapter/index.ts:9 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import '{{csfImportPath}}' · ×1
  • Unlisted import '{{csfImportPath}}' code/builders/builder-webpack5/templates/virtualModuleModernEntry.js:3 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import '{{storiesFilename}}' · ×1
  • Unlisted import '{{storiesFilename}}' code/builders/builder-webpack5/templates/virtualModuleModernEntry.js:8 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import '@babel/preset-env' · ×1
  • Unlisted import '@babel/preset-env' code/core/src/common/utils/babel.ts:25 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import '@babel/traverse' · ×1
  • Unlisted import '@babel/traverse' code/core/src/csf-tools/__corpus__/record.mjs:31 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import '@polka/url' · ×1
  • Unlisted import '@polka/url' code/core/vitest.config.ts:9 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import 'comment-json' · ×1
  • Unlisted import 'comment-json' code/core/src/cli/eslintPlugin.ts:24 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import 'component-package' · ×1
  • Unlisted import 'component-package' code/core/src/core-server/utils/__mockdata__/src/componentPath/package.stories.js:1 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import 'estree-walker' · ×1
  • Unlisted import 'estree-walker' code/core/src/mocking-utils/esmWalker.ts:35 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R8 · Dependency Hygiene · Unlisted import 'expect-type' · ×1
  • Unlisted import 'expect-type' code/core/src/csf/story.test.ts:4 — Imported but not declared in any reachable REDACTED — installs work only by hoisting accident.
R9 · Circular Imports · Import cycle (10 files) · ×1
  • Import cycle (10 files) code/core/src/actions/addArgs.ts:3 — code/core/src/actions/addArgs.ts → code/core/src/actions/addArgsHelpers.ts → code/core/src/actions/runtime/action.ts → code/core/src/preview-api/index.ts → code/core/src/preview-api/modules/store/csf/index.ts → code/core/src/preview-api/modules/store/csf/composeConfigs.ts → code/core/src/preview-api/modules/store/csf/beforeAll.ts → code/core/src/csf/index.ts → code/core/src/csf/core-annotations.ts → code/core/src/actions/preview.ts → code/core/src/actions/addArgs.ts (one verified cycle inside a mutually-dependent group of 48 files)
Serious — 2582 finding(s)
D8 · Code Coverage · Low coverage · ×338
  • Low coverage: agent-eval/lib/templates.ts agent-eval/lib/templates.ts:1 — 37.2% line coverage (143/384).
  • Low coverage: agent-eval/lib/agentic-reference/external-mcp.ts agent-eval/lib/agentic-reference/external-mcp.ts:1 — 0.0% line coverage (0/10).
  • Low coverage: agent-eval/lib/agentic-reference/external-repo.ts agent-eval/lib/agentic-reference/external-repo.ts:1 — 24.1% line coverage (19/79).
  • Low coverage: agent-eval/lib/agentic-reference/results-tree.ts agent-eval/lib/agentic-reference/results-tree.ts:1 — 46.2% line coverage (12/26).
  • Low coverage: code/addons/docs/src/blocks/controls/options/Checkbox.tsx code/addons/docs/src/blocks/controls/options/Checkbox.tsx:1 — 0.0% line coverage (0/25).
  • Low coverage: code/addons/docs/src/blocks/controls/options/Options.tsx code/addons/docs/src/blocks/controls/options/Options.tsx:1 — 0.0% line coverage (0/15).
  • Low coverage: code/addons/docs/src/csf-plugin/webpack-loader.ts code/addons/docs/src/csf-plugin/webpack-loader.ts:1 — 0.0% line coverage (0/15).
  • Low coverage: code/addons/mcp/src/telemetry.ts code/addons/mcp/src/telemetry.ts:1 — 0.0% line coverage (0/3).
  • Low coverage: code/addons/mcp/src/test-support/register-core-toolsets.ts code/addons/mcp/src/test-support/register-core-toolsets.ts:1 — 0.0% line coverage (0/11).
  • Low coverage: code/addons/mcp/src/tools/get-storybook-story-instructions.ts code/addons/mcp/src/tools/get-storybook-story-instructions.ts:1 — 0.0% line coverage (0/21).
  • Low coverage: code/addons/mcp/src/utils/get-story-index.ts code/addons/mcp/src/utils/get-story-index.ts:1 — 0.0% line coverage (0/6).
  • Low coverage: code/addons/vitest/src/vitest-plugin/test-utils.ts code/addons/vitest/src/vitest-plugin/test-utils.ts:1 — 18.9% line coverage (7/37).
  • Low coverage: code/builders/builder-vite/src/codegen-modern-iframe-script.ts code/builders/builder-vite/src/codegen-modern-iframe-script.ts:1 — 0.0% line coverage (0/9).
  • Low coverage: code/builders/builder-vite/src/preset.ts code/builders/builder-vite/src/preset.ts:1 — 0.0% line coverage (0/8).
  • Low coverage: code/builders/builder-vite/src/transform-iframe-html.ts code/builders/builder-vite/src/transform-iframe-html.ts:1 — 0.0% line coverage (0/18).
  • Low coverage: code/builders/builder-vite/src/change-detection-adapter/index.ts code/builders/builder-vite/src/change-detection-adapter/index.ts:1 — 0.0% line coverage (0/16).
  • Low coverage: REDACTED REDACTED:1 — 0.0% line coverage (0/60).
  • Low coverage: code/builders/builder-vite/src/plugins/storybook-optimize-deps-plugin.ts code/builders/builder-vite/src/plugins/storybook-optimize-deps-plugin.ts:1 — 0.0% line coverage (0/16).
  • Low coverage: code/builders/builder-webpack5/src/change-detection-adapter/index.ts code/builders/builder-webpack5/src/change-detection-adapter/index.ts:1 — 0.0% line coverage (0/37).
  • Low coverage: code/builders/builder-webpack5/src/loaders/storybook-mock-transform-loader.ts code/builders/builder-webpack5/src/loaders/storybook-mock-transform-loader.ts:1 — 0.0% line coverage (0/8).
  • Low coverage: code/core/src/preview-errors.ts code/core/src/preview-errors.ts:1 — 39.3% line coverage (24/61).
  • Low coverage: code/core/src/server-errors.ts code/core/src/server-errors.ts:1 — 37.0% line coverage (74/200).
  • Low coverage: code/core/src/actions/addArgsHelpers.ts code/core/src/actions/addArgsHelpers.ts:1 — 0.0% line coverage (0/22).
  • Low coverage: code/core/src/actions/preview.ts code/core/src/actions/preview.ts:1 — 0.0% line coverage (0/1).
  • Low coverage: code/core/src/actions/runtime/action.ts code/core/src/actions/runtime/action.ts:1 — 0.0% line coverage (0/40).
  • + 313 more in this group — see findings.md.
D10 · Test Quality · No assertions · ×307
  • No assertions: ✅ All required args may be provided in meta code/renderers/web-components/src/csf-factories.test.ts:96 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: ✅ Required args may be provided partial in meta and the story code/renderers/web-components/src/csf-factories.test.ts:105 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: ❌ The combined shape of meta args and story args must match the required args. code/renderers/web-components/src/csf-factories.test.ts:115 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: ✅ Required args don't need to be provided when the user uses an empty render code/renderers/web-components/src/csf-factories.test.ts:140 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: ❌ Required args need to be provided when the user uses a non-empty render code/renderers/web-components/src/csf-factories.test.ts:152 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: Correct args are inferred when type is widened for render function code/renderers/web-components/src/csf-factories.test.ts:170 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: Args of a typed render can be set in meta code/renderers/web-components/src/csf-factories.test.ts:184 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: Correct args are inferred when type is widened for decorators code/renderers/web-components/src/csf-factories.test.ts:199 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: Correct args are inferred when type is widened for multiple decorators code/renderers/web-components/src/csf-factories.test.ts:209 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: args can be reused code/renderers/web-components/src/csf-factories.test.ts:231 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: stories can be extended code/renderers/web-components/src/csf-factories.test.ts:240 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: Components without Props can be used code/renderers/web-components/src/csf-factories.test.ts:250 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: ✅ A custom arg can be set in meta and used in render code/renderers/web-components/src/csf-factories.test.ts:282 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: ✅ A custom args type is used by the render of a meta without component code/renderers/web-components/src/csf-factories.test.ts:292 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: ❌ An element class as the custom args type requires every member of that class code/renderers/web-components/src/csf-factories.test.ts:305 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: literal, enum, template literal and branded props need no `as const` code/renderers/web-components/src/csf-factories.test.ts:337 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: meta.input.args keeps the declared prop types code/renderers/web-components/src/csf-factories.test.ts:348 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: fn() args are typed as declared, mocked() gives the mock API code/renderers/web-components/src/csf-factories.test.ts:360 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: invalid meta args are rejected code/renderers/web-components/src/csf-factories.test.ts:370 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: meta.story() needs no args when meta provides all required args code/renderers/web-components/src/csf-factories.test.ts:398 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: union props accept keys shared by every member code/renderers/web-components/src/csf-factories.test.ts:406 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: args declared with preview.type<>() and decorators code/renderers/web-components/src/csf-factories.test.ts:420 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: render-only meta code/renderers/web-components/src/csf-factories.test.ts:432 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: meta without component or render accepts any args code/renderers/web-components/src/csf-factories.test.ts:442 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • No assertions: a meta like the Button stories of the sandboxes code/renderers/web-components/src/csf-factories.test.ts:448 — This method's body runs code, and no assertion call was recognised in it. Recognised by name: Assert*, *Should*/ShouldBe*, Verify, Expect, Throws, Record, Received/DidNotReceive, MustHaveHappened/MustNotHaveHappened, EnsureSuccessStatusCode and *AndEnsure* — so verification routed through a helper of your own naming, through a base-class or callback object whose members hold the assertions, or through a harness that fails by throwing under some other name, is not visible to this check and is not counted here. Read it as 'no assertion this check knows how to see', and if that is right, add one.
  • + 282 more in this group — see findings.md.
D17 · Explicit Debt · TodoComment · ×180
  • TodoComment test-storybooks/portable-stories-kitchen-sink/vue3/.storybook/preview.ts:6 — // TODO: figure out decorators — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment test-storybooks/portable-stories-kitchen-sink/svelte/stories/Button.cy.tsx:9 — // TODO figure out the following issue ReferenceError: $state is not defined — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment scripts/task.ts:154 — // // TODO -- feature flags — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment scripts/utils/cli-step.ts:30 — // TODO allow default values for strings — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment scripts/utils/yarn.ts:4 — // TODO -- should we generate this file a second time outside of CLI? — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment scripts/tasks/sandbox-parts.ts:430 — // TODO: Remove this once Storybook Nuxt applies this internally — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment scripts/tasks/sandbox-parts.ts:463 — // TODO: We should definitely improve the logic here, as it will break every time the stories field change format in the generated sandboxes. — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment scripts/check/check-package.ts:110 — // TODO, add more package checks here, like: — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/web-components/src/index.ts:14 — // TODO: disable HMR and do full page loads because of customElements.define — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/vue3/src/portable-stories.ts:126 — // TODO: we should do the same for composeStories as well — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/vue3/src/types.ts:34 — // TODO add proper typesafety — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/svelte/src/types.ts:15 — // TODO add proper typesafety — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/vue3/src/docgen/story-docs/source-decorator/sourceDecorator.ts:294 — // TODO: check if functions should be rendered in source code — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/vue3/src/docgen/story-docs/source-decorator/sourceDecorator.ts:448 — // TODO: it should be possible to extend the proxy logic here and maybe get rid of the `generatePropsSourceCode` and `getFunctionParamNames` — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/svelte/src/svelte-csf/runtime/create-runtime-stories.ts:122 — // TODO: Restore this feature — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/svelte/src/svelte-csf/runtime/emit-code.ts:37 — // TODO: fix this in @storybook/svelte, don't emit when using stories.svelte files — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/svelte/src/svelte-csf/runtime/emit-code.ts:84 — // TODO: do this at the final stage instead, taking into account the singular args replacements — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/svelte/src/svelte-csf/runtime/emit-code.ts:86 — // TODO: the indentation only works if it's in the root-level component. In a nested component, the indentation will be too shallow — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/svelte/src/svelte-csf/indexer/parser.ts:223 — // TODO: This could actually work in the future, by supporting referencing a template — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/svelte/src/__test__/composeStories/portable-stories.test.ts:140 — // TODO: @JReinhold maybe you can figure this error out? — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/react/src/enrichCsf.ts:32 — // TODO read the user config — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/react/src/preview.tsx:71 — // TODO: [test-syntax] Are we sure we want this? the Component construct was for — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/react/src/componentManifest/reactDocgen.ts:34 — // TODO: None of these are able to be overridden, so `default` is aspirational here. — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/frameworks/react-vite/src/plugins/react-docgen.ts:29 — // TODO: None of these are able to be overridden, so `default` is aspirational here. — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment code/renderers/react/src/componentManifest/reactDocgen/extractReactTypescriptDocgenInfo.test.ts:22 — // TODO: Norbert figure this out thank you — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • + 155 more in this group — see findings.md.
D15 · Churn × Complexity Hotspots · Hotspot · ×128
  • Hotspot: code/core/src/csf-tools/CsfObject.ts code/core/src/csf-tools/CsfObject.ts:692 — code/core/src/csf-tools/CsfObject.ts changed 86 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 46 in Editor.groupValues at line 692. 30 of those changes were fix/bug commits, and the other 56 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/csf-tools/CsfObject.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/manager/components/sidebar/Tree.tsx code/core/src/manager/components/sidebar/Tree.tsx:118 — code/core/src/manager/components/sidebar/Tree.tsx changed 45 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 85 in Tree.Tree at line 118. 3 of those changes were fix/bug commits, and the other 42 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/manager/components/sidebar/Tree.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: REDACTED REDACTED:891 — REDACTED changed 50 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 57 in CsfFile._visitExportNamed at line 891. 19 of those changes were fix/bug commits, and the other 31 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- REDACTED`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/csf-tools/ConfigFile.ts code/core/src/csf-tools/ConfigFile.ts:538 — code/core/src/csf-tools/ConfigFile.ts changed 67 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 41 in ConfigFile.parse at line 538. 21 of those changes were fix/bug commits, and the other 46 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/csf-tools/ConfigFile.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/manager-api/modules/stories.ts code/core/src/manager-api/modules/stories.ts:433 — code/core/src/manager-api/modules/stories.ts changed 19 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 135 in stories.init at line 433. 2 of those changes were fix/bug commits, and the other 17 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/manager-api/modules/stories.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/csf-tools/estree/editor.ts code/core/src/csf-tools/estree/editor.ts:1082 — code/core/src/csf-tools/estree/editor.ts changed 90 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in editor.appendFirst at line 1082. 51 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/csf-tools/estree/editor.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.ts code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.ts:83 — code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.ts changed 26 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 79 in story-to-csf-factory.storyToCsfFactory at line 83. 11 of those changes were fix/bug commits, and the other 15 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/csf-tools/ConfigObject.ts code/core/src/csf-tools/ConfigObject.ts:78 — code/core/src/csf-tools/ConfigObject.ts changed 22 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 67 in ConfigObject.locateConfigRoot at line 78. 7 of those changes were fix/bug commits, and the other 15 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/csf-tools/ConfigObject.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: agent-eval/lib/shell-parse.ts agent-eval/lib/shell-parse.ts:438 — agent-eval/lib/shell-parse.ts changed 29 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 49 in shell-parse.scanShellWords at line 438. 4 of those changes were fix/bug commits, and the other 25 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- agent-eval/lib/shell-parse.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/frameworks/angular-vite/src/preset.ts code/frameworks/angular-vite/src/preset.ts:81 — code/frameworks/angular-vite/src/preset.ts changed 44 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in preset.viteFinal at line 81. 3 of those changes were fix/bug commits, and the other 41 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/frameworks/angular-vite/src/preset.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/manager/components/sidebar/Search.tsx code/core/src/manager/components/sidebar/Search.tsx:177 — code/core/src/manager/components/sidebar/Search.tsx changed 18 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 59 in Search.Search at line 177. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/manager/components/sidebar/Search.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:520 — code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts changed 25 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in transform-template.transformDirective at line 520. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/csf-tools/estree/scope.ts code/core/src/csf-tools/estree/scope.ts:569 — code/core/src/csf-tools/estree/scope.ts changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 81 in scope.analyzeScopes.visitNode at line 569. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/csf-tools/estree/scope.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/cli/tools/run.ts code/core/src/cli/tools/run.ts:258 — code/core/src/cli/tools/run.ts changed 42 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 23 in run.dispatchTools at line 258. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/cli/tools/run.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/lib/cli-storybook/src/upgrade.ts code/lib/cli-storybook/src/upgrade.ts:352 — code/lib/cli-storybook/src/upgrade.ts changed 18 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 49 in upgrade.upgrade at line 352. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/upgrade.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/csf-tools/CsfObjectDiscovery.ts code/core/src/csf-tools/CsfObjectDiscovery.ts:594 — code/core/src/csf-tools/CsfObjectDiscovery.ts changed 36 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in CsfObjectDiscovery.discoverStories at line 594. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/csf-tools/CsfObjectDiscovery.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: agent-eval/lib/test-utils.ts agent-eval/lib/test-utils.ts:1092 — agent-eval/lib/test-utils.ts changed 36 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 24 in test-utils.getBrowserStepsAroundWorkflowCalls at line 1092. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- agent-eval/lib/test-utils.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/lib/cli-storybook/src/automigrate/index.ts code/lib/cli-storybook/src/automigrate/index.ts:253 — code/lib/cli-storybook/src/automigrate/index.ts changed 21 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 38 in index.runFixes at line 253. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/index.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/addons/vitest/src/vitest-plugin/index.ts code/addons/vitest/src/vitest-plugin/index.ts:197 — code/addons/vitest/src/vitest-plugin/index.ts changed 18 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 41 in index.storybookTest at line 197. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/addons/vitest/src/vitest-plugin/index.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/lib/cli-storybook/src/codemod/helpers/wrap-args-mocks.ts code/lib/cli-storybook/src/codemod/helpers/wrap-args-mocks.ts:70 — code/lib/cli-storybook/src/codemod/helpers/wrap-args-mocks.ts changed 14 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 46 in wrap-args-mocks.wrapArgsMocks at line 70. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/codemod/helpers/wrap-args-mocks.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/shared/open-service/toolsets/docs/definition.ts code/core/src/shared/open-service/toolsets/docs/definition.ts:399 — code/core/src/shared/open-service/toolsets/docs/definition.ts changed 23 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 28 in definition.createDocsToolset at line 399. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/shared/open-service/toolsets/docs/definition.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/frameworks/angular-vite/src/docgen/story-docs-args.ts code/frameworks/angular-vite/src/docgen/story-docs-args.ts:125 — code/frameworks/angular-vite/src/docgen/story-docs-args.ts changed 19 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 33 in story-docs-args.evaluateNode at line 125. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/frameworks/angular-vite/src/docgen/story-docs-args.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/renderers/vue3/src/docgen/story-docs/build-story-docs.ts code/renderers/vue3/src/docgen/story-docs/build-story-docs.ts:296 — code/renderers/vue3/src/docgen/story-docs/build-story-docs.ts changed 41 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 15 in build-story-docs.enrichStoryDoc at line 296. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/renderers/vue3/src/docgen/story-docs/build-story-docs.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: code/core/src/manager-api/modules/shortcuts.ts code/core/src/manager-api/modules/shortcuts.ts:197 — code/core/src/manager-api/modules/shortcuts.ts changed 10 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 61 in shortcuts.init at line 197. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/manager-api/modules/shortcuts.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Hotspot: scripts/tasks/sandbox-parts.ts scripts/tasks/sandbox-parts.ts:713 — scripts/tasks/sandbox-parts.ts changed 28 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in sandbox-parts.addStories at line 713. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- scripts/tasks/sandbox-parts.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • + 103 more in this group — see findings.md.
D10 · Test Quality · Skipped test · ×106
  • Skipped test: renders with loaders and play function test-storybooks/portable-stories-kitchen-sink/vue3/stories/Button.cy.tsx:19 — Skipped — switched off by it.skip
  • Skipped test: renders with play function test-storybooks/portable-stories-kitchen-sink/vue3/stories/Button.cy.tsx:34 — Skipped — switched off by it.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:144 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:210 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:282 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:341 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:380 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:420 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:450 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:512 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:558 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:611 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:673 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:745 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/save-from-controls.spec.ts:11 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/save-from-controls.spec.ts:22 — Skipped — switched off by test.skip
  • Skipped test: ${testEntry.name} code/renderers/react/src/extractArgTypes.test.ts:74 — Skipped — switched off by it.skip
  • Skipped test: (unnamed test) code/e2e-sandbox/addon-actions.spec.ts:11 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) code/e2e-sandbox/addon-actions.spec.ts:15 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) code/e2e-sandbox/addon-actions.spec.ts:38 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) code/e2e-sandbox/addon-controls.spec.ts:11 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) code/e2e-sandbox/addon-controls.spec.ts:112 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) code/e2e-sandbox/addon-docs.spec.ts:23 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) code/e2e-sandbox/addon-docs.spec.ts:44 — Skipped — switched off by test.skip
  • Skipped test: (unnamed test) code/e2e-sandbox/addon-docs.spec.ts:84 — Skipped — switched off by test.skip
  • + 81 more in this group — see findings.md.
D3 · God Classes · FunctionTooLong · ×75
  • FunctionTooLong: scope.analyzeScopes code/core/src/csf-tools/estree/scope.ts:293 — FunctionTooLong — analyzeScopes runs 436 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 336 over it, 4.36× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: Tree.Tree code/core/src/manager/components/sidebar/Tree.tsx:118 — FunctionTooLong — Tree runs 423 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 323 over it, 4.23× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: useHighlights.useHighlights code/core/src/highlight/useHighlights.ts:36 — FunctionTooLong — useHighlights runs 399 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 299 over it, 3.99× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: codex-browser-client-mock.createTab agent-eval/lib/mcp/codex-browser-client-mock.mjs:343 — FunctionTooLong — createTab runs 300 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 200 over it, 3.00× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: DocsPage.DocsContent code/addons/docs/src/blocks/components/DocsPage.tsx:60 — FunctionTooLong — DocsContent runs 292 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 192 over it, 2.92× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: A11yContext.A11yContextProvider code/addons/a11y/src/components/A11yContext.tsx:111 — FunctionTooLong — A11yContextProvider runs 281 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 181 over it, 2.81× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: identify.createResolver agent-eval/lib/agentic-reference/metrics/ds-coverage/identify.ts:90 — FunctionTooLong — createResolver runs 244 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 144 over it, 2.44× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: index.storybookTest code/addons/vitest/src/vitest-plugin/index.ts:197 — FunctionTooLong — storybookTest runs 242 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 142 over it, 2.42× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: Search.Search code/core/src/manager/components/sidebar/Search.tsx:177 — FunctionTooLong — Search runs 237 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 137 over it, 2.37× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: DocumentWrapper.DocumentWrapper code/core/src/components/components/typography/DocumentWrapper.tsx:3 — FunctionTooLong — DocumentWrapper runs 236 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 136 over it, 2.36× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: shortcuts.init code/core/src/manager-api/modules/shortcuts.ts:197 — FunctionTooLong — init runs 236 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 136 over it, 2.36× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: collect-pr-data.ensureViews scripts/eval/collect-pr-data.ts:446 — FunctionTooLong — ensureViews runs 230 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 130 over it, 2.30× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: layout.init code/core/src/manager-api/modules/layout.ts:264 — FunctionTooLong — init runs 227 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 127 over it, 2.27× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: Onboarding.Onboarding code/addons/onboarding/src/Onboarding.tsx:47 — FunctionTooLong — Onboarding runs 213 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 113 over it, 2.13× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: SummaryScreen.SummaryScreen code/core/src/manager/components/review/screens/SummaryScreen.tsx:295 — FunctionTooLong — SummaryScreen runs 199 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 99 over it, 1.99× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: Checklist.Checklist code/core/src/manager/settings/Checklist/Checklist.tsx:254 — FunctionTooLong — Checklist runs 197 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 97 over it, 1.97× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: TestingWidget.TestingWidget code/core/src/manager/components/sidebar/TestingWidget.tsx:159 — FunctionTooLong — TestingWidget runs 192 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 92 over it, 1.92× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: upgrade.upgrade code/lib/cli-storybook/src/upgrade.ts:352 — FunctionTooLong — upgrade runs 191 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 91 over it, 1.91× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: FilterPanel.FilterPanel code/core/src/manager/components/sidebar/FilterPanel.tsx:42 — FunctionTooLong — FilterPanel runs 189 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 89 over it, 1.89× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: TreeNode.TreeNode code/core/src/manager/components/sidebar/TreeNode.tsx:270 — FunctionTooLong — TreeNode runs 183 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 83 over it, 1.83× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: postinstall.postInstall code/addons/vitest/src/postinstall.ts:58 — FunctionTooLong — postInstall runs 182 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 82 over it, 1.82× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: service-sync.createReconciler code/core/src/shared/open-service/service-sync.ts:237 — FunctionTooLong — createReconciler runs 182 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 82 over it, 1.82× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ConfigObject.locateConfigRoot code/core/src/csf-tools/ConfigObject.ts:78 — FunctionTooLong — locateConfigRoot runs 179 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 79 over it, 1.79× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: ReviewProvider.ReviewProvider code/core/src/manager/components/review/components/ReviewProvider.tsx:69 — FunctionTooLong — ReviewProvider runs 177 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 77 over it, 1.77× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • FunctionTooLong: patch-recorder.recordPatch code/core/src/shared/open-service/patch-recorder.ts:80 — FunctionTooLong — recordPatch runs 177 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 77 over it, 1.77× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • + 50 more in this group — see findings.md.
PF3 · Async & latency hygiene · Sync-over-async blocking · ×40
  • Sync-over-async blocking agent-eval/lib/post-analysis/baseline.ts:213 — `mkdirSync` in `loadOrBuildBaselineAnalysis` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking agent-eval/lib/post-analysis/baseline.ts:227 — `writeFileSync` in `loadOrBuildBaselineAnalysis` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/addons/themes/src/postinstall.ts:20 — `spawnSync` in `postinstall` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/addons/vitest/src/node/vitest-manager.ts:104 — `existsSync` in `startVitest` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/addons/vitest/src/node/vitest-manager.ts:106 — `readFileSync` in `startVitest` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/addons/vitest/src/node/vitest-manager.ts:580 — `existsSync` in `callback to dependencies.map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/builders/builder-vite/src/plugins/code-generator-plugin.ts:97 — `readFileSync` in `load` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking REDACTED:82 — `existsSync` in `callback to map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/builders/builder-vite/src/vite-config.ts:134 — `existsSync` in `resolveVitePublicDir` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/scripts/generate-source-files.ts:136 — `existsSync` in `callback to filter` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/builder-manager/utils/files.ts:20 — `existsSync` in `callback to outputFiles.map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/builder-manager/utils/managerEntries.ts:60 — `existsSync` in `callback to entrypoints.map` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/cli/detectLanguage.ts:20 — `existsSync` in `detectLanguage` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/cli/detectLanguage.ts:35 — `existsSync` in `detectLanguage` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/cli/helpers.ts:108 — `existsSync` in `cliStoriesTargetPath` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/cli/helpers.ts:140 — `existsSync` in `templatePath` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/cli/helpers.ts:144 — `existsSync` in `templatePath` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/cli/helpers.ts:148 — `existsSync` in `templatePath` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/cli/helpers.ts:152 — `existsSync` in `templatePath` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking REDACTED:127 — `readFileSync` in `getModulePackageJSON` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/common/js-package-manager/NPMProxy.ts:117 — `readFileSync` in `getModulePackageJSON` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/common/js-package-manager/PNPMProxy.ts:227 — `readFileSync` in `getModulePackageJSON` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/common/js-package-manager/Yarn1Proxy.ts:112 — `readFileSync` in `getModulePackageJSON` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/common/js-package-manager/Yarn2Proxy.ts:193 — `readFileSync` in `getModulePackageJSON` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • Sync-over-async blocking code/core/src/common/utils/cli.ts:20 — `mkdirSync` in `temporaryDirectory` blocks the event loop until it finishes — a blocking call inside async code stalls the event loop — every other request waits for as long as it runs.
  • + 15 more in this group — see findings.md.
R11 · Import Boundaries · Boundary violation [package · ×40
  • Boundary violation [package:relative-cross-package] agent-eval/scripts/eval-gate-thread.ts:20 — agent-eval/scripts/eval-gate-thread.ts:20 reaches into another package with a relative path (../../scripts/utils/gh.ts) — import the package by name instead.
  • Boundary violation [package:test-suite-dependency] code/addons/mcp/scripts/generate-tools-api-doc.ts:18 — code/addons/mcp/scripts/generate-tools-api-doc.ts:18 imports code/addons/mcp/src/test-support/register-core-toolsets.ts, a module inside the test suite — test helpers carry no compatibility contract and are maintained for the suite, not as an API, so production code that depends on one is coupled to a module nobody keeps stable. Move the shared helper into a source directory both layers may depend on.
  • Boundary violation [package:relative-cross-package] code/addons/onboarding/src/Onboarding.tsx:9 — code/addons/onboarding/src/Onboarding.tsx:9 reaches into another package with a relative path (../../../core/src/manager/components/TourGuide/HighlightElement.tsx) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/onboarding/src/Onboarding.tsx:10 — code/addons/onboarding/src/Onboarding.tsx:10 reaches into another package with a relative path (../../../core/src/manager/components/TourGuide/TourGuide.tsx) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/onboarding/src/features/IntentSurvey/IntentSurvey.tsx:7 — code/addons/onboarding/src/features/IntentSurvey/IntentSurvey.tsx:7 reaches into another package with a relative path (../../../../../.storybook/isChromatic.ts) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/vitest/src/constants.ts:5 — code/addons/vitest/src/constants.ts:5 reaches into another package with a relative path (../../../core/src/component-testing/constants.ts) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/vitest/src/constants.ts:6 — code/addons/vitest/src/constants.ts:6 reaches into another package with a relative path (../../../addons/a11y/src/constants.ts) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/vitest/src/custom-matchers.d.ts:3 — code/addons/vitest/src/custom-matchers.d.ts:3 reaches into another package with a relative path (../../../core/src/shared/utils/toHaveLiveRegion) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/vitest/src/node/boot-test-runner.ts:17 — code/addons/vitest/src/node/boot-test-runner.ts:17 reaches into another package with a relative path (../../../../core/src/shared/utils/module.ts) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/vitest/src/postinstall.ts:33 — code/addons/vitest/src/postinstall.ts:33 reaches into another package with a relative path (../../../lib/cli-storybook/src/add.ts) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/vitest/src/vitest-plugin/agent-telemetry-reporter.ts:11 — code/addons/vitest/src/vitest-plugin/agent-telemetry-reporter.ts:11 reaches into another package with a relative path (../../../../core/src/shared/utils/ai-checklist-flags.ts) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/addons/vitest/src/vitest-plugin/index.ts:44 — code/addons/vitest/src/vitest-plugin/index.ts:44 reaches into another package with a relative path (../../../../builders/builder-vite/src/utils/without-vite-plugins.ts) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/builders/builder-vite/src/plugins/code-generator-plugin.ts:9 — code/builders/builder-vite/src/plugins/code-generator-plugin.ts:9 reaches into another package with a relative path (../../../../core/src/shared/utils/module.ts) — import the package by name instead.
  • Boundary violation [package:relative-cross-package] code/core/src/component-testing/components/Panel.tsx:24 — code/core/src/component-testing/components/Panel.tsx:24 reaches into another package with a relative path (../../../../addons/vitest/src/constants.ts) — import the package by name instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:8 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:8 imports react-syntax-highlighter/dist/esm/create-element, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:9 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:9 imports react-syntax-highlighter/dist/esm/languages/prism/bash, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:10 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:10 imports react-syntax-highlighter/dist/esm/languages/prism/css, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:11 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:11 imports react-syntax-highlighter/dist/esm/languages/prism/graphql, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:13 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:13 imports react-syntax-highlighter/dist/esm/languages/prism/js-extras, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:14 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:14 imports react-syntax-highlighter/dist/esm/languages/prism/json, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:15 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:15 imports react-syntax-highlighter/dist/esm/languages/prism/jsx, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:16 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:16 imports react-syntax-highlighter/dist/esm/languages/prism/markdown, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:17 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:17 imports react-syntax-highlighter/dist/esm/languages/prism/markup, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:18 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:18 imports react-syntax-highlighter/dist/esm/languages/prism/tsx, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • Boundary violation [package:third-party-deep-import] code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:19 — code/core/src/components/components/syntaxhighlighter/syntaxhighlighter.tsx:19 imports react-syntax-highlighter/dist/esm/languages/prism/typescript, reaching past a declared dependency's public entry into its build output — that path is the package's toolchain layout, not its API, and a minor version bump can relocate it with no semver signal. Import from the package's documented entry point instead.
  • + 15 more in this group — see findings.md.
X24 · Document value interpolated into markup unescaped · Untrusted text written into markup unescaped · ×40
  • Untrusted text written into markup unescaped agent-eval/lib/agentic-reference/comparison/html-report.ts:920 — `tip` is text this program did not author, and it is written into an unquoted attribute through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. HTML text encoding does not help in an unquoted attribute — whitespace ends it; quote the attribute and encode the value.
  • Untrusted text written into markup unescaped agent-eval/lib/agentic-reference/comparison/html-report.ts:2012 — `wfAttr` is text this program did not author, and it is written into an unquoted attribute through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. HTML text encoding does not help in an unquoted attribute — whitespace ends it; quote the attribute and encode the value.
  • Untrusted text written into markup unescaped agent-eval/lib/agentic-reference/comparison/html-report.ts:2232 — `wfAttr` is text this program did not author, and it is written into an unquoted attribute through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. HTML text encoding does not help in an unquoted attribute — whitespace ends it; quote the attribute and encode the value.
  • Untrusted text written into markup unescaped agent-eval/lib/agentic-reference/comparison/html-report.ts:2257 — `wfAttr` is text this program did not author, and it is written into an unquoted attribute through markup this function returns with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. HTML text encoding does not help in an unquoted attribute — whitespace ends it; quote the attribute and encode the value.
  • Untrusted text written into markup unescaped code/addons/a11y/src/components/VisionSimulator.tsx:64 — `filterDefs` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/addons/a11y/src/withVisionSimulator.ts:43 — `filterDefs` is text this program did not author, and it is written into the text of an element through `insertAdjacentHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/addons/pseudo-states/src/stories/ShadowRoot.tsx:38 — `label` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/addons/pseudo-states/src/stories/ShadowRootWithPart.tsx:15 — `label` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/assets/server/template.ejs:52 — `head` is text this program did not author, and it is written into the text of an element through EJS's raw `<%- %>` output with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/assets/server/template.ejs:71 — `(globals[varName])` is text this program did not author, and it is written into a script or style context through EJS's raw `<%- %>` output with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. A script or style context needs its own escaping (or a JSON serialiser that escapes `<`); better, pass the value through a data attribute.
  • Untrusted text written into markup unescaped code/core/src/backgrounds/utils.ts:35 — `css` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/backgrounds/utils.ts:40 — `css` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/backgrounds/utils.ts:53 — `css` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/backgrounds/utils.ts:58 — `css` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped REDACTED:225 — `filter.toHtml(paragraphs[0])` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped REDACTED:195 — `filter.toHtml(printSerializedError(caughtException))` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/component-testing/components/MatcherResult.tsx:139 — `filter.toHtml(line)` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped REDACTED:453 — `e instanceof Error?e.stack:String(e)` is text this program did not author, and it is written into the text of an element through `res.end` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/highlight/useHighlights.ts:157 — `keyframes` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/manager/components/TourGuide/TourTooltip.tsx:115 — `` .__floater__arrow { container-type: size; } .__floater__arrow span { background: ${color.secondary}; } …` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/manager/components/sidebar/Brand.tsx:48 — `title` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/manager/components/sidebar/Brand.tsx:50 — `title` is text this program did not author, and it is written into the text of an element through `dangerouslySetInnerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/outline/helpers.ts:20 — `css` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/outline/helpers.ts:25 — `css` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • Untrusted text written into markup unescaped code/core/src/preview-api/modules/preview-web/WebView.ts:181 — `ansiConverter.toHtml(header)` is text this program did not author, and it is written into the text of an element through `innerHTML` with nothing encoding it for that place. Whoever controls the value controls the markup: it can close the element or attribute it sits in and open a script of its own. Encode it for HTML at this site, render it through the framework's escaping output, or sanitise it if it must stay markup.
  • + 15 more in this group — see findings.md.
D29 · Static Analysis (SAST) · REDACTED · ×36
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • + 11 more in this group — see findings.md.
D30 · Dependency Vulnerabilities · Medium CVE · ×35
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • + 10 more in this group — see findings.md.
D15 · Churn × Complexity Hotspots · Repeated repair · ×34
  • Repeated repair: code/lib/cli-storybook/src/codemod/helpers/custom-args-type.ts code/lib/cli-storybook/src/codemod/helpers/custom-args-type.ts:15 — code/lib/cli-storybook/src/codemod/helpers/custom-args-type.ts changed 20 times in last 90 days and 12 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 10 (its worst body is custom-args-type.customArgsTypes at line 15), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(cli): parenthesize conditional and constructor types in custom args intersections”; “fix(cli): compare bigint literals and namespaced components in custom args types”; “fix(cli): compare custom args types by their trees”; “fix(cli): keep a union story type whole and read method meta args in csf-factories codemod”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/codemod/helpers/custom-args-type.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/renderers/react/src/preview.tsx code/renderers/react/src/preview.tsx:52 — code/renderers/react/src/preview.tsx changed 19 times in last 90 days and 11 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is preview.__definePreview at line 52), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(csf): keep addons required in definePreview”; “fix(csf): infer addon types from typed entries so framework casts resolve”; “fix(csf): require a meta arg again when meta.type<>() redeclares it”; “fix(csf): handle a typed meta held in a constant and constrain meta.type<>()”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/renderers/react/src/preview.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/renderers/web-components/src/preview.ts code/renderers/web-components/src/preview.ts:49 — code/renderers/web-components/src/preview.ts changed 17 times in last 90 days and 11 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is preview.__definePreview at line 49), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(csf): keep addons required in definePreview”; “fix(csf): infer addon types from typed entries so framework casts resolve”; “fix(csf): require a meta arg again when meta.type<>() redeclares it”; “fix(csf): handle a typed meta held in a constant and constrain meta.type<>()”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/renderers/web-components/src/preview.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/renderers/vue3/src/preview.ts code/renderers/vue3/src/preview.ts:48 — code/renderers/vue3/src/preview.ts changed 16 times in last 90 days and 10 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is preview.__definePreview at line 48), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(csf): keep addons required in definePreview”; “fix(csf): require a meta arg again when meta.type<>() redeclares it”; “fix(cli): make a story-only custom args type optional next to a component in csf-factories codemod”; “fix(csf): handle a typed meta held in a constant and constrain meta.type<>()”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/renderers/vue3/src/preview.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/core/src/shared/open-service/toolsets/stories/format.ts code/core/src/shared/open-service/toolsets/stories/format.ts:121 — code/core/src/shared/open-service/toolsets/stories/format.ts changed 14 times in last 90 days and 8 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 10 (its worst body is format.serializeComponentSection at line 121), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(core): apply review feedback on the stories changed note”; “fix(core): keep the original coverage sanity check wording”; “fix(core): fit the coverage gap into one paragraph so tail keeps the story list”; “fix(core): name the coverage gap files in code and end on the review step that includes them”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/shared/open-service/toolsets/stories/format.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/frameworks/angular-vite/src/client/preview.ts code/frameworks/angular-vite/src/client/preview.ts:49 — code/frameworks/angular-vite/src/client/preview.ts changed 14 times in last 90 days and 8 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is preview.__definePreview at line 49), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(csf): keep addons required in definePreview”; “fix(csf): require a meta arg again when meta.type<>() redeclares it”; “fix(csf): handle a typed meta held in a constant and constrain meta.type<>()”; “fix(csf): keep argTypes and loosely typed renders from changing meta args”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/frameworks/angular-vite/src/client/preview.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/frameworks/angular/src/client/preview.ts code/frameworks/angular/src/client/preview.ts:49 — code/frameworks/angular/src/client/preview.ts changed 14 times in last 90 days and 8 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is preview.__definePreview at line 49), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(csf): keep addons required in definePreview”; “fix(csf): require a meta arg again when meta.type<>() redeclares it”; “fix(csf): handle a typed meta held in a constant and constrain meta.type<>()”; “fix(csf): keep argTypes and loosely typed renders from changing meta args”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/frameworks/angular/src/client/preview.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/core/src/cli/AddonVitestService.ts code/core/src/cli/AddonVitestService.ts:150 — code/core/src/cli/AddonVitestService.ts changed 11 times in last 90 days and 7 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 11 (its worst body is AddonVitestService.installPlaywright at line 150), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(csf-tools): pass the file name wherever a parser call site has one”; “fix(core): confirm the npx download prompt in the npm and Yarn 1 proxies”; “fix(core): confirm the npx install prompt during the Playwright browser install”; “fix(cli): harden vitest peer guard and install error tail”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/cli/AddonVitestService.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/core/src/shared/open-service/toolsets/stories/find-story-ids.ts code/core/src/shared/open-service/toolsets/stories/find-story-ids.ts:70 — code/core/src/shared/open-service/toolsets/stories/find-story-ids.ts changed 10 times in last 90 days and 7 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 14 (its worst body is find-story-ids.suggestStoryIds at line 70), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(core): count a misspelled component ID as the same component in story hints”; “fix(core): rank the closest file stories by export name too”; “fix(core): match title prefixes on segment boundaries in story hints”; “fix(core): match an explicit story name only on stories”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/shared/open-service/toolsets/stories/find-story-ids.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/lib/cli-storybook/src/automigrate/fixes/react-vite-to-tanstack-react.ts code/lib/cli-storybook/src/automigrate/fixes/react-vite-to-tanstack-react.ts:32 — code/lib/cli-storybook/src/automigrate/fixes/react-vite-to-tanstack-react.ts changed 8 times in last 90 days and 7 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is react-vite-to-tanstack-react.buildAiMigrationPrompt at line 32), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “Automigrate: keep fix statuses stable across runs and guard inherited frameworks”; “Automigrate: make the Angular and TanStack fixes fail before changing dependencies”; “Automigrate: simplify the TanStack, React Native, a11y, and upgrade fixes”; “Automigrate: stop detecting a fix once it is known to apply”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/fixes/react-vite-to-tanstack-react.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/lib/cli-storybook/src/automigrate/fixes/argtypes-default-value.ts code/lib/cli-storybook/src/automigrate/fixes/argtypes-default-value.ts:8 — code/lib/cli-storybook/src/automigrate/fixes/argtypes-default-value.ts changed 9 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 5 (its worst body is argtypes-default-value.argName at line 8), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(cli): migrate argtypes-default-value for a file with an alias story”; “fix(csf-tools)!: let reads follow any constant and leave diagnostics to mutations”; “fix: limit Carbon QA changes to natural upgrade failures”; “fix: address Carbon QA review findings”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/fixes/argtypes-default-value.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/lib/cli-storybook/src/automigrate/fixes/wrap-getAbsolutePath.ts code/lib/cli-storybook/src/automigrate/fixes/wrap-getAbsolutePath.ts:28 — code/lib/cli-storybook/src/automigrate/fixes/wrap-getAbsolutePath.ts changed 9 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 5 (its worst body is editConfig at line 28), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(csf-tools): place appended statements, moved comments and commas where they read”; “fix(cli): indent the getAbsolutePath wrapper like the config and set it apart”; “Automigrate: trim the small fixes to what they use”; “Automigrate: stream file edits of all fixes through one transform pipeline”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/fixes/wrap-getAbsolutePath.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/lib/cli-storybook/src/automigrate/fixes/upgrade-storybook-related-dependencies.ts code/lib/cli-storybook/src/automigrate/fixes/upgrade-storybook-related-dependencies.ts:29 — code/lib/cli-storybook/src/automigrate/fixes/upgrade-storybook-related-dependencies.ts changed 9 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 2 (its worst body is upgrade-storybook-related-dependencies.scopeOf at line 29), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “Automigrate: make the Angular and TanStack fixes fail before changing dependencies”; “Automigrate: simplify the TanStack, React Native, a11y, and upgrade fixes”; “Automigrate: let fixes describe edits while the runner owns file IO”; “fix(cli): exclude shim from related upgrades”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/fixes/upgrade-storybook-related-dependencies.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/builders/builder-vite/src/vite-config.ts code/builders/builder-vite/src/vite-config.ts:92 — code/builders/builder-vite/src/vite-config.ts changed 7 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 5 (its worst body is vite-config.loadUserViteConfig at line 92), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(builder-vite): print the found Vite config path with forward slashes”; “fix(builder-vite): let viteConfigPath: null disable config loading”; “fix(builder-vite): bound vite config discovery search with getProjectRoot”; “fix(builder-vite): report vite config discovery misses instead of failing silently”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/builders/builder-vite/src/vite-config.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/core/src/common/js-package-manager/NPMProxy.ts code/core/src/common/js-package-manager/NPMProxy.ts:382 — code/core/src/common/js-package-manager/NPMProxy.ts changed 6 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 8 (its worst body is NPMProxy.mapDependencies at line 382), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(core): descend through non-matching nodes when matching npm dependencies”; “Fix Windows-only failures in unit tests”; “fix(cli): install only declared npm workspaces from root”; “fix(cli): install npm workspaces from root”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/common/js-package-manager/NPMProxy.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/core/src/shared/open-service/toolsets/docs/suggest.ts code/core/src/shared/open-service/toolsets/docs/suggest.ts:31 — code/core/src/shared/open-service/toolsets/docs/suggest.ts changed 6 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 9 (its worst body is suggest.suggestEntries at line 31), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(docs-tools): bound the joined word runs of an id”; “fix(docs-tools): rank a multi-word name behind a prefix first”; “fix(docs-tools): print long string-literal unions whole again”; “fix(docs-tools): rank an exact docs id above the component it starts with”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/shared/open-service/toolsets/docs/suggest.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/lib/cli-storybook/src/automigrate/helpers/fix-test-utils.ts code/lib/cli-storybook/src/automigrate/helpers/fix-test-utils.ts:30 — code/lib/cli-storybook/src/automigrate/helpers/fix-test-utils.ts changed 6 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 4 (its worst body is fix-test-utils.runFix at line 30), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “Automigrate: fail fixes that migrate nothing, and keep unresolved summary entries”; “Automigrate: let run decline a fix”; “Automigrate: stop detecting a fix once it is known to apply”; “Automigrate: keep offering fixes whose hooks fail during detection”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/helpers/fix-test-utils.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/addons/pseudo-states/src/preview/rewriteStyleSheet.ts code/addons/pseudo-states/src/preview/rewriteStyleSheet.ts:296 — code/addons/pseudo-states/src/preview/rewriteStyleSheet.ts changed 5 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 11 (its worst body is rewriteStyleSheet.rewriteRuleContainer at line 296), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(pseudo-states): copy rewritten selectors without $ replacement”; “fix(pseudo-states): keep existing .pseudo- selectors in mixed lists”; “fix(pseudo-states): avoid slow WebKit selector matching”; “fix(pseudo-states): split oversized selector rewrites”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/addons/pseudo-states/src/preview/rewriteStyleSheet.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/core/src/common/presets.ts code/core/src/common/presets.ts:78 — code/core/src/common/presets.ts changed 7 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 14 (its worst body is presets.resolveAddonName at line 78), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(core): load presets sequentially to avoid ESM require() race in CJS presets”; “fix: restore Carbon Storybook 11 docs and package resolution”; “fix(core): resolve wrapped addon exports from the addon's own directory”; “fix(core): resolve wrapped addon entries through the package exports map”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/common/presets.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/core/src/cli/skills/content/setup-prompts/partials/steps.ts code/core/src/cli/skills/content/setup-prompts/partials/steps.ts:16 — code/core/src/cli/skills/content/setup-prompts/partials/steps.ts changed 7 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 7 (its worst body is steps.discoveryStepStrict at line 16), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(cli): require the Vitest addon instead of falling back to a build”; “fix(cli): add stories to an existing story file instead of replacing it”; “fix(cli): fix wrong advice in the skills setup instructions”; “fix(cli): preserve React setup guidance and align test types”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/cli/skills/content/setup-prompts/partials/steps.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/frameworks/tanstack-react/src/routing/decorator.tsx code/frameworks/tanstack-react/src/routing/decorator.tsx:185 — code/frameworks/tanstack-react/src/routing/decorator.tsx changed 6 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 10 (its worst body is decorator.resolveTree at line 185), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(tanstack-react): drop defaultErrorComponent and rely on disableGlobalCatchBoundary”; “fix(tanstack-react): surface story render errors to Storybook”; “fix(tanstack-react): support both interpolatePath signatures”; “fix: widen useRouterContext into factory”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/frameworks/tanstack-react/src/routing/decorator.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/lib/cli-storybook/src/automigrate/helpers/failure-report.ts code/lib/cli-storybook/src/automigrate/helpers/failure-report.ts:60 — code/lib/cli-storybook/src/automigrate/helpers/failure-report.ts changed 6 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 3 (its worst body is failure-report.reportFileFailures at line 60), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(cli): handle Windows paths in automigration failure reports”; “Automigrate: keep fix statuses stable across runs and guard inherited frameworks”; “Automigrate: fail fixes that migrate nothing, and keep unresolved summary entries”; “Automigrate: flag fixes whose files were skipped in the per-project log”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/helpers/failure-report.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/core/src/common/js-package-manager/util.ts code/core/src/common/js-package-manager/util.ts:72 — code/core/src/common/js-package-manager/util.ts changed 5 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 9 (its worst body is util.parsePackageTimeMap at line 72), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(core): preapprove chromatic alongside @chromatic-com/storybook”; “fix(cli): harden vitest peer guard and install error tail”; “fix(cli): surface npm stderr on package install failure”; “fix(core): handle npm 12 release-time response”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/core/src/common/js-package-manager/util.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts:15 — code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 2 (its worst body is check at line 15), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “Automigrate: keep fix statuses stable across runs and guard inherited frameworks”; “Automigrate: trim the small fixes to what they use”; “Automigrate: stream file edits of all fixes through one transform pipeline”; “Automigrate: let fixes describe edits while the runner owns file IO”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/fixes/nextjs-to-nextjs-vite.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • Repeated repair: code/lib/cli-storybook/src/automigrate/helpers/edit-parsed-file.ts code/lib/cli-storybook/src/automigrate/helpers/edit-parsed-file.ts:34 — code/lib/cli-storybook/src/automigrate/helpers/edit-parsed-file.ts changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 3 (its worst body is edit-parsed-file.readForEdit at line 34), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(csf-tools): a local exported under two names is shared”; “fix(cli): migrate argtypes-default-value for a file with an alias story”; “fix(csf-tools)!: let reads follow any constant and leave diagnostics to mutations”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-07-28..2026-10-26, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-28 12:31:48 +01:00' --until='2026-10-26 12:31:48 +01:00' --full-history --no-merges -- code/lib/cli-storybook/src/automigrate/helpers/edit-parsed-file.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
  • + 9 more in this group — see findings.md.
X3 · Exception handling · Swallowed exception (empty catch) · ×34
  • Swallowed exception (empty catch) scripts/run-registry.ts:153 — `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
  • Swallowed exception (empty catch) scripts/utils/preapprove-local-packages.ts:39 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) scripts/eval/lib/utils.ts:211 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/renderers/web-components/src/index.ts:31 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/renderers/vue3/src/docgen/story-docs/build-story-docs.ts:154 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/renderers/vue3/src/docgen/component-docgen/component-meta/component-meta.ts:121 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/renderers/vue3/src/docgen/component-docgen/component-meta/component-meta.ts:329 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/renderers/react/src/preset.ts:142 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/renderers/react/src/entry-preview.tsx:95 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/renderers/react/src/componentManifest/getComponentImports.ts:169 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/renderers/react/src/componentManifest/componentMeta/ComponentMetaProject.ts:156 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/eslint-plugin/src/rules/prefer-pascal-case.ts:142 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/eslint-plugin/src/rules/story-exports.ts:73 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/eslint-plugin/scripts/update-lib-flat-configs.ts:74 — `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/initiate.ts:203 — `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/initiate.ts:207 — `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/initiate.ts:222 — `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/initiate.ts:330 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/prompt-cancel.ts:18 — `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/scaffold-new-project.ts:170 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/scaffold-new-project.ts:177 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/services/TelemetryService.ts:102 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/generators/baseGenerator.ts:231 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/generators/REACT_NATIVE_WEB/index.ts:38 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) code/lib/create-storybook/src/commands/FinalizationCommand.ts:85 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • + 9 more in this group — see findings.md.
D3 · God Classes · FileTooLong · ×26
  • FileTooLong: comparison/html-report.ts agent-eval/lib/agentic-reference/comparison/html-report.ts — FileTooLong — 2734 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 2234 over it, 5.47× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: mcp/claude-browser-mock.mjs agent-eval/lib/mcp/claude-browser-mock.mjs — FileTooLong — 1545 significant lines (blank, comment-only and punctuation-only lines excluded; the length bar is tripled for a single-responsibility module of 4 or fewer top-level units). The bar is 500 significant lines; this is 1045 over it, 3.09× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: eval/collect-pr-data.ts scripts/eval/collect-pr-data.ts — FileTooLong — 1218 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 718 over it, 2.44× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: estree/editor.ts code/core/src/csf-tools/estree/editor.ts — FileTooLong — 1199 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 699 over it, 2.40× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: manifests/render-components-manifest.ts code/core/src/core-server/utils/manifests/render-components-manifest.ts — FileTooLong — 1104 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 604 over it, 2.21× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: checklist-store/checklistData.tsx code/core/src/shared/checklist-store/checklistData.tsx — FileTooLong — 1073 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: checklistData (161-1344). The bar is 500 significant lines; this is 573 over it, 2.15× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: componentMeta/componentMetaExtractor.ts code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts — FileTooLong — 1048 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 548 over it, 2.10× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: REDACTED REDACTED — FileTooLong — 924 significant lines (blank, comment-only and punctuation-only lines excluded), about 67% of them inside a single declaration: CsfFile (390-1455). The bar is 500 significant lines; this is 424 over it, 1.85× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: src/server-errors.ts code/core/src/server-errors.ts — FileTooLong — 881 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 381 over it, 1.76× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: tasks/sandbox-parts.ts scripts/tasks/sandbox-parts.ts — FileTooLong — 842 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 342 over it, 1.68× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: lib/templates.ts agent-eval/lib/templates.ts — FileTooLong — 767 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 267 over it, 1.53× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: src/sandbox-templates.ts code/lib/cli-storybook/src/sandbox-templates.ts — FileTooLong — 767 significant lines (blank, comment-only and punctuation-only lines excluded), about 72% of them inside a single declaration: baseTemplates (147-948). The bar is 500 significant lines; this is 267 over it, 1.53× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: transform-template/transform-template.ts code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts — FileTooLong — 698 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 198 over it, 1.40× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: mcp/codex-browser-client-mock.mjs agent-eval/lib/mcp/codex-browser-client-mock.mjs — FileTooLong — 693 significant lines (blank, comment-only and punctuation-only lines excluded; the length bar is tripled for a single-responsibility module of 4 or fewer top-level units). The bar is 500 significant lines; this is 193 over it, 1.39× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: fixes/vitest-setup-file.ts code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts — FileTooLong — 646 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 146 over it, 1.29× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: eval/run-batch.ts scripts/eval/run-batch.ts — FileTooLong — 625 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 125 over it, 1.25× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: estree/scope.ts code/core/src/csf-tools/estree/scope.ts — FileTooLong — 592 significant lines (blank, comment-only and punctuation-only lines excluded), about 74% of them inside a single declaration: analyzeScopes (293-873). The bar is 500 significant lines; this is 92 over it, 1.18× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: utils/StoryIndexGenerator.ts code/core/src/core-server/utils/StoryIndexGenerator.ts — FileTooLong — 565 significant lines (blank, comment-only and punctuation-only lines excluded), about 88% of them inside a single declaration: StoryIndexGenerator (104-925). The bar is 500 significant lines; this is 65 over it, 1.13× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: csf-tools/CsfObjectDiscovery.ts code/core/src/csf-tools/CsfObjectDiscovery.ts — FileTooLong — 563 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 63 over it, 1.13× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: csf-tools/CsfObject.ts code/core/src/csf-tools/CsfObject.ts — FileTooLong — 558 significant lines (blank, comment-only and punctuation-only lines excluded), about 78% of them inside a single declaration: Editor (356-985). The bar is 500 significant lines; this is 58 over it, 1.12× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: sidebar/Tree.tsx code/core/src/manager/components/sidebar/Tree.tsx — FileTooLong — 553 significant lines (blank, comment-only and punctuation-only lines excluded), about 76% of them inside a single declaration: Tree (118-808). The bar is 500 significant lines; this is 53 over it, 1.11× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: js-package-manager/PNPMProxy.ts code/core/src/common/js-package-manager/PNPMProxy.ts — FileTooLong — 535 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: PNPMProxy (68-843). The bar is 500 significant lines; this is 35 over it, 1.07× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: csf-tools/ConfigFile.ts code/core/src/csf-tools/ConfigFile.ts — FileTooLong — 526 significant lines (blank, comment-only and punctuation-only lines excluded), about 63% of them inside a single declaration: ConfigFile (132-1000). The bar is 500 significant lines; this is 26 over it, 1.05× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • FileTooLong: story-shape/resolve-members.ts code/core/src/csf-tools/story-shape/resolve-members.ts — FileTooLong — 522 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 22 over it, 1.04× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: js-package-manager/JsPackageManager.ts code/core/src/common/js-package-manager/JsPackageManager.ts — FileTooLong — 517 significant lines (blank, comment-only and punctuation-only lines excluded), about 88% of them inside a single declaration: JsPackageManager (106-977). The bar is 500 significant lines; this is 17 over it, 1.03× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
  • + 1 more in this group — see findings.md.
R4 · Test Coverage · No test reaches this file · ×26
  • No test reaches this file scripts/snippets/codemod.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file scripts/task.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file agent-eval/scripts/run-plan.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file agent-eval/scripts/analyze-results.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/renderers/react/template/stories/docgen-components/js-proptypes/input.jsx:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file agent-eval/scripts/judge-ds-misuse.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file agent-eval/scripts/eval-gate-thread.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/lib/docgen-harness/src/perf/docgen-memory/generate-project.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/lib/docgen-harness/src/perf/docgen-memory/memory-harness.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file scripts/display-review.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/core/src/shared/open-service/toolset-definition.test-d.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/core/src/shared/open-service/index.test-d.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file scripts/eval/eval.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file agent-eval/scripts/compare-results.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file agent-eval/scripts/check-playground-routes.mjs:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/addons/mcp/scripts/generate-tools-api-doc.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/lib/cli-storybook/src/sandbox.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/lib/docgen-harness/src/perf/docgen-memory/gate.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/core/build-config.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/lib/eslint-plugin/scripts/generate-rule.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/core/scripts/generate-source-files.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file code/renderers/react/template/stories/docgen-components/jsdoc/input.jsx:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file scripts/run-registry.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file agent-eval/scripts/render-results-summary.mjs:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • No test reaches this file scripts/check-package.ts:1 — No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one.
  • + 1 more in this group — see findings.md.
IC1 · Incompleteness & stubs · Fake-async · ×23
  • Fake-async — async method never awaits agent-eval/lib/mcp/codex-browser-client-mock.mjs:824 — `nameSession` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/addons/themes/src/postinstall.ts:16 — `postinstall` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/addons/vitest/src/node/vitest-manager.ts:604 — `setupWatchers` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/builders/builder-vite/src/codegen-set-addon-channel.ts:1 — `generateAddonSetupCode` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/cli/helpers.ts:107 — `cliStoriesTargetPath` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/cli/skills/availability.ts:61 — `isModuleGraphSupported` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/cli/tools/sdk/local-runtime.ts:100 — `startChangeDetectionInProcess` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/components/components/syntaxhighlighter/clipboard.ts:13 — `copyUsingWorkAround` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/core-server/change-detection/change-detection-service.ts:271 — `dispose` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/mocking-utils/mocker-runtime.js:17 — `register` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/mocking-utils/mocker-runtime.js:21 — `delete` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/mocking-utils/mocker-runtime.js:25 — `invalidate` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/preview-api/modules/store/reporter-api.ts:11 — `addReport` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/core/src/preview/preview-navigator.ts:91 — `setupPreviewNavigator` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/frameworks/nextjs-vite/src/preview.tsx:67 — `loaders` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/frameworks/nextjs/src/preview.tsx:64 — `loaders` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/frameworks/sveltekit/src/preview.ts:24 — `beforeEach` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/lib/cli-storybook/src/automigrate/fixes/upgrade-storybook-related-dependencies.ts:107 — `run` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/lib/codemod/src/transforms/find-implicit-spies.ts:69 — `transform` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/lib/docgen-harness/src/web-components/__testfixtures__/stencil-props/stencil-props.tsx:42 — `clear` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/presets/react-webpack/src/loaders/react-docgen-loader.ts:71 — `reactDocgenLoader` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits code/renderers/svelte/src/svelte-csf/compiler/post-transform/create-appendix.ts:28 — `createAppendix` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
  • Fake-async — async method never awaits scripts/get-sandbox-dir.ts:14 — `run` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
D17 · Explicit Debt · FixmeComment · ×21
  • FixmeComment scripts/sandbox/generate.ts:595 — // FIXME: Kill dangling processes. For some reason in CI, — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/renderers/svelte/src/svelte-csf/compiler/post-transform/shared/parameters.ts:94 — // FIXME: This is a dirty workaround. — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/renderers/react/src/extractProps.ts:12 — // FIXME — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/types/modules/addons.ts:157 — // FIXME — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/renderers/react/src/docs/jsxDecorator.tsx:185 — // @ts-expect-error FIXME: workaround react-element-to-jsx-string — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/e2e-sandbox/tags.spec.ts:28 — // FIXME: shows as primary story and also in stories, inconsistent btw dev/CI? — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment REDACTED:303 — // FIXME: we might want to strengthen this locator with an aria-label or testid on the dialog. — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/toolbar/components/ToolbarMenuSelect.tsx:127 — // FIXME: for SB 10 we would want description to become an aria-description, and to add an — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/shared/story-index/autoTitle.ts:8 — // FIXME: types duplicated type from `core-common', to be — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/preview-api/modules/preview-web/index.ts:1 — // FIXME: breaks builder-vite, remove this in 7.0 — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/preview-api/modules/preview-web/render/StoryRender.ts:169 — // FIXME: this comment — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/manager/container/Sidebar.tsx:25 — // FIXME: This is the actual `index.json` index where the `index` below — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/docs-tools/argTypes/docgen/PropDef.ts:1 — // FIXME: this is legacy code that needs to be updated & simplified with ArgType refactor — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/csf-tools/ConfigFile.ts:474 — // FIXME: this is a hack. this is only used in the case where the user is — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/core/src/cli/dirs.ts:27 — // FIXME: this might not be the right version for community packages — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/addons/vitest/src/components/TestProviderRender.tsx:272 — // FIXME: we must clarify why isStarting has any impact here. — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/addons/links/src/react/components/link.tsx:8 — // FIXME: copied from Typography.Link. Code is duplicated to — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/addons/docs/src/blocks.ts:1 — // FIXME: sort this out, maybe with REDACTED exports map — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment code/addons/docs/src/blocks/blocks/SourceContainer.tsx:68 — // FIXME: In SB8.0 when we remove the Source block deprecations, — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment agent-eval/lib/agentic-reference/metrics/tool-taxonomy.test.ts:32 — // ['pnpm run typecheck', ['other']], // FIXME: FLAKY — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment agent-eval/lib/agentic-reference/metrics/tool-taxonomy.test.ts:93 — // ['sudo -n apt-get install -y libnss3', ['other']], // FIXME: FLAKY — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
X2 · Cancellation propagation · Async function without AbortSignal · ×18
  • Async function without AbortSignal: run scripts/event-log-checker.ts:20 — `run` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: uploadToGithub scripts/upload-bench.ts:83 — `uploadToGithub` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: FetchStoryHtmlType code/renderers/server/src/render.ts:13 — `FetchStoryHtmlType` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: manifestProvider code/lib/mcp/bin.ts:65 — `manifestProvider` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: manifestProvider code/lib/mcp/serve.ts:10 — `manifestProvider` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: getStoryIndexFromServer code/core/src/preview-api/modules/preview-web/Preview.tsx:203 — `getStoryIndexFromServer` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: maybeSetupPreviewNavigator code/core/src/preview/preview-navigator.ts:16 — `maybeSetupPreviewNavigator` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: checkRef code/core/src/manager-api/modules/refs.ts:229 — `checkRef` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: updateCheck code/core/src/core-server/utils/update-check.ts:11 — `updateCheck` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: checkRef code/core/src/common/utils/get-storybook-refs.ts:47 — `checkRef` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: resolveUsingBranchInstall code/core/src/cli/dirs.ts:23 — `resolveUsingBranchInstall` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: fetchManifest code/addons/mcp/src/auth/composition-auth.ts:240 — `fetchManifest` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: checkRef code/addons/mcp/src/auth/composition-auth.ts:289 — `checkRef` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: checkMcpAuth code/addons/mcp/src/auth/composition-auth.ts:320 — `checkMcpAuth` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: isMcpUnauthorized code/addons/mcp/src/auth/composition-auth.ts:330 — `isMcpUnauthorized` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: parseAuthFromResponse code/addons/mcp/src/auth/composition-auth.ts:344 — `parseAuthFromResponse` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: resolveDistTagVersion agent-eval/lib/templates.ts:891 — `resolveDistTagVersion` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
  • Async function without AbortSignal: packument agent-eval/lib/checkout-registry-server.mjs:92 — `packument` awaits `fetch(…)` but neither accepts an AbortSignal nor passes one on, so its caller cannot stop the request once it has started. Accept `{ signal }` and pass it through: `fetch(url, { signal })`.
D29 · Static Analysis (SAST) · REDACTED · ×16
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
R4 · Test Coverage · This test file cannot be loaded · ×14
  • This test file cannot be loaded agent-eval/evals/821-upgrade-from-sb9/stories/Button.stories.tsx:2 — agent-eval/evals/821-upgrade-from-sb9/stories/Button.stories.tsx:2 imports '../src/components/Button', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded agent-eval/evals/822-upgrade-from-stable/stories/Button.stories.tsx:2 — agent-eval/evals/822-upgrade-from-stable/stories/Button.stories.tsx:2 imports '../src/components/Button', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded agent-eval/evals/823-setup-outdated-storybook/stories/Button.stories.tsx:2 — agent-eval/evals/823-setup-outdated-storybook/stories/Button.stories.tsx:2 imports '../src/components/Button', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/core/src/csf-tools/__corpus__/inputs/core-interleavedExports.stories.ts:3 — code/core/src/csf-tools/__corpus__/inputs/core-interleavedExports.stories.ts:3 imports './import', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/core/src/csf-tools/__corpus__/inputs/edge-legacy.stories.tsx:3 — code/core/src/csf-tools/__corpus__/inputs/edge-legacy.stories.tsx:3 imports './Button', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/core/src/csf-tools/__corpus__/inputs/react-js-argtypes.stories.jsx:10 — code/core/src/csf-tools/__corpus__/inputs/react-js-argtypes.stories.jsx:10 imports './docgen-components/9586-js-react-memo/input.jsx', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either (3 further unresolvable import(s) in the same file). The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/core/src/csf-tools/__corpus__/inputs/react-test-fn.stories.tsx:7 — code/core/src/csf-tools/__corpus__/inputs/react-test-fn.stories.tsx:7 imports './preview', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/core/src/csf-tools/__corpus__/inputs/shapes-angular-button.stories.ts:5 — code/core/src/csf-tools/__corpus__/inputs/shapes-angular-button.stories.ts:5 imports './templates.ts', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/lib/docgen-harness/src/svelte/server-metadata.test.ts:18 — code/lib/docgen-harness/src/svelte/server-metadata.test.ts:18 imports './story-docs/__fixtures__/legacy-metadata/', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/renderers/svelte/src/docgen/component-docgen/__testfixtures__/subcomponents/plain.stories.ts:3 — code/renderers/svelte/src/docgen/component-docgen/__testfixtures__/subcomponents/plain.stories.ts:3 imports './Missing.svelte', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/renderers/svelte/src/docgen/component-docgen/__testfixtures__/unresolved/missing.stories.ts:1 — code/renderers/svelte/src/docgen/component-docgen/__testfixtures__/unresolved/missing.stories.ts:1 imports './Missing.svelte', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded code/renderers/vue3/src/docgen/component-docgen/__testfixtures__/MissingImportComponent.stories.ts:1 — code/renderers/vue3/src/docgen/component-docgen/__testfixtures__/MissingImportComponent.stories.ts:1 imports './DoesNotExist.vue', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded test-storybooks/ember-cli/app/app.js:4 — test-storybooks/ember-cli/app/app.js:4 imports './config/environment', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
  • This test file cannot be loaded test-storybooks/ember-cli/app/router.js:3 — test-storybooks/ember-cli/app/router.js:3 imports './config/environment', which names no file in this repository — and no rule in its .gitignore chain could cover one, so no build writes it either. The import throws as the runner collects this file, so none of its test cases run and nothing it was written to verify is verified. Restore the missing module or delete the test. It is excluded from the reachability measured above, because a file that cannot load reaches nothing.
P7 · Outbound HTTP resilience · Outbound HTTP without resilience · ×13
  • Outbound HTTP without resilience code/core/src/cli/dirs.ts:38 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience code/core/src/common/utils/get-storybook-refs.ts:49 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience code/core/src/common/utils/get-storybook-refs.ts:55 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience code/core/src/core-server/utils/update-check.ts:20 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience code/core/src/core-server/utils/whats-new.ts:45 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience code/core/src/manager-api/modules/refs.ts:261 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience code/core/src/manager-api/modules/refs.ts:277 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience code/core/src/preview/preview-navigator.ts:27 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience code/core/src/shared/open-service/static-fetch.ts:48 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience scripts/event-log-checker.ts:49 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience scripts/release/utils/get-github-info.ts:114 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience scripts/upload-bench.ts:99 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
  • Outbound HTTP without resilience scripts/utils/githubClient.ts:5 — `fetch(` makes an outbound HTTP call, and nothing bounds it: no timeout, deadline, retry or circuit breaker is set for it here, and the client has no process-wide default. A slow or failing dependency will hold this service's request, thread or connection until the call gives up on its own — or never, for a client with no default timeout.
X17 · Uncapped recursion over a caller-supplied document · Recursive walk over a caller-supplied document has no depth cap · ×13
  • Recursive walk over a caller-supplied document has no depth cap code/lib/docgen-harness/src/sandbox-baselines/stable-stringify.ts:6 — `stableStringify` is exported, takes a document from its caller (line 3) and hands it to `sortKeys`, which calls itself at line 6 (`sortKeys`) with a piece of `input` (and at line 12) — and nowhere in `sortKeys` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `sortKeys` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/lib/docgen-harness/src/compare/deep-equal.ts:13 — `deepEqual` is exported and takes `a: unknown` from its caller, and it calls itself at line 13 (`deepEqual`) with a piece of `a` (and at line 30) — and nowhere in `deepEqual` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `deepEqual` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/frameworks/tanstack-react/src/plugins/incompatible-plugins.ts:3 — `isTanStackStartPlugin` is exported, takes a document from its caller (line 15) and hands it to `matchesPluginName`, which calls itself at line 3 (`matchesPluginName`) with a piece of `p` — and nowhere in `matchesPluginName` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `matchesPluginName` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/frameworks/angular-vite/src/template-grammar.ts:37 — `formatInputValue` is exported, takes a document from its caller (line 50) and hands it to `formatJsonValue`, which calls itself at line 37 (`formatJsonValue`) with a piece of `value` (and at line 42) — and nowhere in `formatJsonValue` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `formatJsonValue` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/frameworks/angular/src/server/framework-preset-angular-cli.ts:108 — `deepMerge` is exported and takes `target: JsonObject` from its caller, and it calls itself at line 108 (`deepMerge`) with a piece of `target` — and nowhere in `deepMerge` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `deepMerge` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/core/src/shared/open-service/service-error-serialization.ts:53 — `serializeError` is exported, takes a document from its caller (line 86) and hands it to `toTransportSafe`, which calls itself at line 53 (`toTransportSafe`) with a piece of `value` (and at line 59) — and nowhere in `toTransportSafe` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `toTransportSafe` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/core/src/shared/open-service/service-sync.ts:163 — `applyStatePatch` is exported, takes a document from its caller (line 137) and hands it to `mergeInto`, which calls itself at line 163 (`mergeInto`) with a piece of `target` — and nowhere in `mergeInto` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `mergeInto` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/core/src/shared/open-service/services/module-graph/types.ts:62 — `errorToErrorLike` is exported and takes `error: unknown` from its caller, and it calls itself at line 62 (`errorToErrorLike`) with a piece of `error` — and nowhere in `errorToErrorLike` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `errorToErrorLike` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/core/src/router/utils.ts:57 — `deepDiff` is exported and takes `value: any` from its caller, and it calls itself at line 57 (`deepDiff`) with a piece of `value` (and at line 72) — and nowhere in `deepDiff` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `deepDiff` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/core/src/preview-api/modules/store/args.ts:91 — `combineArgs` is exported and takes `value: any` from its caller, and it calls itself at line 91 (`combineArgs`) with a piece of `value` (and at line 104) — and nowhere in `combineArgs` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `combineArgs` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/core/src/preview-api/modules/store/args.ts:180 — `deepDiff` is exported and takes `value: any` from its caller, and it calls itself at line 180 (`deepDiff`) with a piece of `value` (and at line 195) — and nowhere in `deepDiff` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `deepDiff` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/core/src/csf-tools/estree/editor.ts:605 — `printValue` is exported and takes `value: unknown` from its caller, and it calls itself at line 605 (`printValue`) with a piece of `value` (and at line 612) — and nowhere in `printValue` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `printValue` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
  • Recursive walk over a caller-supplied document has no depth cap code/core/src/csf-tools/estree/values.ts:106 — `nodeWithoutParse` is exported and takes `value: unknown` from its caller, and it calls itself at line 106 (`nodeWithoutParse`) with a piece of `value` — and nowhere in `nodeWithoutParse` is there a depth parameter, a descent counter, or any other cap. The walk therefore spends one stack frame per LEVEL of the value it is handed, so the nesting of the caller's document — not this code — decides how deep the stack goes. JavaScript sets no limit of its own on that nesting: `JSON.parse` accepts any depth, so a 100,000-byte body — inside Express's default 100kb limit — parses to 50,000 levels, and a walk like this one throws `RangeError: Maximum call stack size exceeded` long before it reaches the bottom. Wherever that throw lands, the work fails: a request errors, and a walk running outside any `try` — an event handler, a timer, a promise nobody awaits — takes the Node process down with every other request in flight. Thread a depth argument through `nodeWithoutParse` and reject the value past a fixed maximum, or rewrite the descent with an explicit stack.
D23 · Boundary Type-Coupling · Cross-context type ProjectType (core → create-storybook) · ×12
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/services/TelemetryService.ts:59 — ProjectType (context core) is exposed in create-storybook's public surface via TelemetryService.trackInit — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/services/TelemetryService.ts:88 — ProjectType (context core) is exposed in create-storybook's public surface via TelemetryService.trackInitWithContext — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:75 — ProjectType (context core) is exposed in create-storybook's public surface via GeneratorMetadata.projectType — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/services/FeatureCompatibilityService.ts:29 — ProjectType (context core) is exposed in create-storybook's public surface via FeatureCompatibilityService.supportsOnboarding — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/services/ProjectTypeService.ts:157 — ProjectType (context core) is exposed in create-storybook's public surface via ProjectTypeService.validateProvidedType — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/services/ProjectTypeService.ts:171 — ProjectType (context core) is exposed in create-storybook's public surface via ProjectTypeService.autoDetectProjectType — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/commands/ProjectDetectionCommand.ts:34 — ProjectType (context core) is exposed in create-storybook's public surface via ProjectDetectionCommand.execute — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/generators/GeneratorRegistry.ts:28 — ProjectType (context core) is exposed in create-storybook's public surface via GeneratorRegistry.get — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/commands/FrameworkDetectionCommand.ts:31 — ProjectType (context core) is exposed in create-storybook's public surface via FrameworkDetectionCommand.execute — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/commands/FrameworkDetectionCommand.ts:90 — ProjectType (context core) is exposed in create-storybook's public surface via FrameworkDetectionCommand.executeFrameworkDetection — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/commands/UserPreferencesCommand.ts:37 — ProjectType (context core) is exposed in create-storybook's public surface via UserPreferencesOptions.projectType — couples the contexts.
  • Cross-context type ProjectType (core → create-storybook) code/lib/create-storybook/src/initiate.ts:74 — ProjectType (context core) is exposed in create-storybook's public surface via initiate.doInitiate — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type SupportedBuilder (core → create-storybook) · ×11
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:32 — SupportedBuilder (context core) is exposed in create-storybook's public surface via FrameworkOptions.extraPackages — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:37 — SupportedBuilder (context core) is exposed in create-storybook's public surface via FrameworkOptions.webpackCompiler — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:82 — SupportedBuilder (context core) is exposed in create-storybook's public surface via GeneratorMetadata.framework — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:90 — SupportedBuilder (context core) is exposed in create-storybook's public surface via GeneratorMetadata.builderOverride — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:101 — SupportedBuilder (context core) is exposed in create-storybook's public surface via GeneratorContext.builder — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/services/FeatureCompatibilityService.ts:44 — SupportedBuilder (context core) is exposed in create-storybook's public surface via FeatureCompatibilityService.validateTestFeatureCompatibility — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/services/AddonService.ts:13 — SupportedBuilder (context core) is exposed in create-storybook's public surface via AddonService.getWebpackCompilerAddon — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/services/AddonService.ts:55 — SupportedBuilder (context core) is exposed in create-storybook's public surface via AddonService.configureAddons — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/services/FrameworkDetectionService.ts:22 — SupportedBuilder (context core) is exposed in create-storybook's public surface via FrameworkDetectionService.detectFramework — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/commands/FrameworkDetectionCommand.ts:15 — SupportedBuilder (context core) is exposed in create-storybook's public surface via FrameworkDetectionResult.builder — couples the contexts.
  • Cross-context type SupportedBuilder (core → create-storybook) code/lib/create-storybook/src/commands/UserPreferencesCommand.ts:35 — SupportedBuilder (context core) is exposed in create-storybook's public surface via UserPreferencesOptions.builder — couples the contexts.
D29 · Static Analysis (SAST) · REDACTED · ×8
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
AC2 · Forms & labels · <Select> field component without a label · ×7
  • <Select> field component without a label code/addons/a11y/src/components/VisionSimulator.tsx:52 — This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
  • <Select> field component without a label code/addons/pseudo-states/src/manager/PseudoStateTool.tsx:28 — This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
  • <Select> field component without a label code/addons/themes/src/theme-switcher.tsx:94 — This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
  • <Select> field component without a label code/core/src/backgrounds/components/Tool.tsx:101 — This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
  • <Select> field component without a label code/core/src/manager/components/review/components/ReviewCollectionPicker.tsx:71 — This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
  • <Select> field component without a label code/core/src/toolbar/components/ToolbarMenuSelect.tsx:132 — This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
  • <Select> field component without a label code/core/src/viewport/components/Tool.tsx:68 — This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
D12 · Dependency Hygiene · Deprecated · ×7
  • Deprecated: @types/prettier REDACTED:331 — @types/prettier 3.0.0, declared in REDACTED, is marked deprecated by its publisher: "This is a stub types definition. prettier provides its own type definitions, so you do not need this installed.". Replace it with the package or version that message names, or record why this one must stay.
  • Deprecated: npmlog REDACTED:389 — npmlog 7.0.1, declared in REDACTED, is marked deprecated by its publisher: "This package is no longer supported.". Replace it with the package or version that message names, or record why this one must stay.
  • Deprecated: @angular/animations code/frameworks/angular/package.json:74 — @angular/animations 21.2.22, declared in code/frameworks/angular/package.json, is marked deprecated by its publisher: "@angular/animations is deprecated. Use `animate.enter` and `animate.leave` instead. For more information see: https://v22.angular.dev/guide/animations.". Replace it with the package or version that message names, or record why this one must stay.
  • Deprecated: next code/frameworks/nextjs-vite/package.json:100 — next 15.5.6, declared in code/frameworks/nextjs-vite/package.json, is marked deprecated by its publisher: "This version has a security vulnerability. Please upgrade to a patched version. See https://nextjs.org/blog/[CVE redacted] for more details.". Replace it with the package or version that message names, or record why this one must stay.
  • Deprecated: next code/frameworks/nextjs/package.json:138 — next 15.5.6, declared in code/frameworks/nextjs/package.json, is marked deprecated by its publisher: "This version has a security vulnerability. Please upgrade to a patched version. See https://nextjs.org/blog/[CVE redacted] for more details.". Replace it with the package or version that message names, or record why this one must stay.
  • Deprecated: eslint code/lib/eslint-plugin/package.json:57 — eslint 8.57.1, declared in code/lib/eslint-plugin/package.json, is marked deprecated by its publisher: "This version is no longer supported. Please see https://eslint.org/version-support for other options.". Replace it with the package or version that message names, or record why this one must stay.
  • Deprecated: next code/lib/vite-plugin-storybook-nextjs/package.json:87 — next 15.5.6, declared in code/lib/vite-plugin-storybook-nextjs/package.json, is marked deprecated by its publisher: "This version has a security vulnerability. Please upgrade to a patched version. See https://nextjs.org/blog/[CVE redacted] for more details.". Replace it with the package or version that message names, or record why this one must stay.
D17 · Explicit Debt · HackComment · ×7
  • HackComment test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:581 — // HACK: the testing module popover has poor tracking of focus due to how many disabled — a workaround marked in source: record what it is compensating for and what would allow its removal (the upstream fix, the API it is waiting on, the invariant it restores), so the next reader can judge whether it is still needed rather than rediscovering why it is there.
  • HackComment test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:650 — // HACK: the testing module popover has poor tracking of focus due to how many disabled — a workaround marked in source: record what it is compensating for and what would allow its removal (the upstream fix, the API it is waiting on, the invariant it restores), so the next reader can judge whether it is still needed rather than rediscovering why it is there.
  • HackComment test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:708 — // HACK: the testing module popover has poor tracking of focus due to how many disabled — a workaround marked in source: record what it is compensating for and what would allow its removal (the upstream fix, the API it is waiting on, the invariant it restores), so the next reader can judge whether it is still needed rather than rediscovering why it is there.
  • HackComment test-storybooks/portable-stories-kitchen-sink/react/e2e-tests/component-testing.spec.ts:775 — // HACK: the testing module popover has poor tracking of focus due to how many disabled — a workaround marked in source: record what it is compensating for and what would allow its removal (the upstream fix, the API it is waiting on, the invariant it restores), so the next reader can judge whether it is still needed rather than rediscovering why it is there.
  • HackComment code/core/src/manager-api/tests/stories.test.ts:617 — // HACK api to effectively mock getCurrentParameter — a workaround marked in source: record what it is compensating for and what would allow its removal (the upstream fix, the API it is waiting on, the invariant it restores), so the next reader can judge whether it is still needed rather than rediscovering why it is there.
  • HackComment code/addons/docs/src/blocks/blocks/mdx.tsx:18 — // Hacky utility for asserting identifiers in MDX Story elements — a workaround marked in source: record what it is compensating for and what would allow its removal (the upstream fix, the API it is waiting on, the invariant it restores), so the next reader can judge whether it is still needed rather than rediscovering why it is there.
  • HackComment code/addons/docs/src/blocks/blocks/mdx.tsx:26 — // Hacky utility for adding mdxStoryToId to the default context — a workaround marked in source: record what it is compensating for and what would allow its removal (the upstream fix, the API it is waiting on, the invariant it restores), so the next reader can judge whether it is still needed rather than rediscovering why it is there.
D29 · Static Analysis (SAST) · REDACTED · ×7
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D3 · God Classes · MethodTooLong · ×7
  • MethodTooLong: StoryRender.render code/core/src/preview-api/modules/preview-web/render/StoryRender.ts:185 — MethodTooLong — render runs 164 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 64 over it, 1.64× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: CsfFile._visitExportNamed REDACTED:891 — MethodTooLong — _visitExportNamed runs 134 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 34 over it, 1.34× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Editor.groupValues code/core/src/csf-tools/CsfObject.ts:692 — MethodTooLong — groupValues runs 134 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 34 over it, 1.34× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Instrumenter.constructor code/core/src/instrumenter/instrumenter.ts:103 — MethodTooLong — constructor runs 128 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 28 over it, 1.28× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: PreviewWithSelection.renderSelection code/core/src/preview-api/modules/preview-web/PreviewWithSelection.tsx:304 — MethodTooLong — renderSelection runs 124 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 24 over it, 1.24× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: ConfigFile.parse code/core/src/csf-tools/ConfigFile.ts:538 — MethodTooLong — parse runs 109 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 9 over it, 1.09× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: Instrumenter.invoke code/core/src/instrumenter/instrumenter.ts:491 — MethodTooLong — invoke runs 106 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 6 over it, 1.06× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
D23 · Boundary Type-Coupling · Cross-context type Type (svelte → angular-vite) · ×6
  • Cross-context type Type (svelte → angular-vite) code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts:160 — Type (context svelte) is exposed in angular-vite's public surface via NgComponentAnalyzer.isComponent — couples the contexts.
  • Cross-context type Type (svelte → angular-vite) code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts:170 — Type (context svelte) is exposed in angular-vite's public surface via NgComponentAnalyzer.isStandaloneComponent — couples the contexts.
  • Cross-context type Type (svelte → angular-vite) code/frameworks/angular-vite/src/client/renderer/ComputesTemplateFromComponent.ts:29 — Type (context svelte) is exposed in angular-vite's public surface via ComputesTemplateFromComponent.computesTemplateFromComponent — couples the contexts.
  • Cross-context type Type (svelte → angular-vite) code/frameworks/angular-vite/src/client/renderer/ComputesTemplateFromComponent.ts:59 — Type (context svelte) is exposed in angular-vite's public surface via ComputesTemplateFromComponent.computesTemplateSourceFromComponent — couples the contexts.
  • Cross-context type Type (svelte → angular-vite) code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts:33 — Type (context svelte) is exposed in angular-vite's public surface via StorybookWrapperComponent.createStorybookWrapperComponent — couples the contexts.
  • Cross-context type Type (svelte → angular-vite) code/frameworks/angular-vite/src/client/decorators.ts:63 — Type (context svelte) is exposed in angular-vite's public surface via decorators.componentWrapperDecorator — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type Type (svelte → angular) · ×6
  • Cross-context type Type (svelte → angular) code/frameworks/angular/src/client/angular-beta/utils/NgComponentAnalyzer.ts:160 — Type (context svelte) is exposed in angular's public surface via NgComponentAnalyzer.isComponent — couples the contexts.
  • Cross-context type Type (svelte → angular) code/frameworks/angular/src/client/angular-beta/utils/NgComponentAnalyzer.ts:170 — Type (context svelte) is exposed in angular's public surface via NgComponentAnalyzer.isStandaloneComponent — couples the contexts.
  • Cross-context type Type (svelte → angular) code/frameworks/angular/src/client/angular-beta/ComputesTemplateFromComponent.ts:50 — Type (context svelte) is exposed in angular's public surface via ComputesTemplateFromComponent.computesTemplateFromComponent — couples the contexts.
  • Cross-context type Type (svelte → angular) code/frameworks/angular/src/client/angular-beta/ComputesTemplateFromComponent.ts:142 — Type (context svelte) is exposed in angular's public surface via ComputesTemplateFromComponent.computesTemplateSourceFromComponent — couples the contexts.
  • Cross-context type Type (svelte → angular) code/frameworks/angular/src/client/angular-beta/StorybookWrapperComponent.ts:33 — Type (context svelte) is exposed in angular's public surface via StorybookWrapperComponent.createStorybookWrapperComponent — couples the contexts.
  • Cross-context type Type (svelte → angular) code/frameworks/angular/src/client/decorators.ts:63 — Type (context svelte) is exposed in angular's public surface via decorators.componentWrapperDecorator — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type SupportedFramework (core → create-storybook) · ×6
  • Cross-context type SupportedFramework (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:82 — SupportedFramework (context core) is exposed in create-storybook's public surface via GeneratorMetadata.framework — couples the contexts.
  • Cross-context type SupportedFramework (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:99 — SupportedFramework (context core) is exposed in create-storybook's public surface via GeneratorContext.framework — couples the contexts.
  • Cross-context type SupportedFramework (core → create-storybook) code/lib/create-storybook/src/services/FeatureCompatibilityService.ts:44 — SupportedFramework (context core) is exposed in create-storybook's public surface via FeatureCompatibilityService.validateTestFeatureCompatibility — couples the contexts.
  • Cross-context type SupportedFramework (core → create-storybook) code/lib/create-storybook/src/services/FrameworkDetectionService.ts:22 — SupportedFramework (context core) is exposed in create-storybook's public surface via FrameworkDetectionService.detectFramework — couples the contexts.
  • Cross-context type SupportedFramework (core → create-storybook) code/lib/create-storybook/src/commands/FrameworkDetectionCommand.ts:16 — SupportedFramework (context core) is exposed in create-storybook's public surface via FrameworkDetectionResult.framework — couples the contexts.
  • Cross-context type SupportedFramework (core → create-storybook) code/lib/create-storybook/src/commands/UserPreferencesCommand.ts:34 — SupportedFramework (context core) is exposed in create-storybook's public surface via UserPreferencesOptions.framework — couples the contexts.
D5 · Coupling · Off the main sequence · ×6
  • Off the main sequence: eslint-plugin-storybook — eslint-plugin-storybook: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 1 project(s), so it's rigid to change.
  • Off the main sequence: @storybook/builder-vite — @storybook/builder-vite: abstractness 0.00, instability 0.07, distance 0.93 — zone of pain — concrete and depended on by 13 project(s), so it's rigid to change.
  • Off the main sequence: @storybook/core-webpack — @storybook/core-webpack: abstractness 0.00, instability 0.14, distance 0.86 — zone of pain — concrete and depended on by 6 project(s), so it's rigid to change.
  • Off the main sequence: storybook — storybook: abstractness 0.14, instability 0.02, distance 0.84 — zone of pain — concrete and depended on by 47 project(s), so it's rigid to change.
  • Off the main sequence: @storybook/react — @storybook/react: abstractness 0.14, instability 0.11, distance 0.74 — zone of pain — concrete and depended on by 8 project(s), so it's rigid to change.
  • Off the main sequence: @storybook/svelte — @storybook/svelte: abstractness 0.04, instability 0.25, distance 0.71 — zone of pain — concrete and depended on by 3 project(s), so it's rigid to change.
X3 · Exception handling · Swallowed exception (caught, then discarded) · ×6
  • Swallowed exception (caught, then discarded) code/renderers/svelte/src/docgen/component-docgen/build-docgen.ts:59 — `catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts:209 — `catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) code/renderers/react/src/componentManifest/componentMeta/ComponentMetaProject.ts:281 — `catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) code/lib/cli-storybook/src/automigrate/index.ts:423 — `catch (err)` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:131 — `catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
  • Swallowed exception (caught, then discarded) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:159 — `catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
AC6 · Visual & motion safety · Low contrast colour pair in CSS (2.6 · ×5
  • Low contrast colour pair in CSS (2.6:1) test-storybooks/portable-stories-kitchen-sink/vue3/stories/button.css:10 — `.storybook-button--primary` sets color: white on background-color: #1ea7fd — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.6:1) test-storybooks/portable-stories-kitchen-sink/svelte/stories/button.css:10 — `.storybook-button--primary` sets color: white on background-color: #1ea7fd — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.6:1) test-storybooks/portable-stories-kitchen-sink/react/stories/button.css:10 — `.storybook-button--primary` sets color: white on background-color: #1ea7fd — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.6:1) test-storybooks/mcp/stories/components/button.css:13 — `.storybook-button--primary` sets color: white on background-color: #1ea7fd — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
  • Low contrast colour pair in CSS (2.6:1) code/addons/pseudo-states/src/stories/nested.css:1 — `button` sets color: white on background-color: #1ea7fd — 2.6:1, below the 4.5:1 WCAG AA minimum for normal text. Darken or lighten one of them.
D23 · Boundary Type-Coupling · Cross-context type Feature (core → create-storybook) · ×5
  • Cross-context type Feature (core → create-storybook) code/lib/create-storybook/src/services/TelemetryService.ts:88 — Feature (context core) is exposed in create-storybook's public surface via TelemetryService.trackInitWithContext — couples the contexts.
  • Cross-context type Feature (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:105 — Feature (context core) is exposed in create-storybook's public surface via GeneratorContext.features — couples the contexts.
  • Cross-context type Feature (core → create-storybook) code/lib/create-storybook/src/services/AddonService.ts:26 — Feature (context core) is exposed in create-storybook's public surface via AddonService.getAddonsForFeatures — couples the contexts.
  • Cross-context type Feature (core → create-storybook) code/lib/create-storybook/src/services/AddonService.ts:55 — Feature (context core) is exposed in create-storybook's public surface via AddonService.configureAddons — couples the contexts.
  • Cross-context type Feature (core → create-storybook) code/lib/create-storybook/src/commands/UserPreferencesCommand.ts:29 — Feature (context core) is exposed in create-storybook's public surface via UserPreferencesResult.selectedFeatures — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type SupportedRenderer (core → create-storybook) · ×5
  • Cross-context type SupportedRenderer (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:76 — SupportedRenderer (context core) is exposed in create-storybook's public surface via GeneratorMetadata.renderer — couples the contexts.
  • Cross-context type SupportedRenderer (core → create-storybook) code/lib/create-storybook/src/generators/types.ts:100 — SupportedRenderer (context core) is exposed in create-storybook's public surface via GeneratorContext.renderer — couples the contexts.
  • Cross-context type SupportedRenderer (core → create-storybook) code/lib/create-storybook/src/services/FrameworkDetectionService.ts:22 — SupportedRenderer (context core) is exposed in create-storybook's public surface via FrameworkDetectionService.detectFramework — couples the contexts.
  • Cross-context type SupportedRenderer (core → create-storybook) code/lib/create-storybook/src/commands/FrameworkDetectionCommand.ts:14 — SupportedRenderer (context core) is exposed in create-storybook's public surface via FrameworkDetectionResult.renderer — couples the contexts.
  • Cross-context type SupportedRenderer (core → create-storybook) code/lib/create-storybook/src/commands/UserPreferencesCommand.ts:36 — SupportedRenderer (context core) is exposed in create-storybook's public surface via UserPreferencesOptions.renderer — couples the contexts.
D3 · God Classes · ClassTooLong · ×5
  • ClassTooLong: checklistData code/core/src/shared/checklist-store/checklistData.tsx:1 — ClassTooLong — 975 significant lines (blank, comment-only and punctuation-only lines excluded), 4 methods. The bar is 400 significant lines; this is 575 over it, 2.44× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: PNPMProxy code/core/src/common/js-package-manager/PNPMProxy.ts:68 — ClassTooLong — 488 significant lines (blank, comment-only and punctuation-only lines excluded), 39 methods. The bar is 400 significant lines; this is 88 over it, 1.22× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: Editor code/core/src/csf-tools/CsfObject.ts:356 — ClassTooLong — 436 significant lines (blank, comment-only and punctuation-only lines excluded), 29 methods. The bar is 400 significant lines; this is 36 over it, 1.09× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: Tree code/core/src/manager/components/sidebar/Tree.tsx:1 — ClassTooLong — 423 significant lines (blank, comment-only and punctuation-only lines excluded), 2 methods. The bar is 400 significant lines; this is 23 over it, 1.06× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • ClassTooLong: Instrumenter code/core/src/instrumenter/instrumenter.ts:94 — ClassTooLong — 405 significant lines (blank, comment-only and punctuation-only lines excluded), 13 methods. The bar is 400 significant lines; this is 5 over it, 1.01× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
IC1 · Incompleteness & stubs · Hollow method · ×5
  • Hollow method — returns a constant without doing the work scripts/tasks/bench.ts:13 — `ready` looks like it should compute a result but its body just returns a constant — a placeholder return that was never filled in.
  • Hollow method — returns a constant without doing the work scripts/tasks/check-sandbox.ts:8 — `ready` looks like it should compute a result but its body just returns a constant — a placeholder return that was never filled in.
  • Hollow method — returns a constant without doing the work scripts/tasks/check.ts:45 — `ready` looks like it should compute a result but its body just returns a constant — a placeholder return that was never filled in.
  • Hollow method — returns a constant without doing the work scripts/tasks/chromatic.ts:9 — `ready` looks like it should compute a result but its body just returns a constant — a placeholder return that was never filled in.
  • Hollow method — returns a constant without doing the work scripts/tasks/sync-docs.ts:22 — `ready` looks like it should compute a result but its body just returns a constant — a placeholder return that was never filled in.
D23 · Boundary Type-Coupling · Cross-context type Type (svelte → angular-cm) · ×4
  • Cross-context type Type (svelte → angular-cm) code/lib/angular-cm/src/analyzer/type-index.ts:107 — Type (context svelte) is exposed in angular-cm's public surface via TypeIndex.renderCheckerType — couples the contexts.
  • Cross-context type Type (svelte → angular-cm) code/lib/angular-cm/src/analyzer/type-index.ts:115 — Type (context svelte) is exposed in angular-cm's public surface via TypeIndex.renderValueType — couples the contexts.
  • Cross-context type Type (svelte → angular-cm) code/lib/angular-cm/src/analyzer/type-index.ts:200 — Type (context svelte) is exposed in angular-cm's public surface via TypeIndex.addFromType — couples the contexts.
  • Cross-context type Type (svelte → angular-cm) code/lib/angular-cm/src/analyzer/signals.ts:156 — Type (context svelte) is exposed in angular-cm's public surface via signals.signalValueTypeFromType — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type Parsed (cli-storybook → docgen-harness) · ×4
  • Cross-context type Parsed (cli-storybook → docgen-harness) code/lib/docgen-harness/src/compare/types.ts:26 — Parsed (context cli-storybook) is exposed in docgen-harness's public surface via SnippetGrammar.parse — couples the contexts.
  • Cross-context type Parsed (cli-storybook → docgen-harness) code/lib/docgen-harness/src/compare/types.ts:27 — Parsed (context cli-storybook) is exposed in docgen-harness's public surface via SnippetGrammar.representedNames — couples the contexts.
  • Cross-context type Parsed (cli-storybook → docgen-harness) code/lib/docgen-harness/src/compare/types.ts:29 — Parsed (context cli-storybook) is exposed in docgen-harness's public surface via SnippetGrammar.assertGatable — couples the contexts.
  • Cross-context type Parsed (cli-storybook → docgen-harness) code/lib/docgen-harness/src/compare/types.ts:31 — Parsed (context cli-storybook) is exposed in docgen-harness's public surface via SnippetGrammar.compareStructure — couples the contexts.
AC3 · Page structure · Page without a main landmark · ×3
  • Page without a main landmark code/addons/mcp/src/template.html:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark code/builders/builder-webpack5/templates/preview.ejs:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
  • Page without a main landmark code/core/assets/server/template.ejs:2 — No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
D23 · Boundary Type-Coupling · Cross-context type IndexEntry (core → react) · ×3
  • Cross-context type IndexEntry (core → react) code/renderers/react/src/componentManifest/buildReactComponentDocgen.ts:228 — IndexEntry (context core) is exposed in react's public surface via buildReactComponentDocgen.buildStoryDocsFromResolved — couples the contexts.
  • Cross-context type IndexEntry (core → react) code/renderers/react/src/componentManifest/buildReactComponentDocgen.ts:302 — IndexEntry (context core) is exposed in react's public surface via buildReactComponentDocgen.buildComponentDocgenFromResolved — couples the contexts.
  • Cross-context type IndexEntry (core → react) code/renderers/react/src/componentManifest/buildReactComponentDocgen.ts:404 — IndexEntry (context core) is exposed in react's public surface via buildReactComponentDocgen.buildReactComponentDocgenFromResolved — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type TemplateKey (cli-storybook → scripts) · ×3
  • Cross-context type TemplateKey (cli-storybook → scripts) scripts/ci/focus.ts:68 — TemplateKey (context cli-storybook) is exposed in scripts's public surface via focus.templateDirs — couples the contexts.
  • Cross-context type TemplateKey (cli-storybook → scripts) scripts/ci/focus.ts:90 — TemplateKey (context cli-storybook) is exposed in scripts's public surface via focus.selectFocusSandboxes — couples the contexts.
  • Cross-context type TemplateKey (cli-storybook → scripts) scripts/ci/focus.ts:113 — TemplateKey (context cli-storybook) is exposed in scripts's public surface via focus.selectChromaticSiblings — couples the contexts.
D29 · Static Analysis (SAST) · REDACTED · ×3
  • REDACTED
  • REDACTED
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×3
  • REDACTED
  • REDACTED
  • REDACTED
D3 · God Classes · TooManyMethods · ×3
  • TooManyMethods: JsPackageManager code/core/src/common/js-package-manager/JsPackageManager.ts:106 — TooManyMethods — 50 methods. The bar is 30 methods; this is 20 over it, 1.67× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: PNPMProxy code/core/src/common/js-package-manager/PNPMProxy.ts:68 — TooManyMethods — 39 methods. The bar is 30 methods; this is 9 over it, 1.30× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: ConfigFile code/core/src/csf-tools/ConfigFile.ts:132 — TooManyMethods — 38 methods. The bar is 30 methods; this is 8 over it, 1.27× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
R7 · Dead Code · Dead file (~66 LoC) · ×3
  • Dead file (~66 LoC) code/frameworks/angular-vite/src/client/public-types.test-d.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
  • Dead file (~66 LoC) code/frameworks/angular/src/client/public-types.test-d.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
  • Dead file (~66 LoC) scripts/reset.js — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
X1 · Async correctness · `async` callback passed to `forEach` · ×3
  • `async` callback passed to `forEach` scripts/build-package.ts:172 — `forEach` ignores what its callback returns, so the Promise each `async` call returns is dropped: nothing can await it, the code after this loop runs before any of the awaited work has finished (a function that `await`s around this loop still returns early), and a rejection is never handled — in Node.js an unhandled rejection terminates the process by default, and in a browser it is lost. Iterate with `for (const item of items) { await … }` when the work must run in order, or `await Promise.all(items.map(async (item) => { … }))` when it may run concurrently, so the enclosing function finishes only when the work does and its failures reach the caller. Where firing and forgetting is genuinely intended, make the callback's whole body a `try { … } catch (e) { … }` that handles the failure, so it cannot escape.
  • `async` callback passed to `forEach` scripts/check-package.ts:192 — `forEach` ignores what its callback returns, so the Promise each `async` call returns is dropped: nothing can await it, the code after this loop runs before any of the awaited work has finished (a function that `await`s around this loop still returns early), and a rejection is never handled — in Node.js an unhandled rejection terminates the process by default, and in a browser it is lost. Iterate with `for (const item of items) { await … }` when the work must run in order, or `await Promise.all(items.map(async (item) => { … }))` when it may run concurrently, so the enclosing function finishes only when the work does and its failures reach the caller. Where firing and forgetting is genuinely intended, make the callback's whole body a `try { … } catch (e) { … }` that handles the failure, so it cannot escape.
  • `async` callback passed to `forEach` scripts/snippets/codemod.ts:453 — `forEach` ignores what its callback returns, so the Promise each `async` call returns is dropped: nothing can await it, the code after this loop runs before any of the awaited work has finished (a function that `await`s around this loop still returns early), and a rejection is never handled — in Node.js an unhandled rejection terminates the process by default, and in a browser it is lost. Iterate with `for (const item of items) { await … }` when the work must run in order, or `await Promise.all(items.map(async (item) => { … }))` when it may run concurrently, so the enclosing function finishes only when the work does and its failures reach the caller. Where firing and forgetting is genuinely intended, make the callback's whole body a `try { … } catch (e) { … }` that handles the failure, so it cannot escape.
X1 · Async correctness · `async` Promise executor · ×3
  • `async` Promise executor code/renderers/react/src/renderToCanvas.tsx:118 — The function passed to `new Promise(…)` is `async`. The constructor ignores what its executor returns, so anything this executor throws — every throw inside an `async` function, including after an `await` — rejects a Promise nobody holds instead of the one being constructed: the outer Promise never settles, whoever awaits it hangs, and the error is reported nowhere. If the body needs `await`, it does not need `new Promise` at all: make the enclosing function `async` and `return` the value (or `throw`) directly. If it wraps a callback API, keep the executor synchronous — call the API and `resolve`/`reject` from its callback — and do the awaiting outside it.
  • `async` Promise executor code/core/src/manager-api/modules/refs.ts:384 — The function passed to `new Promise(…)` is `async`. The constructor ignores what its executor returns, so anything this executor throws — every throw inside an `async` function, including after an `await` — rejects a Promise nobody holds instead of the one being constructed: the outer Promise never settles, whoever awaits it hangs, and the error is reported nowhere. If the body needs `await`, it does not need `new Promise` at all: make the enclosing function `async` and `return` the value (or `throw`) directly. If it wraps a callback API, keep the executor synchronous — call the API and `resolve`/`reject` from its callback — and do the awaiting outside it.
  • `async` Promise executor code/addons/vitest/src/node/vitest-manager.ts:189 — The function passed to `new Promise(…)` is `async`. The constructor ignores what its executor returns, so anything this executor throws — every throw inside an `async` function, including after an `await` — rejects a Promise nobody holds instead of the one being constructed: the outer Promise never settles, whoever awaits it hangs, and the error is reported nowhere. If the body needs `await`, it does not need `new Promise` at all: make the enclosing function `async` and `return` the value (or `throw`) directly. If it wraps a callback API, keep the executor synchronous — call the API and `resolve`/`reject` from its callback — and do the awaiting outside it.
AC2 · Forms & labels · <TextInput> field component without a label · ×2
  • <TextInput> field component without a label code/core/src/manager/settings/shortcuts.tsx:325 — This UI-library field component has no label / aria-label / aria-labelledby / id — and neither does anything it renders (a name prop is the form-submission key, not a label) — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
  • <TextInput> field component without a label code/core/src/manager/settings/shortcuts.tsx:334 — This UI-library field component is named only by a placeholder — a placeholder is not a label (it vanishes as soon as the user types, and many assistive technologies ignore it). Give it a real name whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
AC6 · Visual & motion safety · Animation without a prefers-reduced-motion guard · ×2
  • Animation without a prefers-reduced-motion guard code/core/assets/server/base-preview-head.html:288 — `.sb-loader` moves (`animation: sb-rotate360 0.7s linear infinite`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce.
  • Animation without a prefers-reduced-motion guard test-storybooks/portable-stories-kitchen-sink/nextjs/styles/Home.module.css:59 — `.card span` moves (`transition: transform 200ms`) and nothing reads prefers-reduced-motion for it — no @media (prefers-reduced-motion) rule for this element, no reset this project loads — so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Declare it under @media (prefers-reduced-motion: no-preference), or neutralise it under reduce.
AC6 · Visual & motion safety · Focus outline removed in CSS without a · ×2
  • Focus outline removed in CSS without a :focus replacement code/renderers/svelte/src/svelte-csf/__tests__/stories/Example.svelte:28 — `.button` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
  • Focus outline removed in CSS without a :focus replacement code/renderers/svelte/src/sample/MockButton.svelte:34 — `.button` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
D1 · Cyclomatic Complexity · buildAccessibilityTree · ×2
  • buildAccessibilityTree::nameOf (cyclomatic 30) agent-eval/lib/mcp/claude-browser-mock.mjs:955 — buildAccessibilityTree::nameOf has cyclomatic complexity 30 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
  • buildAccessibilityTree::visit (cyclomatic 23) agent-eval/lib/mcp/claude-browser-mock.mjs:1031 — buildAccessibilityTree::visit has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D12 · Dependency Hygiene · One package at two majors across the workspace · ×2
  • One package at two majors across the workspace: magic-string — `magic-string` is maintained at 2 different major versions inside this one repository — major 0 in code/lib/vite-plugin-storybook-nextjs/package.json; major 1 in code/builders/builder-webpack5/package.json, code/frameworks/react-vite/package.json, code/frameworks/svelte-vite/package.json (+2 more). Every major carries its own breaking changes, advisories and upgrade path, so the cost of keeping current is paid more than once; and where the packages are installed together, the resolver cannot dedupe them, so both copies ship.
  • One package at two majors across the workspace: style-loader — `style-loader` is maintained at 2 different major versions inside this one repository — major 3 in code/frameworks/nextjs/package.json; major 4 in code/builders/builder-webpack5/package.json. Every major carries its own breaking changes, advisories and upgrade path, so the cost of keeping current is paid more than once; and where the packages are installed together, the resolver cannot dedupe them, so both copies ship.
D2 · Cognitive Complexity · buildAccessibilityTree · ×2
  • buildAccessibilityTree::visit (cognitive 40) agent-eval/lib/mcp/claude-browser-mock.mjs:1031 — buildAccessibilityTree::visit has cognitive complexity 40 (threshold 15). Drivers by points: if/else 8 (17 pts), ternaries 3 (9 pts), loops 3 (7 pts), boolean chains 6, other 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • buildAccessibilityTree::nameOf (cognitive 38) agent-eval/lib/mcp/claude-browser-mock.mjs:955 — buildAccessibilityTree::nameOf has cognitive complexity 38 (threshold 15). Drivers by points: if/else 15 (22 pts), boolean chains 8, ternaries 3 (6 pts), loops 1, other 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ComponentMetaManager.findMatchTSConfig · ×2
  • ComponentMetaManager.findMatchTSConfig::getReferencesChains (cognitive 25) code/core/src/component-meta/ComponentMetaManager.ts:240 — ComponentMetaManager.findMatchTSConfig::getReferencesChains has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 2 (7 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ComponentMetaManager.findMatchTSConfig::findTSConfig) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
  • ComponentMetaManager.findMatchTSConfig::findTSConfig (cognitive 20) code/core/src/component-meta/ComponentMetaManager.ts:205 — ComponentMetaManager.findMatchTSConfig::findTSConfig has cognitive complexity 20 (threshold 15). Drivers by points: if/else 3 (12 pts), loops 3 (8 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (ComponentMetaManager.findMatchTSConfig::getReferencesChains) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · app-router-provider.AppRouterProvider (cognitive 20) · ×2
  • app-router-provider.AppRouterProvider (cognitive 20) code/frameworks/nextjs-vite/src/routing/app-router-provider.tsx:72 — app-router-provider.AppRouterProvider has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 2 (6 pts), boolean chains 2 (nesting depth added 11). None of this is in the body itself: all 20 points belong to one function literal inside it that branches (line 79). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
  • app-router-provider.AppRouterProvider (cognitive 20) code/frameworks/nextjs/src/routing/app-router-provider.tsx:72 — app-router-provider.AppRouterProvider has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 2 (6 pts), boolean chains 2 (nesting depth added 11). None of this is in the body itself: all 20 points belong to one function literal inside it that branches (line 79). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · extract-arg-types.extractArgTypesFromData (cognitive 20) · ×2
  • extract-arg-types.extractArgTypesFromData (cognitive 20) code/lib/angular-cm/src/extract-arg-types.ts:460 — extract-arg-types.extractArgTypesFromData has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 9, boolean chains 6, if/else 5. Most of this is not in the body itself: 2 of the 20 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 478, 538, 563). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
  • extract-arg-types.extractArgTypesFromData (cognitive 20) code/lib/angular-compodoc/src/extract-arg-types.ts:456 — extract-arg-types.extractArgTypesFromData has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 9, boolean chains 6, if/else 5. Most of this is not in the body itself: 2 of the 20 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 479, 530, 556). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · actualNameHandler.actualNameHandler (cognitive 18) · ×2
  • actualNameHandler.actualNameHandler (cognitive 18) code/renderers/react/src/componentManifest/reactDocgen/actualNameHandler.ts:17 — actualNameHandler.actualNameHandler has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
  • actualNameHandler.actualNameHandler (cognitive 18) code/frameworks/react-vite/src/plugins/docgen-handlers/actualNameHandler.ts:17 — actualNameHandler.actualNameHandler has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D23 · Boundary Type-Coupling · Cross-context type PreviewAnnotation (core → builder-vite) · ×2
  • Cross-context type PreviewAnnotation (core → builder-vite) code/builders/builder-vite/src/utils/process-preview-annotation.ts:6 — PreviewAnnotation (context core) is exposed in builder-vite's public surface via process-preview-annotation.processPreviewAnnotation — couples the contexts.
  • Cross-context type PreviewAnnotation (core → builder-vite) code/builders/builder-vite/src/codegen-project-annotations.ts:34 — PreviewAnnotation (context core) is exposed in builder-vite's public surface via codegen-project-annotations.generateProjectAnnotationsCodeFromPreviews — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type Type (svelte → react) · ×2
  • Cross-context type Type (svelte → react) code/renderers/react/src/componentManifest/types.ts:19 — Type (context svelte) is exposed in react's public surface via ResolvedComponentTarget.propsType — couples the contexts.
  • Cross-context type Type (svelte → react) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:478 — Type (context svelte) is exposed in react's public surface via componentMetaExtractor.resolvePropsFromComponentType — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type PropsTableMode (angular-cm → angular-vite) · ×2
  • Cross-context type PropsTableMode (angular-cm → angular-vite) code/frameworks/angular-vite/src/docgen/build-docgen.ts:18 — PropsTableMode (context angular-cm) is exposed in angular-vite's public surface via AngularDocgenOptions.propsTable — couples the contexts.
  • Cross-context type PropsTableMode (angular-cm → angular-vite) code/frameworks/angular-vite/src/props-table.ts:27 — PropsTableMode (context angular-cm) is exposed in angular-vite's public surface via props-table.resolvePropsTable — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type IndexEntry (core → docgen-harness) · ×2
  • Cross-context type IndexEntry (core → docgen-harness) code/lib/docgen-harness/src/angular/docgen-fixture.ts:17 — IndexEntry (context core) is exposed in docgen-harness's public surface via docgen-fixture.createFixtureDocgen.getDocgenPayload — couples the contexts.
  • Cross-context type IndexEntry (core → docgen-harness) code/lib/docgen-harness/src/web-components/story-docs/docgen-fixture.ts:9 — IndexEntry (context core) is exposed in docgen-harness's public surface via docgen-fixture.createFixtureDocgen — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type IndexEntry (core → svelte) · ×2
  • Cross-context type IndexEntry (core → svelte) code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts:142 — IndexEntry (context core) is exposed in svelte's public surface via resolve-component.resolveStoryComponent — couples the contexts.
  • Cross-context type IndexEntry (core → svelte) code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts:188 — IndexEntry (context core) is exposed in svelte's public surface via resolve-component.resolveStorySubcomponents — couples the contexts.
D29 · Static Analysis (SAST) · REDACTED · ×2
  • REDACTED
  • REDACTED
D35 · Change Coupling · Change coupling · ×2
  • Change coupling: FinalizationCommand.ts ↔ FeatureCompatibilityService.ts code/lib/create-storybook/src/commands/FinalizationCommand.ts:1 — `code/lib/create-storybook/src/commands/FinalizationCommand.ts` and `code/lib/create-storybook/src/services/FeatureCompatibilityService.ts` change together 64% of the time (7 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well, and counted over this repository's 10,000 most recent commits rather than its whole history — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 7 shared commits counted here, the most recent 3 are `c878263a` CLI: Drop skills get/list, add skills --all; `3428a631` Keep advertising storybook skills get <id> to agents.; `de2575a8` CLI: Align storybook skills with the tools command shape — run `git show` on any of them.
  • Change coupling: EVAL.ts ↔ templates.ts agent-eval/evals/812-first-story-empty-project/EVAL.ts:1 — `agent-eval/evals/812-first-story-empty-project/EVAL.ts` and `agent-eval/lib/templates.ts` change together 55% of the time (6 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well, and counted over this repository's 10,000 most recent commits rather than its whole history — a repo-wide or module-wide sweep is evidence about the sweep rather than about any pair inside it and is left out of BOTH sides of this ratio, while a dependency bump, a formatter/rename sweep, or a commit whose edit to one of the two files was a tool directive such as //go:generate or whitespace only is left out of the shared count ONLY, so the two sides are not taken over identical commit sets) with no explicit dependency — the edge is real but nothing declares it. Read the pair before acting: if one registers itself into the other through a hook or an initialiser, the missing dependency is DELIBERATE — the registration is the link, and it is meant not to be an import — and the thing to add is a comment on each side naming the other, not a merge; if they simply belong together, co-locate them; if neither holds, the coupling is hidden and worth breaking. You can check this without leaving the row: of the 6 shared commits counted here, the most recent 3 are `c3e16491` test(agent-eval): remove the review-off assertions; `11e16332` refactor(agent-eval): drop the Claude preview browser and check that …; `716cea35` feat(core): open the Storybook review in the harness's in-app browser — run `git show` on any of them.
IC1 · Incompleteness & stubs · Guard cannot change the result · ×2
  • Guard cannot change the result — returns what the code already falls through to agent-eval/lib/mcp/node-repl-mock.mjs:120 — The guard above `return 'image/png';` also returns `'image/png'`, so no input can make it matter. Implement the distinction that was intended, or delete the guard.
  • Guard cannot change the result — returns what the code already falls through to scripts/eval/lib/package-manager.ts:24 — The guard above `return 'npm';` also returns `'npm'`, so no input can make it matter. Implement the distinction that was intended, or delete the guard.
R10 · Code Duplication · Wholesale file copy (104 identical lines × 2 files) · ×2
  • Wholesale file copy (104 identical lines × 2 files) code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts:1 — code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts:1 · code/frameworks/angular/src/client/angular-beta/AbstractRenderer.ts:1 — these 2 files are line-for-line copies of one another — 104 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
  • Wholesale file copy (104 identical lines × 2 files) code/frameworks/react-native-web-vite/template/cli/js/Page.jsx:1 — code/frameworks/react-native-web-vite/template/cli/js/Page.jsx:1 · code/frameworks/react-native-web-vite/template/cli/ts/Page.tsx:1 — these 2 files are line-for-line copies of one another — 104 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication · Duplicated block with local edits (95 matched lines × 2 locations) · ×2
  • Duplicated block with local edits (95 matched lines × 2 locations) code/frameworks/angular-vite/src/builders/build-storybook/index.ts:86 — code/frameworks/angular-vite/src/builders/build-storybook/index.ts:86 · code/frameworks/angular-vite/src/builders/start-storybook/index.ts:98 — the two spans are one implementation copied and then locally edited — 434 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
  • Duplicated block with local edits (95 matched lines × 2 locations) code/frameworks/angular/src/builders/build-storybook/index.ts:35 — code/frameworks/angular/src/builders/build-storybook/index.ts:35 · code/frameworks/angular/src/builders/start-storybook/index.ts:36 — the two spans are one implementation copied and then locally edited — 497 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Wholesale file copy (85 identical lines × 2 files) · ×2
  • Wholesale file copy (85 identical lines × 2 files) code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts:1 — code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts:1 · code/frameworks/angular/src/client/angular-beta/StorybookWrapperComponent.ts:1 — these 2 files are line-for-line copies of one another — 85 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
  • Wholesale file copy (85 identical lines × 2 files) REDACTED:1 — REDACTED:1 · REDACTED:1 — these 2 files are line-for-line copies of one another — 85 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R7 · Dead Code · Dead file (~92 LoC) · ×2
  • Dead file (~92 LoC) code/frameworks/ember/src/client/preview/render.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/frameworks/ember/src/client/preview/config.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
  • Dead file (~92 LoC) code/lib/vite-plugin-storybook-nextjs/build-config.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~49 LoC) · ×2
  • Dead file (~49 LoC) code/frameworks/angular-vite/template/components/button.component.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/frameworks/angular-vite/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
  • Dead file (~49 LoC) code/frameworks/angular/template/components/button.component.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/frameworks/angular/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~47 LoC) · ×2
  • Dead file (~47 LoC) code/frameworks/ember/src/client/preview/jsondoc.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/frameworks/ember/src/client/preview/config.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
  • Dead file (~47 LoC) code/renderers/react/template/stories/docgen-components/js-function-component/input.jsx — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/renderers/react/template/stories/docgen-components/js-re-exported-component/input.jsx) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~45 LoC) · ×2
  • Dead file (~45 LoC) code/builders/builder-webpack5/build-config.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
  • Dead file (~45 LoC) code/renderers/web-components/build-config.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
X19 · Unrestored process-global state · Process-global state is restored only on the happy path · ×2
  • Process-global state is restored only on the happy path code/lib/cli-storybook/src/sandbox.ts:35 — `sandbox` changes state that belongs to the whole PROCESS and changes it back at the end of the same body — the process working directory (changed at line 223, put back at line 234) — which says the change was meant to last no longer than this call. But the restore is an ordinary statement on the straight-line path, not a `finally`, so it is skipped by any exception thrown in between — or by a promise that rejects at an `await`, and while this function is suspended at one every other callback the event loop runs sees the moved value too: the process then keeps the overwritten value for the rest of its life, and every later relative path, child-process launch or config read in ANY module resolves against it. That failure is silent and remote from its cause — the function that breaks is not the function that moved the directory. The durable fix is not to widen the restore but to stop mutating the global: pass the value to the operation that needs it — the `cwd` and `env` options of `child_process.spawn`/`exec`/`execSync` (or `Deno.Command`) scope both to the CHILD — or build absolute paths with `path.resolve`. Where the global genuinely must move, wrap it `try`/`finally` so the restore runs on every path.
  • Process-global state is restored only on the happy path REDACTED:38 — this arrow function changes state that belongs to the whole PROCESS and changes it back at the end of the same body — the `__NEXT_PRIVATE_RENDER_WORKER` environment variable (set at line 48, put back at line 55) — which says the change was meant to last no longer than this call. But the restore is an ordinary statement on the straight-line path, not a `finally`, so it is skipped by any exception thrown in between: the process then keeps the overwritten value for the rest of its life, and every later relative path, child-process launch or config read in ANY module resolves against it. That failure is silent and remote from its cause — the function that breaks is not the function that moved the directory. The durable fix is not to widen the restore but to stop mutating the global: pass the value to the operation that needs it — the `cwd` and `env` options of `child_process.spawn`/`exec`/`execSync` (or `Deno.Command`) scope both to the CHILD — or build absolute paths with `path.resolve`. Where the global genuinely must move, wrap it `try`/`finally` so the restore runs on every path.
AC2 · Forms & labels · <optgroup> without a label · ×1
  • <optgroup> without a label code/core/src/components/components/Form/Select.tsx:136 — An <optgroup> groups <option>s but has no label, so assistive tech announces the group with no name. Add a label attribute.
AC3 · Page structure · Empty <h1> heading · ×1
  • Empty <h1> heading code/core/assets/server/base-preview-body.html:86 — An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
D1 · Cyclomatic Complexity · Tree.Tree (cyclomatic 85) · ×1
  • Tree.Tree (cyclomatic 85) code/core/src/manager/components/sidebar/Tree.tsx:118 — Tree.Tree has cyclomatic complexity 85 (threshold 15). Most of this is not in the body itself: 3 of the 85 points are its own statements and the rest belongs to 28 function literals inside it that branch (lines 560, 233, 522, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · scope.analyzeScopes.visitNode (cyclomatic 81) · ×1
  • scope.analyzeScopes.visitNode (cyclomatic 81) code/core/src/csf-tools/estree/scope.ts:569 — scope.analyzeScopes.visitNode has cyclomatic complexity 81 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Select.Select (cyclomatic 81) · ×1
  • Select.Select (cyclomatic 81) code/core/src/components/components/Select/Select.tsx:205 — Select.Select has cyclomatic complexity 81 (threshold 15). Of this number, 18 points are the body's own statements and 63 belong to 20 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · story-to-csf-factory.storyToCsfFactory (cyclomatic 79) · ×1
  • story-to-csf-factory.storyToCsfFactory (cyclomatic 79) code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.ts:83 — story-to-csf-factory.storyToCsfFactory has cyclomatic complexity 79 (threshold 15). Of this number, 28 points are the body's own statements and 51 belong to 9 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · useHighlights.useHighlights (cyclomatic 71) · ×1
  • useHighlights.useHighlights (cyclomatic 71) code/core/src/highlight/useHighlights.ts:36 — useHighlights.useHighlights has cyclomatic complexity 71 (threshold 15). Most of this is not in the body itself: 2 of the 71 points are its own statements and the rest belongs to 25 function items inside it that branch (renderMenu, a function literal at line 256, a function literal at line 434, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · ConfigObject.locateConfigRoot (cyclomatic 67) · ×1
  • ConfigObject.locateConfigRoot (cyclomatic 67) code/core/src/csf-tools/ConfigObject.ts:78 — ConfigObject.locateConfigRoot has cyclomatic complexity 67 (threshold 15). Of this number, 50 points are the body's own statements and 17 belong to 6 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · render-components-manifest.renderComponentCard (cyclomatic 66) · ×1
  • render-components-manifest.renderComponentCard (cyclomatic 66) code/core/src/core-server/utils/manifests/render-components-manifest.ts:973 — render-components-manifest.renderComponentCard has cyclomatic complexity 66 (threshold 15). Of this number, 47 points are the body's own statements and 19 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · shortcuts.init (cyclomatic 61) · ×1
  • shortcuts.init (cyclomatic 61) code/core/src/manager-api/modules/shortcuts.ts:197 — shortcuts.init has cyclomatic complexity 61 (threshold 15). Of this number, 53 points are the body's own statements and 8 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Search.Search (cyclomatic 59) · ×1
  • Search.Search (cyclomatic 59) code/core/src/manager/components/sidebar/Search.tsx:177 — Search.Search has cyclomatic complexity 59 (threshold 15). Most of this is not in the body itself: 2 of the 59 points are its own statements and the rest belongs to 10 function literals inside it that branch (lines 383, 322, 402, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · html-report.buildEffects (cyclomatic 58) · ×1
  • html-report.buildEffects (cyclomatic 58) agent-eval/lib/agentic-reference/comparison/html-report.ts:1311 — html-report.buildEffects has cyclomatic complexity 58 (threshold 15). Of this number, 30 points are the body's own statements and 28 belong to 6 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · CsfFile._visitExportNamed (cyclomatic 57) · ×1
  • CsfFile._visitExportNamed (cyclomatic 57) REDACTED:891 — CsfFile._visitExportNamed has cyclomatic complexity 57 (threshold 15). Of this number, 56 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · createTab (cyclomatic 57) · ×1
  • createTab (cyclomatic 57) agent-eval/lib/mcp/codex-browser-client-mock.mjs:343 — createTab has cyclomatic complexity 57 (threshold 15). Most of this is not in the body itself: 1 of the 57 points is its own statement and the rest belongs to 86 function items inside it that branch (a function literal at line 466, scroll, get::readEvents, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · esmWalker.esmWalker (cyclomatic 56) · ×1
  • esmWalker.esmWalker (cyclomatic 56) code/core/src/mocking-utils/esmWalker.ts:71 — esmWalker.esmWalker has cyclomatic complexity 56 (threshold 15). Of this number, 26 points are the body's own statements and 30 belong to 7 function items inside it that branch. This file's own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes — or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages.
D1 · Cyclomatic Complexity · shell-parse.scanShellWords (cyclomatic 49) · ×1
  • shell-parse.scanShellWords (cyclomatic 49) agent-eval/lib/shell-parse.ts:438 — shell-parse.scanShellWords has cyclomatic complexity 49 (threshold 15). Of this number, 36 points are the body's own statements and 13 belong to 3 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · layout.init (cyclomatic 49) · ×1
  • layout.init (cyclomatic 49) code/core/src/manager-api/modules/layout.ts:264 — layout.init has cyclomatic complexity 49 (threshold 15). Of this number, 18 points are the body's own statements and 31 belong to 9 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · upgrade.upgrade (cyclomatic 49) · ×1
  • upgrade.upgrade (cyclomatic 49) code/lib/cli-storybook/src/upgrade.ts:352 — upgrade.upgrade has cyclomatic complexity 49 (threshold 15). Of this number, 42 points are the body's own statements and 7 belong to 4 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Editor.groupValues (cyclomatic 46) · ×1
  • Editor.groupValues (cyclomatic 46) code/core/src/csf-tools/CsfObject.ts:692 — Editor.groupValues has cyclomatic complexity 46 (threshold 15). Of this number, 44 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · generate-docgen.extractDocgen (cyclomatic 46) · ×1
  • generate-docgen.extractDocgen (cyclomatic 46) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts:510 — generate-docgen.extractDocgen has cyclomatic complexity 46 (threshold 15). Most of this is not in the body itself: 10 of the 46 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 625, 578, 547, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · build-dev.buildDevStandalone (cyclomatic 44) · ×1
  • build-dev.buildDevStandalone (cyclomatic 44) code/core/src/core-server/build-dev.ts:75 — build-dev.buildDevStandalone has cyclomatic complexity 44 (threshold 15). Of this number, 43 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · TestingWidget.TestingWidget (cyclomatic 44) · ×1
  • TestingWidget.TestingWidget (cyclomatic 44) code/core/src/manager/components/sidebar/TestingWidget.tsx:159 — TestingWidget.TestingWidget has cyclomatic complexity 44 (threshold 15). Of this number, 35 points are the body's own statements and 9 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · vitest-setup-file.transformSetupFile (cyclomatic 44) · ×1
  • vitest-setup-file.transformSetupFile (cyclomatic 44) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:328 — vitest-setup-file.transformSetupFile has cyclomatic complexity 44 (threshold 15). Of this number, 31 points are the body's own statements and 13 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · A11yContext.A11yContextProvider (cyclomatic 43) · ×1
  • A11yContext.A11yContextProvider (cyclomatic 43) code/addons/a11y/src/components/A11yContext.tsx:111 — A11yContext.A11yContextProvider has cyclomatic complexity 43 (threshold 15). Most of this is not in the body itself: 1 of the 43 points is its own statement and the rest belongs to 18 function literals inside it that branch (lines 473, 265, 373, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · Button.StyledButton (cyclomatic 43) · ×1
  • Button.StyledButton (cyclomatic 43) code/core/src/components/components/Button/Button.tsx:185 — Button.StyledButton has cyclomatic complexity 43 (threshold 15). Most of this is not in the body itself: 13 of the 43 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 218, 269, 251, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · print-template.printTemplate (cyclomatic 43) · ×1
  • print-template.printTemplate (cyclomatic 43) code/renderers/svelte/src/docgen/story-docs/print-template.ts:33 — print-template.printTemplate has cyclomatic complexity 43 (threshold 15). Of this number, 33 points are the body's own statements and 10 belong to 7 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · runComputerAction (cyclomatic 43) · ×1
  • runComputerAction (cyclomatic 43) agent-eval/lib/mcp/claude-browser-mock.mjs:1429 — runComputerAction has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · html-report.buildFullReport (cyclomatic 42) · ×1
  • html-report.buildFullReport (cyclomatic 42) agent-eval/lib/agentic-reference/comparison/html-report.ts:1692 — html-report.buildFullReport has cyclomatic complexity 42 (threshold 15). Most of this is not in the body itself: 12 of the 42 points are its own statements and the rest belongs to 6 function items inside it that branch (a function literal at line 1761, entryKey, a function literal at line 1749, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · stories.transformStoryIndexToStoriesHash (cyclomatic 42) · ×1
  • stories.transformStoryIndexToStoriesHash (cyclomatic 42) code/core/src/manager-api/lib/stories.ts:106 — stories.transformStoryIndexToStoriesHash has cyclomatic complexity 42 (threshold 15). Most of this is not in the body itself: 6 of the 42 points are its own statements and the rest belongs to 14 function items inside it that branch (a function literal at line 167, a function literal at line 128, a function literal at line 185, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · index.storybookTest (cyclomatic 41) · ×1
  • index.storybookTest (cyclomatic 41) code/addons/vitest/src/vitest-plugin/index.ts:197 — index.storybookTest has cyclomatic complexity 41 (threshold 15). Of this number, 39 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · ConfigFile.parse (cyclomatic 41) · ×1
  • ConfigFile.parse (cyclomatic 41) code/core/src/csf-tools/ConfigFile.ts:538 — ConfigFile.parse has cyclomatic complexity 41 (threshold 15). Most of this is not in the body itself: 1 of the 41 points is its own statement and the rest belongs to one function literal inside it that branches (line 539). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · server-code-elimination.eliminateServerCode (cyclomatic 41) · ×1
  • server-code-elimination.eliminateServerCode (cyclomatic 41) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts:77 — server-code-elimination.eliminateServerCode has cyclomatic complexity 41 (threshold 15). Most of this is not in the body itself: 5 of the 41 points are its own statements and the rest belongs to 4 function items inside it that branch (a function literal at line 110, a function literal at line 86, remove, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · postinstall.postInstall (cyclomatic 40) · ×1
  • postinstall.postInstall (cyclomatic 40) code/addons/vitest/src/postinstall.ts:58 — postinstall.postInstall has cyclomatic complexity 40 (threshold 15). Of this number, 37 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · sandbox.sandbox (cyclomatic 40) · ×1
  • sandbox.sandbox (cyclomatic 40) code/lib/cli-storybook/src/sandbox.ts:35 — sandbox.sandbox has cyclomatic complexity 40 (threshold 15). Of this number, 32 points are the body's own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · transform-template.transformDirective (cyclomatic 39) · ×1
  • transform-template.transformDirective (cyclomatic 39) code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:520 — transform-template.transformDirective has cyclomatic complexity 39 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · ConfigFile.findCallArguments (cyclomatic 38) · ×1
  • ConfigFile.findCallArguments (cyclomatic 38) code/core/src/csf-tools/ConfigFile.ts:1003 — ConfigFile.findCallArguments has cyclomatic complexity 38 (threshold 15). Most of this is not in the body itself: 1 of the 38 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 1014, 1056). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · index.runFixes (cyclomatic 38) · ×1
  • index.runFixes (cyclomatic 38) code/lib/cli-storybook/src/automigrate/index.ts:253 — index.runFixes has cyclomatic complexity 38 (threshold 15). Of this number, 35 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · parse-snapshot.parseArgTypesSnapshot (cyclomatic 38) · ×1
  • parse-snapshot.parseArgTypesSnapshot (cyclomatic 38) REDACTED:15 — parse-snapshot.parseArgTypesSnapshot has cyclomatic complexity 38 (threshold 15). Most of this is not in the body itself: 7 of the 38 points are its own statements and the rest belongs to 6 function items inside it that branch (parseBareToken, parseObject, parseArray, …). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · forward-setup.readForwardableSetup (cyclomatic 38) · ×1
  • forward-setup.readForwardableSetup (cyclomatic 38) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts:90 — forward-setup.readForwardableSetup has cyclomatic complexity 38 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · preset.experimental_devServer (cyclomatic 37) · ×1
  • preset.experimental_devServer (cyclomatic 37) code/addons/mcp/src/preset.ts:32 — preset.experimental_devServer has cyclomatic complexity 37 (threshold 15). Most of this is not in the body itself: 7 of the 37 points are its own statements and the rest belongs to 6 function items inside it that branch (a function literal at line 189, rejectDisallowedOrigin, a function literal at line 157, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · get-dummy-args-from-argtypes.generateDummyValueFromSBType (cyclomatic 37) · ×1
  • get-dummy-args-from-argtypes.generateDummyValueFromSBType (cyclomatic 37) code/core/src/core-server/utils/get-dummy-args-from-argtypes.ts:146 — get-dummy-args-from-argtypes.generateDummyValueFromSBType has cyclomatic complexity 37 (threshold 15). Of this number, 36 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · StoryRender.render (cyclomatic 36) · ×1
  • StoryRender.render (cyclomatic 36) code/core/src/preview-api/modules/preview-web/render/StoryRender.ts:185 — StoryRender.render has cyclomatic complexity 36 (threshold 15). Of this number, 30 points are the body's own statements and 6 belong to 6 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · PreviewWithSelection.renderSelection (cyclomatic 36) · ×1
  • PreviewWithSelection.renderSelection (cyclomatic 36) code/core/src/preview-api/modules/preview-web/PreviewWithSelection.tsx:304 — PreviewWithSelection.renderSelection has cyclomatic complexity 36 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · component-transformer.collectComponentExports (cyclomatic 36) · ×1
  • component-transformer.collectComponentExports (cyclomatic 36) code/core/src/csf-tools/vitest-plugin/component-transformer.ts:94 — component-transformer.collectComponentExports has cyclomatic complexity 36 (threshold 15). Of this number, 33 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · useDragging.useDragging (cyclomatic 35) · ×1
  • useDragging.useDragging (cyclomatic 35) code/core/src/manager/components/layout/useDragging.ts:109 — useDragging.useDragging has cyclomatic complexity 35 (threshold 15). Most of this is not in the body itself: 1 of the 35 points is its own statement and the rest belongs to 8 function literals inside it that branch (lines 212, 160, 311, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · config-to-csf-factory.configToCsfFactory (cyclomatic 35) · ×1
  • config-to-csf-factory.configToCsfFactory (cyclomatic 35) code/lib/cli-storybook/src/codemod/helpers/config-to-csf-factory.ts:27 — config-to-csf-factory.configToCsfFactory has cyclomatic complexity 35 (threshold 15). Of this number, 18 points are the body's own statements and 17 belong to 6 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · forward-setup.collectFreeExpression (cyclomatic 35) · ×1
  • forward-setup.collectFreeExpression (cyclomatic 35) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts:355 — forward-setup.collectFreeExpression has cyclomatic complexity 35 (threshold 15). Of this number, 29 points are the body's own statements and 6 belong to 2 function literals inside it that branch. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · task.run (cyclomatic 35) · ×1
  • task.run (cyclomatic 35) scripts/task.ts:411 — task.run has cyclomatic complexity 35 (threshold 15). Of this number, 31 points are the body's own statements and 4 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · getComponentImports.getComponents (cyclomatic 34) · ×1
  • getComponentImports.getComponents (cyclomatic 34) code/renderers/react/src/componentManifest/getComponentImports.ts:63 — getComponentImports.getComponents has cyclomatic complexity 34 (threshold 15). Most of this is not in the body itself: 3 of the 34 points are its own statements and the rest belongs to 4 function items inside it that branch (a function literal at line 145, a function literal at line 85, a function literal at line 99, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · template-print.resolveAttribute (cyclomatic 34) · ×1
  • template-print.resolveAttribute (cyclomatic 34) code/renderers/web-components/src/docgen/story-docs/template-print.ts:174 — template-print.resolveAttribute has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · tool-tokens.parseToolsTokens (cyclomatic 33) · ×1
  • tool-tokens.parseToolsTokens (cyclomatic 33) code/core/src/cli/tools/tool-tokens.ts:44 — tool-tokens.parseToolsTokens has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · componentMetaExtractor.serializeComponentDoc (cyclomatic 33) · ×1
  • componentMetaExtractor.serializeComponentDoc (cyclomatic 33) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1404 — componentMetaExtractor.serializeComponentDoc has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · ReviewProvider.ReviewProvider (cyclomatic 33) · ×1
  • ReviewProvider.ReviewProvider (cyclomatic 33) code/core/src/manager/components/review/components/ReviewProvider.tsx:69 — ReviewProvider.ReviewProvider has cyclomatic complexity 33 (threshold 15). Most of this is not in the body itself: 4 of the 33 points are its own statements and the rest belongs to 10 function literals inside it that branch (lines 134, 244, 268, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · story-docs-args.evaluateNode (cyclomatic 33) · ×1
  • story-docs-args.evaluateNode (cyclomatic 33) code/frameworks/angular-vite/src/docgen/story-docs-args.ts:125 — story-docs-args.evaluateNode has cyclomatic complexity 33 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · resolve.analyzeExpression (cyclomatic 32) · ×1
  • resolve.analyzeExpression (cyclomatic 32) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/resolve.ts:404 — resolve.analyzeExpression has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · componentMetaExtractor.resolveLiteralValue (cyclomatic 32) · ×1
  • componentMetaExtractor.resolveLiteralValue (cyclomatic 32) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:824 — componentMetaExtractor.resolveLiteralValue has cyclomatic complexity 32 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · react-loadable-plugin.default (cyclomatic 32) · ×1
  • react-loadable-plugin.default (cyclomatic 32) code/frameworks/nextjs/src/babel/plugins/react-loadable-plugin.ts:9 — react-loadable-plugin.default has cyclomatic complexity 32 (threshold 15). Most of this is not in the body itself: 4 of the 32 points are its own statements and the rest belongs to one function literal inside it that branches (line 34). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · jsxDecorator.renderJsx (cyclomatic 32) · ×1
  • jsxDecorator.renderJsx (cyclomatic 32) code/renderers/react/src/docs/jsxDecorator.tsx:88 — jsxDecorator.renderJsx has cyclomatic complexity 32 (threshold 15). Most of this is not in the body itself: 15 of the 32 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 138, 184). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · url.init (cyclomatic 31) · ×1
  • url.init (cyclomatic 31) code/core/src/manager-api/modules/url.ts:239 — url.init has cyclomatic complexity 31 (threshold 15). Of this number, 26 points are the body's own statements and 5 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · versions.init (cyclomatic 31) · ×1
  • versions.init (cyclomatic 31) code/core/src/manager-api/modules/versions.ts:74 — versions.init has cyclomatic complexity 31 (threshold 15). Most of this is not in the body itself: 1 of the 31 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 104, 148, 94). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · values.readResolved (cyclomatic 31) · ×1
  • values.readResolved (cyclomatic 31) code/core/src/csf-tools/estree/values.ts:167 — values.readResolved has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · parser.parseForIndexer (cyclomatic 31) · ×1
  • parser.parseForIndexer (cyclomatic 31) code/renderers/svelte/src/svelte-csf/indexer/parser.ts:56 — parser.parseForIndexer has cyclomatic complexity 31 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · analyze-results.main (cyclomatic 30) · ×1
  • analyze-results.main (cyclomatic 30) agent-eval/scripts/analyze-results.ts:296 — analyze-results.main has cyclomatic complexity 30 (threshold 15). Of this number, 28 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · CsfFile.parse (cyclomatic 30) · ×1
  • CsfFile.parse (cyclomatic 30) REDACTED:1212 — CsfFile.parse has cyclomatic complexity 30 (threshold 15). Of this number, 16 points are the body's own statements and 14 belong to 3 function items inside it that branch. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
D1 · Cyclomatic Complexity · checklist.initializeChecklist (cyclomatic 30) · ×1
  • checklist.initializeChecklist (cyclomatic 30) code/core/src/core-server/utils/checklist.ts:28 — checklist.initializeChecklist has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 3 of the 30 points are its own statements and the rest belongs to 13 function items inside it that branch (isAiSetupCompleted, a function literal at line 246, scheduleIdleCheck, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · Viewport.Viewport (cyclomatic 30) · ×1
  • Viewport.Viewport (cyclomatic 30) code/core/src/manager/components/preview/Viewport.tsx:200 — Viewport.Viewport has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 11 of the 30 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 224, 275, 243). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · preset.default (cyclomatic 30) · ×1
  • preset.default (cyclomatic 30) code/frameworks/nextjs/src/babel/preset.ts:68 — preset.default has cyclomatic complexity 30 (threshold 15). Of this number, 27 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · server-code-elimination.isPure (cyclomatic 30) · ×1
  • server-code-elimination.isPure (cyclomatic 30) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts:401 — server-code-elimination.isPure has cyclomatic complexity 30 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · print-template.replaceArgsReads (cyclomatic 30) · ×1
  • print-template.replaceArgsReads (cyclomatic 30) code/renderers/svelte/src/docgen/story-docs/print-template.ts:251 — print-template.replaceArgsReads has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 9 of the 30 points are its own statements and the rest belongs to 2 function items inside it that branch (a function literal at line 266, valueOf). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · shell-parse.parseToolArguments (cyclomatic 29) · ×1
  • shell-parse.parseToolArguments (cyclomatic 29) agent-eval/lib/shell-parse.ts:302 — shell-parse.parseToolArguments has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · componentMetaExtractor.extractStaticDefaultProps (cyclomatic 29) · ×1
  • componentMetaExtractor.extractStaticDefaultProps (cyclomatic 29) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1164 — componentMetaExtractor.extractStaticDefaultProps has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · default-initializer.literalKind (cyclomatic 29) · ×1
  • default-initializer.literalKind (cyclomatic 29) code/lib/angular-cm/src/analyzer/default-initializer.ts:30 — default-initializer.literalKind has cyclomatic complexity 29 (threshold 15). Of this number, 27 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · scope.analyzeScopes (cyclomatic 28) · ×1
  • scope.analyzeScopes (cyclomatic 28) code/core/src/csf-tools/estree/scope.ts:293 — scope.analyzeScopes has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · editor.appendFirst (cyclomatic 28) · ×1
  • editor.appendFirst (cyclomatic 28) code/core/src/csf-tools/estree/editor.ts:1082 — editor.appendFirst has cyclomatic complexity 28 (threshold 15). Of this number, 27 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · ObjectMembers.onlyRead (cyclomatic 28) · ×1
  • ObjectMembers.onlyRead (cyclomatic 28) code/core/src/csf-tools/ObjectMembers.ts:111 — ObjectMembers.onlyRead has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 1 of the 28 points is its own statement and the rest belongs to one function literal inside it that branches (line 112). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · definition.createDocsToolset (cyclomatic 28) · ×1
  • definition.createDocsToolset (cyclomatic 28) code/core/src/shared/open-service/toolsets/docs/definition.ts:399 — definition.createDocsToolset has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 6 of the 28 points are its own statements and the rest belongs to 7 function items inside it that branch (a function literal at line 581, recoverMissedId, a function literal at line 515, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · Panel.Panel (cyclomatic 28) · ×1
  • Panel.Panel (cyclomatic 28) code/core/src/component-testing/components/Panel.tsx:223 — Panel.Panel has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 6 of the 28 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 399, 406, 416, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · exportNameHandler.exportNameHandler (cyclomatic 28) · ×1
  • exportNameHandler.exportNameHandler (cyclomatic 28) code/renderers/react/src/componentManifest/reactDocgen/exportNameHandler.ts:100 — exportNameHandler.exportNameHandler has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · componentMetaExtractor.resolveComponentSymbol (cyclomatic 28) · ×1
  • componentMetaExtractor.resolveComponentSymbol (cyclomatic 28) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:147 — componentMetaExtractor.resolveComponentSymbol has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · vitest-setup-file.resolveStaticPath (cyclomatic 28) · ×1
  • vitest-setup-file.resolveStaticPath (cyclomatic 28) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:857 — vitest-setup-file.resolveStaticPath has cyclomatic complexity 28 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · create-server-arg-types.createServerArgTypes (cyclomatic 28) · ×1
  • create-server-arg-types.createServerArgTypes (cyclomatic 28) code/renderers/svelte/src/docgen/component-docgen/arg-types/create-server-arg-types.ts:58 — create-server-arg-types.createServerArgTypes has cyclomatic complexity 28 (threshold 15). Of this number, 26 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · census.censusReactTree (cyclomatic 27) · ×1
  • census.censusReactTree (cyclomatic 27) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/census.ts:80 — census.censusReactTree has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 4 of the 27 points are its own statements and the rest belongs to 3 function items inside it that branch (count, walk, a function literal at line 116). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · storybook-metadata.computeStorybookMetadata (cyclomatic 27) · ×1
  • storybook-metadata.computeStorybookMetadata (cyclomatic 27) code/core/src/telemetry/storybook-metadata.ts:112 — storybook-metadata.computeStorybookMetadata has cyclomatic complexity 27 (threshold 15). Of this number, 19 points are the body's own statements and 8 belong to 5 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · service-transport.connectRuntimeToChannel (cyclomatic 27) · ×1
  • service-transport.connectRuntimeToChannel (cyclomatic 27) code/core/src/shared/open-service/service-transport.ts:160 — service-transport.connectRuntimeToChannel has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 1 of the 27 points is its own statement and the rest belongs to 6 function items inside it that branch (onEntry, onSyncReply, onSyncRequest, …). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · Modal.BaseModal (cyclomatic 27) · ×1
  • Modal.BaseModal (cyclomatic 27) code/core/src/components/components/Modal/Modal.tsx:78 — Modal.BaseModal has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 13 of the 27 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 165, 185, 175, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · story-docs-ng-modules.ngModulesFromDecorators (cyclomatic 27) · ×1
  • story-docs-ng-modules.ngModulesFromDecorators (cyclomatic 27) code/frameworks/angular-vite/src/docgen/story-docs-ng-modules.ts:24 — story-docs-ng-modules.ngModulesFromDecorators has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · generateCodeSnippet.rewriteJsx (cyclomatic 27) · ×1
  • generateCodeSnippet.rewriteJsx (cyclomatic 27) code/renderers/react/src/componentManifest/generateCodeSnippet.ts:328 — generateCodeSnippet.rewriteJsx has cyclomatic complexity 27 (threshold 15). Of this number, 19 points are the body's own statements and 8 belong to 3 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · print-h.isPrintableArgsExpression (cyclomatic 27) · ×1
  • print-h.isPrintableArgsExpression (cyclomatic 27) code/renderers/vue3/src/docgen/story-docs/print-h/print-h.ts:538 — print-h.isPrintableArgsExpression has cyclomatic complexity 27 (threshold 15). Of this number, 23 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · ArgsTable.ArgsTable (cyclomatic 26) · ×1
  • ArgsTable.ArgsTable (cyclomatic 26) code/addons/docs/src/blocks/components/ArgsTable/ArgsTable.tsx:335 — ArgsTable.ArgsTable has cyclomatic complexity 26 (threshold 15). Of this number, 17 points are the body's own statements and 9 belong to 6 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · changed-files-outside-stories.detectChangedFilesOutsideStories (cyclomatic 26) · ×1
  • changed-files-outside-stories.detectChangedFilesOutsideStories (cyclomatic 26) code/core/src/shared/open-service/toolsets/stories/changed-files-outside-stories.ts:45 — changed-files-outside-stories.detectChangedFilesOutsideStories has cyclomatic complexity 26 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · build-static.buildStaticStandalone (cyclomatic 26) · ×1
  • build-static.buildStaticStandalone (cyclomatic 26) code/core/src/core-server/build-static.ts:40 — build-static.buildStaticStandalone has cyclomatic complexity 26 (threshold 15). Of this number, 21 points are the body's own statements and 5 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · TreeNode.TreeNode (cyclomatic 26) · ×1
  • TreeNode.TreeNode (cyclomatic 26) code/core/src/manager/components/sidebar/TreeNode.tsx:270 — TreeNode.TreeNode has cyclomatic complexity 26 (threshold 15). Most of this is not in the body itself: 5 of the 26 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 464, 403, 422, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · churn.collectShellOperations (cyclomatic 25) · ×1
  • churn.collectShellOperations (cyclomatic 25) agent-eval/lib/agentic-reference/metrics/churn.ts:94 — churn.collectShellOperations has cyclomatic complexity 25 (threshold 15). Of this number, 23 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · identify.createResolver · ×1
  • identify.createResolver::memberOf (cyclomatic 25) agent-eval/lib/agentic-reference/metrics/ds-coverage/identify.ts:449 — identify.createResolver::memberOf has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · VitestManager.startVitest (cyclomatic 25) · ×1
  • VitestManager.startVitest (cyclomatic 25) code/addons/vitest/src/node/vitest-manager.ts:54 — VitestManager.startVitest has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · convert.convert (cyclomatic 25) · ×1
  • convert.convert (cyclomatic 25) code/core/src/docs-tools/argTypes/convert/proptypes/convert.ts:10 — convert.convert has cyclomatic complexity 25 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · shortcut.eventToShortcut (cyclomatic 25) · ×1
  • shortcut.eventToShortcut (cyclomatic 25) code/core/src/manager-api/lib/shortcut.ts:21 — shortcut.eventToShortcut has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · Editor.moveValue (cyclomatic 25) · ×1
  • Editor.moveValue (cyclomatic 25) code/core/src/csf-tools/CsfObject.ts:615 — Editor.moveValue has cyclomatic complexity 25 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · componentMetaExtractor.extractDestructuringDefaults (cyclomatic 25) · ×1
  • componentMetaExtractor.extractDestructuringDefaults (cyclomatic 25) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1020 — componentMetaExtractor.extractDestructuringDefaults has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · transformer.vitestTransform (cyclomatic 25) · ×1
  • transformer.vitestTransform (cyclomatic 25) code/core/src/csf-tools/vitest-plugin/transformer.ts:101 — transformer.vitestTransform has cyclomatic complexity 25 (threshold 15). Of this number, 16 points are the body's own statements and 9 belong to 4 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · Instrumenter.constructor (cyclomatic 25) · ×1
  • Instrumenter.constructor (cyclomatic 25) code/core/src/instrumenter/instrumenter.ts:103 — Instrumenter.constructor has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 2 of the 25 points are its own statements and the rest belongs to 9 function items inside it that branch (renderPhaseChanged, resetState, a function literal at line 179, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · FilterPanel.FilterPanel (cyclomatic 25) · ×1
  • FilterPanel.FilterPanel (cyclomatic 25) code/core/src/manager/components/sidebar/FilterPanel.tsx:42 — FilterPanel.FilterPanel has cyclomatic complexity 25 (threshold 15). Of this number, 15 points are the body's own statements and 10 belong to 5 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · Checklist.Checklist (cyclomatic 25) · ×1
  • Checklist.Checklist (cyclomatic 25) code/core/src/manager/settings/Checklist/Checklist.tsx:254 — Checklist.Checklist has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 1 of the 25 points is its own statement and the rest belongs to 4 function literals inside it that branch (lines 359, 299, 334, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · automock.automockModule (cyclomatic 25) · ×1
  • automock.automockModule (cyclomatic 25) code/core/src/mocking-utils/automock.ts:46 — automock.automockModule has cyclomatic complexity 25 (threshold 15). Of this number, 15 points are the body's own statements and 10 belong to 4 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · extract.extractMockCalls (cyclomatic 25) · ×1
  • extract.extractMockCalls (cyclomatic 25) code/core/src/mocking-utils/extract.ts:112 — extract.extractMockCalls has cyclomatic complexity 25 (threshold 15). Of this number, 15 points are the body's own statements and 10 belong to one function item inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · story-docs-markup.functionScope (cyclomatic 25) · ×1
  • story-docs-markup.functionScope (cyclomatic 25) code/frameworks/angular-vite/src/docgen/story-docs-markup.ts:551 — story-docs-markup.functionScope has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · preset.viteFinal (cyclomatic 25) · ×1
  • preset.viteFinal (cyclomatic 25) code/frameworks/angular-vite/src/preset.ts:81 — preset.viteFinal has cyclomatic complexity 25 (threshold 15). Of this number, 23 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · pipeline.runTransforms (cyclomatic 25) · ×1
  • pipeline.runTransforms (cyclomatic 25) code/lib/cli-storybook/src/automigrate/pipeline.ts:170 — pipeline.runTransforms has cyclomatic complexity 25 (threshold 15). Of this number, 19 points are the body's own statements and 6 belong to 4 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · snippet-imports.markupReferences (cyclomatic 25) · ×1
  • snippet-imports.markupReferences (cyclomatic 25) code/renderers/svelte/src/docgen/story-docs/snippet-imports.ts:171 — snippet-imports.markupReferences has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 12 of the 25 points are its own statements and the rest belongs to 4 function items inside it that branch (visitElement, read, a function literal at line 190, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · print-h.printProps (cyclomatic 25) · ×1
  • print-h.printProps (cyclomatic 25) code/renderers/vue3/src/docgen/story-docs/print-h/print-h.ts:300 — print-h.printProps has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · get-github-info.getPullInfoFromCommit (cyclomatic 25) · ×1
  • get-github-info.getPullInfoFromCommit (cyclomatic 25) scripts/release/utils/get-github-info.ts:175 — get-github-info.getPullInfoFromCommit has cyclomatic complexity 25 (threshold 15). Of this number, 19 points are the body's own statements and 6 belong to one function literal inside it that branches. This file's own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes — or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages.
D1 · Cyclomatic Complexity · Onboarding.Onboarding (cyclomatic 24) · ×1
  • Onboarding.Onboarding (cyclomatic 24) code/addons/onboarding/src/Onboarding.tsx:47 — Onboarding.Onboarding has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 7 of the 24 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 143, 72, 112, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · scope.analyzeScopes.enterScope (cyclomatic 24) · ×1
  • scope.analyzeScopes.enterScope (cyclomatic 24) code/core/src/csf-tools/estree/scope.ts:396 — scope.analyzeScopes.enterScope has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · CsfObjectDiscovery.discoverStories (cyclomatic 24) · ×1
  • CsfObjectDiscovery.discoverStories (cyclomatic 24) code/core/src/csf-tools/CsfObjectDiscovery.ts:594 — CsfObjectDiscovery.discoverStories has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 1 of the 24 points is its own statement and the rest belongs to one function literal inside it that branches (line 600). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · ComponentMetaManager.findMatchTSConfig (cyclomatic 24) · ×1
  • ComponentMetaManager.findMatchTSConfig (cyclomatic 24) code/core/src/component-meta/ComponentMetaManager.ts:139 — ComponentMetaManager.findMatchTSConfig has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 7 of the 24 points are its own statements and the rest belongs to 3 function items inside it that branch (getReferencesChains, findTSConfig, prepareClosestRootCommandLine). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · componentMetaExtractor.extractDefaultsFromSourceFile (cyclomatic 24) · ×1
  • componentMetaExtractor.extractDefaultsFromSourceFile (cyclomatic 24) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1612 — componentMetaExtractor.extractDefaultsFromSourceFile has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · componentMetaExtractor.findExportedFunction (cyclomatic 24) · ×1
  • componentMetaExtractor.findExportedFunction (cyclomatic 24) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1724 — componentMetaExtractor.findExportedFunction has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · NumericInput.NumericInput (cyclomatic 24) · ×1
  • NumericInput.NumericInput (cyclomatic 24) code/core/src/manager/components/preview/NumericInput.tsx:82 — NumericInput.NumericInput has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 8 of the 24 points are its own statements and the rest belongs to 8 function literals inside it that branch (lines 160, 111, 121, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · members.visitAccessorPair (cyclomatic 24) · ×1
  • members.visitAccessorPair (cyclomatic 24) code/lib/angular-cm/src/analyzer/members.ts:456 — members.visitAccessorPair has cyclomatic complexity 24 (threshold 15). Of this number, 21 points are the body's own statements and 3 belong to 3 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · generate-docgen.convertType (cyclomatic 24) · ×1
  • generate-docgen.convertType (cyclomatic 24) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts:73 — generate-docgen.convertType has cyclomatic complexity 24 (threshold 15). Of this number, 21 points are the body's own statements and 3 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · resolve-component.followExport (cyclomatic 24) · ×1
  • resolve-component.followExport (cyclomatic 24) code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts:69 — resolve-component.followExport has cyclomatic complexity 24 (threshold 15). Of this number, 19 points are the body's own statements and 5 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · named-type-detail.createNamedTypeDetailResolver (cyclomatic 24) · ×1
  • named-type-detail.createNamedTypeDetailResolver (cyclomatic 24) code/renderers/vue3/src/docgen/component-docgen/arg-types/named-type-detail.ts:35 — named-type-detail.createNamedTypeDetailResolver has cyclomatic complexity 24 (threshold 15). Most of this is not in the body itself: 3 of the 24 points are its own statements and the rest belongs to 7 function items inside it that branch (a function literal at line 126, a function literal at line 89, a function literal at line 112, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · compare-results.main (cyclomatic 23) · ×1
  • compare-results.main (cyclomatic 23) agent-eval/scripts/compare-results.ts:68 — compare-results.main has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Object.ObjectControl (cyclomatic 23) · ×1
  • Object.ObjectControl (cyclomatic 23) code/addons/docs/src/blocks/controls/Object.tsx:166 — Object.ObjectControl has cyclomatic complexity 23 (threshold 15). Of this number, 12 points are the body's own statements and 11 belong to 6 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · args.map (cyclomatic 23) · ×1
  • args.map (cyclomatic 23) code/core/src/preview-api/modules/store/args.ts:15 — args.map has cyclomatic complexity 23 (threshold 15). Of this number, 21 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · resolveViewport.resolveViewport (cyclomatic 23) · ×1
  • resolveViewport.resolveViewport (cyclomatic 23) code/core/src/viewport/resolveViewport.ts:43 — resolveViewport.resolveViewport has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · refs.init (cyclomatic 23) · ×1
  • refs.init (cyclomatic 23) code/core/src/manager-api/modules/refs.ts:195 — refs.init has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 4 of the 23 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 229, 325, 384). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · CsfObjectDiscovery.assignmentsOf (cyclomatic 23) · ×1
  • CsfObjectDiscovery.assignmentsOf (cyclomatic 23) code/core/src/csf-tools/CsfObjectDiscovery.ts:376 — CsfObjectDiscovery.assignmentsOf has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · run.dispatchTools (cyclomatic 23) · ×1
  • run.dispatchTools (cyclomatic 23) code/core/src/cli/tools/run.ts:258 — run.dispatchTools has cyclomatic complexity 23 (threshold 15). Of this number, 22 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · componentMetaExtractor.findImportSymbolInStoryFile (cyclomatic 23) · ×1
  • componentMetaExtractor.findImportSymbolInStoryFile (cyclomatic 23) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:242 — componentMetaExtractor.findImportSymbolInStoryFile has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · save-story.initializeSaveStory (cyclomatic 23) · ×1
  • save-story.initializeSaveStory (cyclomatic 23) code/core/src/core-server/utils/save-story/save-story.ts:33 — save-story.initializeSaveStory has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 34, 61). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · ShowChangesButton.ShowChangesButton (cyclomatic 23) · ×1
  • ShowChangesButton.ShowChangesButton (cyclomatic 23) code/core/src/manager/components/sidebar/ShowChangesButton.tsx:47 — ShowChangesButton.ShowChangesButton has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 10 of the 23 points are its own statements and the rest belongs to 7 function items inside it that branch (a function literal at line 59, a function literal at line 67, a function literal at line 68, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · parse.oxcParse (cyclomatic 23) · ×1
  • parse.oxcParse (cyclomatic 23) code/core/src/oxc-parser/parse.ts:20 — parse.oxcParse has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · helpers.getVariableMetasBySpecifier (cyclomatic 23) · ×1
  • helpers.getVariableMetasBySpecifier (cyclomatic 23) code/frameworks/nextjs/src/font/babel/helpers.ts:274 — helpers.getVariableMetasBySpecifier has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 283, 334). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · TypeIndex.render (cyclomatic 23) · ×1
  • TypeIndex.render (cyclomatic 23) code/lib/angular-cm/src/analyzer/type-index.ts:37 — TypeIndex.render has cyclomatic complexity 23 (threshold 15). Of this number, 20 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · extract-arg-types.extractArgTypesFromData (cyclomatic 23) · ×1
  • extract-arg-types.extractArgTypesFromData (cyclomatic 23) code/lib/angular-cm/src/extract-arg-types.ts:460 — extract-arg-types.extractArgTypesFromData has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 3 of the 23 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 478, 538, 563). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · generate-docgen.createDocgenProgram (cyclomatic 23) · ×1
  • generate-docgen.createDocgenProgram (cyclomatic 23) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts:379 — generate-docgen.createDocgenProgram has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · plugin.vitePluginNextImage.resolveId (cyclomatic 23) · ×1
  • plugin.vitePluginNextImage.resolveId (cyclomatic 23) code/lib/vite-plugin-storybook-nextjs/src/plugins/next-image/plugin.ts:94 — plugin.vitePluginNextImage.resolveId has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · sourceDecorator.generatePropsSourceCode (cyclomatic 23) · ×1
  • sourceDecorator.generatePropsSourceCode (cyclomatic 23) code/renderers/vue3/src/docgen/story-docs/source-decorator/sourceDecorator.ts:207 — sourceDecorator.generatePropsSourceCode has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 227, 307, 273). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · claude-code.logMessage (cyclomatic 23) · ×1
  • claude-code.logMessage (cyclomatic 23) scripts/eval/lib/agents/claude-code.ts:87 — claude-code.logMessage has cyclomatic complexity 23 (threshold 15). Of this number, 22 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · compare_stats.analyze (cyclomatic 23) · ×1
  • compare_stats.analyze (cyclomatic 23) agent-eval/scripts/compare_stats.py:148 — compare_stats.analyze has cyclomatic complexity 23 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · complexity-jsx.jsxCognitiveForSource (cyclomatic 22) · ×1
  • complexity-jsx.jsxCognitiveForSource (cyclomatic 22) agent-eval/lib/agentic-reference/metrics/complexity-jsx.ts:265 — complexity-jsx.jsxCognitiveForSource has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 2 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 272). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · resolve.resolveScopedName (cyclomatic 22) · ×1
  • resolve.resolveScopedName (cyclomatic 22) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/resolve.ts:64 — resolve.resolveScopedName has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · check-playground-routes.collectExports (cyclomatic 22) · ×1
  • check-playground-routes.collectExports (cyclomatic 22) agent-eval/scripts/check-playground-routes.mjs:94 — check-playground-routes.collectExports has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · TourGuide.TourGuide (cyclomatic 22) · ×1
  • TourGuide.TourGuide (cyclomatic 22) code/core/src/manager/components/TourGuide/TourGuide.tsx:71 — TourGuide.TourGuide has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 9 of the 22 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 151, 109, 128, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · storySort.storySort (cyclomatic 22) · ×1
  • storySort.storySort (cyclomatic 22) code/core/src/shared/story-index/storySort.ts:10 — storySort.storySort has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 1 of the 22 points is its own statement and the rest belongs to one function literal inside it that branches (line 11). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · patch-recorder.recordPatch · ×1
  • patch-recorder.recordPatch::wrap (cyclomatic 22) code/core/src/shared/open-service/patch-recorder.ts:183 — patch-recorder.recordPatch::wrap has cyclomatic complexity 22 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · render-components-manifest.renderComponentsManifest (cyclomatic 22) · ×1
  • render-components-manifest.renderComponentsManifest (cyclomatic 22) code/core/src/core-server/utils/manifests/render-components-manifest.ts:63 — render-components-manifest.renderComponentsManifest has cyclomatic complexity 22 (threshold 15). Of this number, 18 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · ChecklistWidget.ChecklistWidget (cyclomatic 22) · ×1
  • ChecklistWidget.ChecklistWidget (cyclomatic 22) code/core/src/manager/components/sidebar/ChecklistWidget.tsx:216 — ChecklistWidget.ChecklistWidget has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 5 of the 22 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 356, 240, 277, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · extract-arg-types.extractArgTypesFromData (cyclomatic 22) · ×1
  • extract-arg-types.extractArgTypesFromData (cyclomatic 22) code/lib/angular-compodoc/src/extract-arg-types.ts:456 — extract-arg-types.extractArgTypesFromData has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 3 of the 22 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 479, 530, 556). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · remove-unused-types.removeUnusedTypes (cyclomatic 22) · ×1
  • remove-unused-types.removeUnusedTypes (cyclomatic 22) code/lib/cli-storybook/src/codemod/helpers/remove-unused-types.ts:42 — remove-unused-types.removeUnusedTypes has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 3 of the 22 points are its own statements and the rest belongs to 3 function items inside it that branch (a function literal at line 60, markOwner, a function literal at line 92). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · multi-project.runAutomigrationsForProjects (cyclomatic 22) · ×1
  • multi-project.runAutomigrationsForProjects (cyclomatic 22) code/lib/cli-storybook/src/automigrate/multi-project.ts:320 — multi-project.runAutomigrationsForProjects has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · build-tag-index.buildTagIndex (cyclomatic 22) · ×1
  • build-tag-index.buildTagIndex (cyclomatic 22) code/renderers/web-components/src/docgen/component-docgen/manifest/build-tag-index.ts:6 — build-tag-index.buildTagIndex has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · generateCodeSnippet.functionSnippet (cyclomatic 22) · ×1
  • generateCodeSnippet.functionSnippet (cyclomatic 22) code/renderers/react/src/componentManifest/generateCodeSnippet.ts:176 — generateCodeSnippet.functionSnippet has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · ComponentMetaProject.extractPropsFromStories (cyclomatic 22) · ×1
  • ComponentMetaProject.extractPropsFromStories (cyclomatic 22) code/renderers/react/src/componentManifest/componentMeta/ComponentMetaProject.ts:168 — ComponentMetaProject.extractPropsFromStories has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · build-story-docs.snippetArg (cyclomatic 22) · ×1
  • build-story-docs.snippetArg (cyclomatic 22) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts:178 — build-story-docs.snippetArg has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · classify-value.isResolvable (cyclomatic 22) · ×1
  • classify-value.isResolvable (cyclomatic 22) code/renderers/vue3/src/docgen/shared/classify-value.ts:244 — classify-value.isResolvable has cyclomatic complexity 22 (threshold 15). Of this number, 16 points are the body's own statements and 6 belong to 2 function literals inside it that branch. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D1 · Cyclomatic Complexity · module-graph.recordDeclaration (cyclomatic 21) · ×1
  • module-graph.recordDeclaration (cyclomatic 21) agent-eval/lib/agentic-reference/metrics/ds-coverage/module-graph.ts:209 — module-graph.recordDeclaration has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · imports.setImport (cyclomatic 21) · ×1
  • imports.setImport (cyclomatic 21) code/core/src/csf-tools/estree/imports.ts:147 — imports.setImport has cyclomatic complexity 21 (threshold 15). Of this number, 14 points are the body's own statements and 7 belong to 3 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · access-provider.resolveComponentEntry (cyclomatic 21) · ×1
  • access-provider.resolveComponentEntry (cyclomatic 21) code/core/src/shared/open-service/toolsets/docs/access-provider.ts:317 — access-provider.resolveComponentEntry has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · eslintPlugin.configureFlatConfig (cyclomatic 21) · ×1
  • eslintPlugin.configureFlatConfig (cyclomatic 21) code/core/src/cli/eslintPlugin.ts:244 — eslintPlugin.configureFlatConfig has cyclomatic complexity 21 (threshold 15). Of this number, 16 points are the body's own statements and 5 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Button.Button (cyclomatic 21) · ×1
  • Button.Button (cyclomatic 21) code/core/src/components/components/Button/Button.tsx:60 — Button.Button has cyclomatic complexity 21 (threshold 15). Of this number, 17 points are the body's own statements and 4 belong to 3 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · dev-server.storybookDevServer (cyclomatic 21) · ×1
  • dev-server.storybookDevServer (cyclomatic 21) code/core/src/core-server/dev-server.ts:32 — dev-server.storybookDevServer has cyclomatic complexity 21 (threshold 15). Of this number, 18 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · Refs.Ref (cyclomatic 21) · ×1
  • Refs.Ref (cyclomatic 21) code/core/src/manager/components/sidebar/Refs.tsx:81 — Refs.Ref has cyclomatic complexity 21 (threshold 15). Of this number, 16 points are the body's own statements and 5 belong to 3 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · upgrade-deprecated-types.upgradeDeprecatedTypes (cyclomatic 21) · ×1
  • upgrade-deprecated-types.upgradeDeprecatedTypes (cyclomatic 21) code/lib/codemod/src/transforms/upgrade-deprecated-types.ts:57 — upgrade-deprecated-types.upgradeDeprecatedTypes has cyclomatic complexity 21 (threshold 15). Of this number, 13 points are the body's own statements and 8 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · argtypes.typeCurrentOrBetter (cyclomatic 21) · ×1
  • argtypes.typeCurrentOrBetter (cyclomatic 21) code/lib/docgen-harness/src/compare/argtypes.ts:243 — argtypes.typeCurrentOrBetter has cyclomatic complexity 21 (threshold 15). Of this number, 20 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · build-package.run (cyclomatic 21) · ×1
  • build-package.run (cyclomatic 21) scripts/build-package.ts:31 — build-package.run has cyclomatic complexity 21 (threshold 15). Of this number, 14 points are the body's own statements and 7 belong to 6 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · check-docs.checkBareUrls (cyclomatic 21) · ×1
  • check-docs.checkBareUrls (cyclomatic 21) scripts/docs/check-docs.ts:357 — check-docs.checkBareUrls has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · codemod.runSnippetCodemod (cyclomatic 21) · ×1
  • codemod.runSnippetCodemod (cyclomatic 21) scripts/snippets/codemod.ts:348 — codemod.runSnippetCodemod has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 4 of the 21 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 386, 423, 436). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · compare_stats.write_report (cyclomatic 21) · ×1
  • compare_stats.write_report (cyclomatic 21) agent-eval/scripts/compare_stats.py:408 — compare_stats.write_report has cyclomatic complexity 21 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · owner.ownerName (cyclomatic 20) · ×1
  • owner.ownerName (cyclomatic 20) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/owner.ts:24 — owner.ownerName has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Preview.Preview (cyclomatic 20) · ×1
  • Preview.Preview (cyclomatic 20) code/addons/docs/src/blocks/components/Preview.tsx:148 — Preview.Preview has cyclomatic complexity 20 (threshold 15). Of this number, 18 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · plugin.viteMockPlugin (cyclomatic 20) · ×1
  • plugin.viteMockPlugin (cyclomatic 20) code/builders/builder-vite/src/plugins/vite-mock/plugin.ts:41 — plugin.viteMockPlugin has cyclomatic complexity 20 (threshold 15). Of this number, 14 points are the body's own statements and 6 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · decorator.withBackgroundAndGrid (cyclomatic 20) · ×1
  • decorator.withBackgroundAndGrid (cyclomatic 20) code/core/src/backgrounds/decorator.ts:21 — decorator.withBackgroundAndGrid has cyclomatic complexity 20 (threshold 15). Of this number, 18 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · editor.printValue (cyclomatic 20) · ×1
  • editor.printValue (cyclomatic 20) code/core/src/csf-tools/estree/editor.ts:570 — editor.printValue has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · parse-react-docgen.serializeTsType (cyclomatic 20) · ×1
  • parse-react-docgen.serializeTsType (cyclomatic 20) code/core/src/shared/open-service/toolsets/docs/manifest-formatter/parse-react-docgen.ts:86 — parse-react-docgen.serializeTsType has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · eslintPlugin.findConfigHelperNames (cyclomatic 20) · ×1
  • eslintPlugin.findConfigHelperNames (cyclomatic 20) code/core/src/cli/eslintPlugin.ts:78 — eslintPlugin.findConfigHelperNames has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · render-components-manifest.renderSubcomponentNote (cyclomatic 20) · ×1
  • render-components-manifest.renderSubcomponentNote (cyclomatic 20) code/core/src/core-server/utils/manifests/render-components-manifest.ts:1313 — render-components-manifest.renderSubcomponentNote has cyclomatic complexity 20 (threshold 15). Of this number, 19 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · esmWalker.isRefIdentifier (cyclomatic 20) · ×1
  • esmWalker.isRefIdentifier (cyclomatic 20) code/core/src/mocking-utils/esmWalker.ts:252 — esmWalker.isRefIdentifier has cyclomatic complexity 20 (threshold 15). This file's own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes — or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages.
D1 · Cyclomatic Complexity · parse.collectRequireSpecifiers (cyclomatic 20) · ×1
  • parse.collectRequireSpecifiers (cyclomatic 20) code/core/src/oxc-parser/parse.ts:185 — parse.collectRequireSpecifiers has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · addon-svelte-csf-to-core.storyTagAttributes (cyclomatic 20) · ×1
  • addon-svelte-csf-to-core.storyTagAttributes (cyclomatic 20) code/lib/cli-storybook/src/automigrate/fixes/addon-svelte-csf-to-core.ts:56 — addon-svelte-csf-to-core.storyTagAttributes has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · metroConfig.hasWithStorybookBinding (cyclomatic 20) · ×1
  • metroConfig.hasWithStorybookBinding (cyclomatic 20) code/lib/create-storybook/src/generators/REACT_NATIVE/metroConfig.ts:133 — metroConfig.hasWithStorybookBinding has cyclomatic complexity 20 (threshold 15). Of this number, 18 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · initiate.doInitiate (cyclomatic 20) · ×1
  • initiate.doInitiate (cyclomatic 20) code/lib/create-storybook/src/initiate.ts:74 — initiate.doInitiate has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · argtypes.splitTopLevelUnion (cyclomatic 20) · ×1
  • argtypes.splitTopLevelUnion (cyclomatic 20) code/lib/docgen-harness/src/compare/argtypes.ts:455 — argtypes.splitTopLevelUnion has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · post-analysis.summarize (cyclomatic 19) · ×1
  • post-analysis.summarize (cyclomatic 19) agent-eval/lib/agentic-reference/post-analysis.ts:577 — post-analysis.summarize has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · CsfFile._parseMeta (cyclomatic 19) · ×1
  • CsfFile._parseMeta (cyclomatic 19) REDACTED:731 — CsfFile._parseMeta has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · CsfFile._visitExpressionStatement (cyclomatic 19) · ×1
  • CsfFile._visitExpressionStatement (cyclomatic 19) REDACTED:1081 — CsfFile._visitExpressionStatement has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · markdown.formatComponentManifest (cyclomatic 19) · ×1
  • markdown.formatComponentManifest (cyclomatic 19) code/core/src/shared/open-service/toolsets/docs/manifest-formatter/markdown.ts:353 — markdown.formatComponentManifest has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · summarizeIndex.summarizeIndex (cyclomatic 19) · ×1
  • summarizeIndex.summarizeIndex (cyclomatic 19) code/core/src/core-server/utils/summarizeIndex.ts:28 — summarizeIndex.summarizeIndex has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 43, 89). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · componentMetaExtractor.unwrapToFunction (cyclomatic 19) · ×1
  • componentMetaExtractor.unwrapToFunction (cyclomatic 19) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:759 — componentMetaExtractor.unwrapToFunction has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · render-components-manifest.serializeTsType (cyclomatic 19) · ×1
  • render-components-manifest.serializeTsType (cyclomatic 19) code/core/src/core-server/utils/manifests/render-components-manifest.ts:1472 — render-components-manifest.serializeTsType has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · duplicate-story-with-new-name.duplicateStoryWithNewName (cyclomatic 19) · ×1
  • duplicate-story-with-new-name.duplicateStoryWithNewName (cyclomatic 19) code/core/src/core-server/utils/save-story/duplicate-story-with-new-name.ts:9 — duplicate-story-with-new-name.duplicateStoryWithNewName has cyclomatic complexity 19 (threshold 15). Of this number, 14 points are the body's own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · Menu.useMenu (cyclomatic 19) · ×1
  • Menu.useMenu (cyclomatic 19) code/core/src/manager/container/Menu.tsx:32 — Menu.useMenu has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to 12 function literals inside it that branch (lines 217, 95, 108, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · inheritance.instantiateProperty (cyclomatic 19) · ×1
  • inheritance.instantiateProperty (cyclomatic 19) code/lib/angular-cm/src/analyzer/inheritance.ts:171 — inheritance.instantiateProperty has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · analyze-file.analyzeSourceFile (cyclomatic 19) · ×1
  • analyze-file.analyzeSourceFile (cyclomatic 19) code/lib/angular-cm/src/analyzer/analyze-file.ts:24 — analyze-file.analyzeSourceFile has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · svelte-csf-to-csf-factory.transformModuleScript (cyclomatic 19) · ×1
  • svelte-csf-to-csf-factory.transformModuleScript (cyclomatic 19) code/lib/cli-storybook/src/codemod/helpers/svelte-csf-to-csf-factory.ts:132 — svelte-csf-to-csf-factory.transformModuleScript has cyclomatic complexity 19 (threshold 15). Of this number, 14 points are the body's own statements and 5 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · index.displayDoctorResults (cyclomatic 19) · ×1
  • index.displayDoctorResults (cyclomatic 19) code/lib/cli-storybook/src/doctor/index.ts:61 — index.displayDoctorResults has cyclomatic complexity 19 (threshold 15). Of this number, 13 points are the body's own statements and 6 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · generate-docgen.initializerToDefaultValue (cyclomatic 19) · ×1
  • generate-docgen.initializerToDefaultValue (cyclomatic 19) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts:155 — generate-docgen.initializerToDefaultValue has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · classify-args.classifyArg (cyclomatic 19) · ×1
  • classify-args.classifyArg (cyclomatic 19) code/renderers/vue3/src/docgen/story-docs/classify-args/classify-args.ts:127 — classify-args.classifyArg has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · check-package.run (cyclomatic 19) · ×1
  • check-package.run (cyclomatic 19) scripts/check-package.ts:20 — check-package.run has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 7 of the 19 points are its own statements and the rest belongs to 8 function items inside it that branch (runAllChecks, a function literal at line 24, a function literal at line 36, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · sandbox-parts.addStories (cyclomatic 19) · ×1
  • sandbox-parts.addStories (cyclomatic 19) scripts/tasks/sandbox-parts.ts:713 — sandbox-parts.addStories has cyclomatic complexity 19 (threshold 15). Of this number, 13 points are the body's own statements and 6 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · codemod.transformSvelteCsfNextFile (cyclomatic 19) · ×1
  • codemod.transformSvelteCsfNextFile (cyclomatic 19) scripts/snippets/codemod.ts:196 — codemod.transformSvelteCsfNextFile has cyclomatic complexity 19 (threshold 15). Of this number, 15 points are the body's own statements and 4 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · handleFormInput (cyclomatic 19) · ×1
  • handleFormInput (cyclomatic 19) agent-eval/lib/mcp/claude-browser-mock.mjs:1569 — handleFormInput has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 6 of the 19 points are its own statements and the rest belongs to 3 function items inside it that branch (a function literal at line 1573, (anonymous)::setNative, a function literal at line 1590). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · complexity-cyclomatic.nameOfFunctionLike (cyclomatic 18) · ×1
  • complexity-cyclomatic.nameOfFunctionLike (cyclomatic 18) agent-eval/lib/agentic-reference/metrics/complexity-cyclomatic.ts:43 — complexity-cyclomatic.nameOfFunctionLike has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · churn.computeChurn (cyclomatic 18) · ×1
  • churn.computeChurn (cyclomatic 18) agent-eval/lib/agentic-reference/metrics/churn.ts:170 — churn.computeChurn has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · A11YPanel.A11YPanel (cyclomatic 18) · ×1
  • A11YPanel.A11YPanel (cyclomatic 18) code/addons/a11y/src/components/A11YPanel.tsx:56 — A11YPanel.A11YPanel has cyclomatic complexity 18 (threshold 15). Of this number, 15 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · Color.ColorControl (cyclomatic 18) · ×1
  • Color.ColorControl (cyclomatic 18) code/addons/docs/src/blocks/controls/Color.tsx:367 — Color.ColorControl has cyclomatic complexity 18 (threshold 15). Of this number, 14 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · Description.Description (cyclomatic 18) · ×1
  • Description.Description (cyclomatic 18) code/addons/vitest/src/components/Description.tsx:31 — Description.Description has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · add.add (cyclomatic 18) · ×1
  • add.add (cyclomatic 18) code/lib/cli-storybook/src/add.ts:87 — add.add has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · ToolbarMenuSelect.ToolbarMenuSelect (cyclomatic 18) · ×1
  • ToolbarMenuSelect.ToolbarMenuSelect (cyclomatic 18) code/core/src/toolbar/components/ToolbarMenuSelect.tsx:28 — ToolbarMenuSelect.ToolbarMenuSelect has cyclomatic complexity 18 (threshold 15). Of this number, 12 points are the body's own statements and 6 belong to 4 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · DocsContext.resolveModuleExport (cyclomatic 18) · ×1
  • DocsContext.resolveModuleExport (cyclomatic 18) code/core/src/preview-api/modules/preview-web/docs-context/DocsContext.ts:162 — DocsContext.resolveModuleExport has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · resolve-members.declaredMembers (cyclomatic 18) · ×1
  • resolve-members.declaredMembers (cyclomatic 18) code/core/src/csf-tools/story-shape/resolve-members.ts:521 — resolve-members.declaredMembers has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · index._processAndSend (cyclomatic 18) · ×1
  • index._processAndSend (cyclomatic 18) code/core/src/telemetry/index.ts:149 — index._processAndSend has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · MatcherResult.MatcherResult (cyclomatic 18) · ×1
  • MatcherResult.MatcherResult (cyclomatic 18) code/core/src/component-testing/components/MatcherResult.tsx:56 — MatcherResult.MatcherResult has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 1 of the 18 points is its own statement and the rest belongs to one function literal inside it that branches (line 74). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · componentMetaExtractor.unwrapToFunctionAST (cyclomatic 18) · ×1
  • componentMetaExtractor.unwrapToFunctionAST (cyclomatic 18) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1802 — componentMetaExtractor.unwrapToFunctionAST has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · ContextMenu.ContextMenu (cyclomatic 18) · ×1
  • ContextMenu.ContextMenu (cyclomatic 18) code/core/src/manager/components/sidebar/ContextMenu.tsx:95 — ContextMenu.ContextMenu has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 8 of the 18 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 111, 138). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · jsx-pragma.jsxPragma (cyclomatic 18) · ×1
  • jsx-pragma.jsxPragma (cyclomatic 18) code/frameworks/nextjs/src/babel/plugins/jsx-pragma.ts:14 — jsx-pragma.jsxPragma has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · duplicate-tree.resolveStoryLeaf (cyclomatic 18) · ×1
  • duplicate-tree.resolveStoryLeaf (cyclomatic 18) code/frameworks/tanstack-react/src/routing/duplicate-tree.ts:232 — duplicate-tree.resolveStoryLeaf has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · server-code-elimination.eliminateDeadCode (cyclomatic 18) · ×1
  • server-code-elimination.eliminateDeadCode (cyclomatic 18) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts:449 — server-code-elimination.eliminateDeadCode has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · util.generateUpgradeSpecs (cyclomatic 18) · ×1
  • util.generateUpgradeSpecs (cyclomatic 18) code/lib/cli-storybook/src/util.ts:434 — util.generateUpgradeSpecs has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 7 of the 18 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 454, 491, 485). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · baseGenerator.baseGenerator (cyclomatic 18) · ×1
  • baseGenerator.baseGenerator (cyclomatic 18) code/lib/create-storybook/src/generators/baseGenerator.ts:132 — baseGenerator.baseGenerator has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · metroConfig.transformMetroConfigSource (cyclomatic 18) · ×1
  • metroConfig.transformMetroConfigSource (cyclomatic 18) code/lib/create-storybook/src/generators/REACT_NATIVE/metroConfig.ts:210 — metroConfig.transformMetroConfigSource has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · extractArgTypes.convertVueComponentMetaProp (cyclomatic 18) · ×1
  • extractArgTypes.convertVueComponentMetaProp (cyclomatic 18) code/renderers/vue3/src/docgen/component-docgen/arg-types/extractArgTypes.ts:205 — extractArgTypes.convertVueComponentMetaProp has cyclomatic complexity 18 (threshold 15). Of this number, 16 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · forward-setup.collectArgsReads (cyclomatic 18) · ×1
  • forward-setup.collectArgsReads (cyclomatic 18) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts:268 — forward-setup.collectArgsReads has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 3 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 276). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · template-holes.resolveHoleValue (cyclomatic 18) · ×1
  • template-holes.resolveHoleValue (cyclomatic 18) code/renderers/web-components/src/docgen/story-docs/template-holes.ts:39 — template-holes.resolveHoleValue has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · build-story-docs.argsSnippet (cyclomatic 18) · ×1
  • build-story-docs.argsSnippet (cyclomatic 18) code/renderers/web-components/src/docgen/story-docs/build-story-docs.ts:290 — build-story-docs.argsSnippet has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · complexity-cognitive.nameOfFunctionLike (cyclomatic 17) · ×1
  • complexity-cognitive.nameOfFunctionLike (cyclomatic 17) agent-eval/lib/agentic-reference/metrics/complexity-cognitive.ts:34 — complexity-cognitive.nameOfFunctionLike has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · complexity-jsx.nameOfFunctionLike (cyclomatic 17) · ×1
  • complexity-jsx.nameOfFunctionLike (cyclomatic 17) agent-eval/lib/agentic-reference/metrics/complexity-jsx.ts:59 — complexity-jsx.nameOfFunctionLike has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · judge-ds-misuse.main (cyclomatic 17) · ×1
  • judge-ds-misuse.main (cyclomatic 17) agent-eval/scripts/judge-ds-misuse.ts:314 — judge-ds-misuse.main has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · preview.afterEach (cyclomatic 17) · ×1
  • preview.afterEach (cyclomatic 17) code/addons/a11y/src/preview.tsx:14 — preview.afterEach has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · inferControls.inferControl (cyclomatic 17) · ×1
  • inferControls.inferControl (cyclomatic 17) code/core/src/preview-api/modules/store/inferControls.ts:26 — inferControls.inferControl has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · wrap-utils.wrapTextForClackHint (cyclomatic 17) · ×1
  • wrap-utils.wrapTextForClackHint (cyclomatic 17) code/core/src/node-logger/wrap-utils.ts:218 — wrap-utils.wrapTextForClackHint has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · JsPackageManagerFactory.getPackageManagerType (cyclomatic 17) · ×1
  • JsPackageManagerFactory.getPackageManagerType (cyclomatic 17) code/core/src/common/js-package-manager/JsPackageManagerFactory.ts:57 — JsPackageManagerFactory.getPackageManagerType has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · CsfFile._visitCallExpression (cyclomatic 17) · ×1
  • CsfFile._visitCallExpression (cyclomatic 17) REDACTED:1142 — CsfFile._visitCallExpression has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · resolve-members.assignedMembers (cyclomatic 17) · ×1
  • resolve-members.assignedMembers (cyclomatic 17) code/core/src/csf-tools/story-shape/resolve-members.ts:695 — resolve-members.assignedMembers has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · child-client.spawnChildHost (cyclomatic 17) · ×1
  • child-client.spawnChildHost (cyclomatic 17) code/core/src/cli/tools/sdk/child-client.ts:73 — child-client.spawnChildHost has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 8 of the 17 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 174, 147, 160). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · StatelessTabList.StatelessTabList (cyclomatic 17) · ×1
  • StatelessTabList.StatelessTabList (cyclomatic 17) code/core/src/components/components/Tabs/StatelessTabList.tsx:66 — StatelessTabList.StatelessTabList has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 4 of the 17 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 129, 74, 102, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · componentMetaExtractor.resolvePropsFromStoryFile · ×1
  • componentMetaExtractor.resolvePropsFromStoryFile::visit (cyclomatic 17) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:412 — componentMetaExtractor.resolvePropsFromStoryFile::visit has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · render-components-manifest.renderDocCard (cyclomatic 17) · ×1
  • render-components-manifest.renderDocCard (cyclomatic 17) code/core/src/core-server/utils/manifests/render-components-manifest.ts:906 — render-components-manifest.renderDocCard has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · previewThumbnailState.thumbnailReducer (cyclomatic 17) · ×1
  • previewThumbnailState.thumbnailReducer (cyclomatic 17) code/core/src/manager/components/review/components/previewThumbnailState.ts:45 — previewThumbnailState.thumbnailReducer has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · createType.createType (cyclomatic 17) · ×1
  • createType.createType (cyclomatic 17) code/renderers/react/src/docs/propTypes/createType.ts:358 — createType.createType has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · next-swc-loader-patch.loaderTransform (cyclomatic 17) · ×1
  • next-swc-loader-patch.loaderTransform (cyclomatic 17) code/frameworks/nextjs/src/swc/next-swc-loader-patch.ts:54 — next-swc-loader-patch.loaderTransform has cyclomatic complexity 17 (threshold 15). Of this number, 13 points are the body's own statements and 4 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · input-transform.analyzeInputTransform (cyclomatic 17) · ×1
  • input-transform.analyzeInputTransform (cyclomatic 17) code/lib/angular-cm/src/analyzer/input-transform.ts:17 — input-transform.analyzeInputTransform has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · vitest-setup-file.countReferences (cyclomatic 17) · ×1
  • vitest-setup-file.countReferences (cyclomatic 17) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:544 — vitest-setup-file.countReferences has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to one function literal inside it that branches (line 550). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · argtypes.compareArgTypes (cyclomatic 17) · ×1
  • argtypes.compareArgTypes (cyclomatic 17) code/lib/docgen-harness/src/compare/argtypes.ts:39 — argtypes.compareArgTypes has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · parse-type-text.parseTypeText (cyclomatic 17) · ×1
  • parse-type-text.parseTypeText (cyclomatic 17) code/renderers/web-components/src/docgen/component-docgen/arg-types/parse-type-text.ts:31 — parse-type-text.parseTypeText has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · parse-type-text.splitTopLevel (cyclomatic 17) · ×1
  • parse-type-text.splitTopLevel (cyclomatic 17) code/renderers/web-components/src/docgen/component-docgen/arg-types/parse-type-text.ts:189 — parse-type-text.splitTopLevel has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · import-source.findMeta (cyclomatic 17) · ×1
  • import-source.findMeta (cyclomatic 17) code/renderers/svelte/src/svelte-csf/utils/import-source.ts:76 — import-source.findMeta has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · extractArgTypes.extractFromVueDocgenApi (cyclomatic 17) · ×1
  • extractArgTypes.extractFromVueDocgenApi (cyclomatic 17) code/renderers/vue3/src/docgen/component-docgen/arg-types/extractArgTypes.ts:74 — extractArgTypes.extractFromVueDocgenApi has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · arg-values.evaluate (cyclomatic 17) · ×1
  • arg-values.evaluate (cyclomatic 17) code/renderers/web-components/src/docgen/story-docs/arg-values.ts:46 — arg-values.evaluate has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · html-tree.parseAttributes (cyclomatic 17) · ×1
  • html-tree.parseAttributes (cyclomatic 17) code/renderers/web-components/src/docgen/story-docs/html-tree.ts:176 — html-tree.parseAttributes has cyclomatic complexity 17 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline.
D1 · Cyclomatic Complexity · version.optionsSchema (cyclomatic 17) · ×1
  • version.optionsSchema (cyclomatic 17) scripts/release/version.ts:54 — version.optionsSchema has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · getWebpackConfig (cyclomatic 17) · ×1
  • getWebpackConfig (cyclomatic 17) code/frameworks/angular/src/server/angular-cli-webpack.js:31 — getWebpackConfig has cyclomatic complexity 17 (threshold 15). Of this number, 9 points are the body's own statements and 8 belong to 13 function items inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · complexity-cognitive.cognitiveForSource · ×1
  • complexity-cognitive.cognitiveForSource::measure::walk (cyclomatic 16) agent-eval/lib/agentic-reference/metrics/complexity-cognitive.ts:127 — complexity-cognitive.cognitiveForSource::measure::walk has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · shell-segments.splitCommandSegments (cyclomatic 16) · ×1
  • shell-segments.splitCommandSegments (cyclomatic 16) agent-eval/lib/utils/shell-segments.ts:44 — shell-segments.splitCommandSegments has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · resolve.styledTargetOf (cyclomatic 16) · ×1
  • resolve.styledTargetOf (cyclomatic 16) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/resolve.ts:155 — resolve.styledTargetOf has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · tool-taxonomy.classifySegmentTokens (cyclomatic 16) · ×1
  • tool-taxonomy.classifySegmentTokens (cyclomatic 16) agent-eval/lib/agentic-reference/metrics/tool-taxonomy.ts:209 — tool-taxonomy.classifySegmentTokens has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · claude-browser-mock.handleResizeWindow (cyclomatic 16) · ×1
  • claude-browser-mock.handleResizeWindow (cyclomatic 16) agent-eval/lib/mcp/claude-browser-mock.mjs:1803 — claude-browser-mock.handleResizeWindow has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · a11yRunner.run (cyclomatic 16) · ×1
  • a11yRunner.run (cyclomatic 16) code/addons/a11y/src/a11yRunner.ts:84 — a11yRunner.run has cyclomatic complexity 16 (threshold 15). Of this number, 12 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · Source.useCode (cyclomatic 16) · ×1
  • Source.useCode (cyclomatic 16) code/addons/docs/src/blocks/blocks/Source.tsx:67 — Source.useCode has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · hooks.useHook (cyclomatic 16) · ×1
  • hooks.useHook (cyclomatic 16) code/core/src/preview-api/modules/addons/hooks.ts:244 — hooks.useHook has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · animation-utils.pauseAnimations (cyclomatic 16) · ×1
  • animation-utils.pauseAnimations (cyclomatic 16) code/core/src/preview-api/modules/preview-web/render/animation-utils.ts:18 — animation-utils.pauseAnimations has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 4 of the 16 points are its own statements and the rest belongs to 3 function items inside it that branch (pauseAllAnimations, a function literal at line 70, a function literal at line 38). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · CsfObjectPath.locate (cyclomatic 16) · ×1
  • CsfObjectPath.locate (cyclomatic 16) code/core/src/csf-tools/CsfObjectPath.ts:124 — CsfObjectPath.locate has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · resolve-members.exportedBinding (cyclomatic 16) · ×1
  • resolve-members.exportedBinding (cyclomatic 16) code/core/src/csf-tools/story-shape/resolve-members.ts:788 — resolve-members.exportedBinding has cyclomatic complexity 16 (threshold 15). Of this number, 13 points are the body's own statements and 3 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · resolve-meta-component.createMetaComponentResolver (cyclomatic 16) · ×1
  • resolve-meta-component.createMetaComponentResolver (cyclomatic 16) code/core/src/common/utils/resolve-meta-component.ts:54 — resolve-meta-component.createMetaComponentResolver has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 5 function items inside it that branch (a function literal at line 93, fromIdentifier, resolveFile, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D1 · Cyclomatic Complexity · sync-main-preview-addons.syncPreviewAddonsWithMainConfig (cyclomatic 16) · ×1
  • sync-main-preview-addons.syncPreviewAddonsWithMainConfig (cyclomatic 16) code/core/src/common/utils/sync-main-preview-addons.ts:31 — sync-main-preview-addons.syncPreviewAddonsWithMainConfig has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · eslintPlugin.findConfigTarget (cyclomatic 16) · ×1
  • eslintPlugin.findConfigTarget (cyclomatic 16) code/core/src/cli/eslintPlugin.ts:121 — eslintPlugin.findConfigTarget has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · ComponentMetaManager.watchProgramSourceDirs (cyclomatic 16) · ×1
  • ComponentMetaManager.watchProgramSourceDirs (cyclomatic 16) code/core/src/component-meta/ComponentMetaManager.ts:405 — ComponentMetaManager.watchProgramSourceDirs has cyclomatic complexity 16 (threshold 15). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline.
D1 · Cyclomatic Complexity · InteractionsPanel.InteractionsPanel (cyclomatic 16) · ×1
  • InteractionsPanel.InteractionsPanel (cyclomatic 16) REDACTED:122 — InteractionsPanel.InteractionsPanel has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D1 · Cyclomatic Complexity · TabList.TabList (cyclomatic 16) · ×1
  • TabList.TabList (cyclomatic 16) code/core/src/components/components/Tabs/TabList.tsx:150 — TabList.TabList has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 219, 164, 192, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · StoryIndexGenerator.extractDocs (cyclomatic 16) · ×1
  • StoryIndexGenerator.extractDocs (cyclomatic 16) code/core/src/core-server/utils/StoryIndexGenerator.ts:527 — StoryIndexGenerator.extractDocs has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · StoryIndexGenerator.chooseDuplicate (cyclomatic 16) · ×1
  • StoryIndexGenerator.chooseDuplicate (cyclomatic 16) code/core/src/core-server/utils/StoryIndexGenerator.ts:649 — StoryIndexGenerator.chooseDuplicate has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · component-transformer.componentTransform (cyclomatic 16) · ×1
  • component-transformer.componentTransform (cyclomatic 16) code/core/src/csf-tools/vitest-plugin/component-transformer.ts:214 — component-transformer.componentTransform has cyclomatic complexity 16 (threshold 15). Of this number, 9 points are the body's own statements and 7 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · Instrumenter.invoke · ×1
  • Instrumenter.invoke::serializeValues (cyclomatic 16) code/core/src/instrumenter/instrumenter.ts:498 — Instrumenter.invoke::serializeValues has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · usePreviewThumbnail.usePreviewThumbnail (cyclomatic 16) · ×1
  • usePreviewThumbnail.usePreviewThumbnail (cyclomatic 16) REDACTED:74 — usePreviewThumbnail.usePreviewThumbnail has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 9 function literals inside it that branch (lines 91, 184, 175, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · SearchResults.SearchResults (cyclomatic 16) · ×1
  • SearchResults.SearchResults (cyclomatic 16) code/core/src/manager/components/sidebar/SearchResults.tsx:229 — SearchResults.SearchResults has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 5 of the 16 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 242, 261, 310). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D1 · Cyclomatic Complexity · decorators.readMetadataInputsOutputs (cyclomatic 16) · ×1
  • decorators.readMetadataInputsOutputs (cyclomatic 16) code/lib/angular-cm/src/analyzer/decorators.ts:171 — decorators.readMetadataInputsOutputs has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · multi-project.collectAutomigrationsAcrossProjects (cyclomatic 16) · ×1
  • multi-project.collectAutomigrationsAcrossProjects (cyclomatic 16) code/lib/cli-storybook/src/automigrate/multi-project.ts:60 — multi-project.collectAutomigrationsAcrossProjects has cyclomatic complexity 16 (threshold 15). Of this number, 13 points are the body's own statements and 3 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · build-story-docs.buildStoryDocsPayload (cyclomatic 16) · ×1
  • build-story-docs.buildStoryDocsPayload (cyclomatic 16) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts:34 — build-story-docs.buildStoryDocsPayload has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · build-story-docs.storySnippet (cyclomatic 16) · ×1
  • build-story-docs.storySnippet (cyclomatic 16) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts:109 — build-story-docs.storySnippet has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · transform-template.transformElement (cyclomatic 16) · ×1
  • transform-template.transformElement (cyclomatic 16) code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:386 — transform-template.transformElement has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
D1 · Cyclomatic Complexity · result-docs.normalizeTranscriptEntry (cyclomatic 16) · ×1
  • result-docs.normalizeTranscriptEntry (cyclomatic 16) scripts/eval/lib/result-docs.ts:128 — result-docs.normalizeTranscriptEntry has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D1 · Cyclomatic Complexity · sandbox-parts.init (cyclomatic 16) · ×1
  • sandbox-parts.init (cyclomatic 16) scripts/tasks/sandbox-parts.ts:283 — sandbox-parts.init has cyclomatic complexity 16 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Where every arm is uniform — the same kind of value, with no behaviour of its own — a table keyed by the case is the shorter form; wherever the arms carry different data or different behaviour, keep them as cases, because collapsing those trades an explicit, reviewable set of cases for nothing.
D10 · Test Quality · Fixed-sleep synchronisation · ×1
  • Fixed-sleep synchronisation: waits for each preset import to settle before importing the next, so CJS presets can require() ESM entries code/core/src/common/presets.test.ts:805 — This test starts work it did not wait for (`presetsPromise`, still running when the sleep starts) and then orders itself against it with `new Promise((resolve) => setTimeout(resolve, 0))` — a fixed wait, not a signal that the work is done. Whether it passes depends on how loaded the machine is, which is why a test written this way is green on a developer's box and random in CI. Wait for the event itself instead: the process's own exit or output, a completion handle, or a condition polled to a timeout.
D12 · Dependency Hygiene · Floating npm dependency · ×1
  • Floating npm dependency: vite — `vite` is declared as `>=8.0.0` in code/frameworks/angular-vite/package.json, which names no releasable version: `>=8.0.0` is an open range with no upper bound on the major. A production dependency that cannot be resolved to one immutable release makes the build non-reproducible — two installs a day apart can ship different code — and leaves nothing for a vulnerability scanner to match against.
D2 · Cognitive Complexity · html-report.buildEffects (cognitive 193) · ×1
  • html-report.buildEffects (cognitive 193) agent-eval/lib/agentic-reference/comparison/html-report.ts:1311 — html-report.buildEffects has cognitive complexity 193 (threshold 15). Drivers by points: ternaries 33 (134 pts), if/else 12 (39 pts), loops 6 (16 pts), boolean chains 4 (nesting depth added 138). Of this number, 89 points are the body's own statements and 104 belong to 6 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CsfFile._visitExportNamed (cognitive 133) · ×1
  • CsfFile._visitExportNamed (cognitive 133) REDACTED:891 — CsfFile._visitExportNamed has cognitive complexity 133 (threshold 15). Drivers by points: if/else 36 (98 pts), boolean chains 16, loops 4 (13 pts), ternaries 2 (6 pts) (nesting depth added 75). Of this number, 132 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · story-to-csf-factory.storyToCsfFactory (cognitive 108) · ×1
  • story-to-csf-factory.storyToCsfFactory (cognitive 108) code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.ts:83 — story-to-csf-factory.storyToCsfFactory has cognitive complexity 108 (threshold 15). Drivers by points: if/else 45 (75 pts), boolean chains 22, ternaries 4 (7 pts), error handling 2, loops 2 (nesting depth added 33). Of this number, 48 points are the body's own statements and 60 belong to 9 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · render-components-manifest.renderComponentCard (cognitive 99) · ×1
  • render-components-manifest.renderComponentCard (cognitive 99) code/core/src/core-server/utils/manifests/render-components-manifest.ts:973 — render-components-manifest.renderComponentCard has cognitive complexity 99 (threshold 15). Drivers by points: ternaries 61 (95 pts), boolean chains 4 (nesting depth added 34). Of this number, 61 points are the body's own statements and 38 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ConfigFile.parse (cognitive 92) · ×1
  • ConfigFile.parse (cognitive 92) code/core/src/csf-tools/ConfigFile.ts:538 — ConfigFile.parse has cognitive complexity 92 (threshold 15). Drivers by points: if/else 24 (57 pts), ternaries 3 (15 pts), loops 4 (12 pts), boolean chains 8 (nesting depth added 53). None of this is in the body itself: all 92 points belong to one function literal inside it that branches (line 539). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · scope.analyzeScopes.visitNode (cognitive 91) · ×1
  • scope.analyzeScopes.visitNode (cognitive 91) code/core/src/csf-tools/estree/scope.ts:569 — scope.analyzeScopes.visitNode has cognitive complexity 91 (threshold 15). Drivers by points: if/else 33 (60 pts), loops 10 (22 pts), boolean chains 5, ternaries 1 (3 pts), match/switch 1 (nesting depth added 41). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ConfigObject.locateConfigRoot (cognitive 84) · ×1
  • ConfigObject.locateConfigRoot (cognitive 84) code/core/src/csf-tools/ConfigObject.ts:78 — ConfigObject.locateConfigRoot has cognitive complexity 84 (threshold 15). Drivers by points: if/else 20 (43 pts), boolean chains 27, loops 6 (9 pts), ternaries 3 (5 pts) (nesting depth added 28). Of this number, 71 points are the body's own statements and 13 belong to 6 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Tree.Tree (cognitive 83) · ×1
  • Tree.Tree (cognitive 83) code/core/src/manager/components/sidebar/Tree.tsx:118 — Tree.Tree has cognitive complexity 83 (threshold 15). Drivers by points: if/else 39 (42 pts), boolean chains 22, ternaries 14 (16 pts), loops 3 (nesting depth added 5). Most of this is not in the body itself: 2 of the 83 points are its own statements and the rest belongs to 28 function literals inside it that branch (lines 560, 357, 233, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · Select.Select (cognitive 82) · ×1
  • Select.Select (cognitive 82) code/core/src/components/components/Select/Select.tsx:205 — Select.Select has cognitive complexity 82 (threshold 15). Drivers by points: if/else 39 (43 pts), boolean chains 24, ternaries 11 (15 pts) (nesting depth added 8). Most of this is not in the body itself: 15 of the 82 points are its own statements and the rest belongs to 20 function literals inside it that branch (lines 406, 452, 352, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · upgrade.upgrade (cognitive 80) · ×1
  • upgrade.upgrade (cognitive 80) code/lib/cli-storybook/src/upgrade.ts:352 — upgrade.upgrade has cognitive complexity 80 (threshold 15). Drivers by points: if/else 28 (42 pts), boolean chains 13, error handling 3 (9 pts), ternaries 4 (9 pts), loops 4 (7 pts) (nesting depth added 28). Of this number, 69 points are the body's own statements and 11 belong to 4 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Editor.groupValues (cognitive 79) · ×1
  • Editor.groupValues (cognitive 79) code/core/src/csf-tools/CsfObject.ts:692 — Editor.groupValues has cognitive complexity 79 (threshold 15). Drivers by points: if/else 24 (45 pts), ternaries 7 (20 pts), boolean chains 8, loops 4 (6 pts) (nesting depth added 36). Of this number, 76 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · component-transformer.collectComponentExports (cognitive 72) · ×1
  • component-transformer.collectComponentExports (cognitive 72) code/core/src/csf-tools/vitest-plugin/component-transformer.ts:94 — component-transformer.collectComponentExports has cognitive complexity 72 (threshold 15). Drivers by points: if/else 20 (53 pts), boolean chains 11, loops 3 (8 pts) (nesting depth added 38). Of this number, 69 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · postinstall.postInstall (cognitive 71) · ×1
  • postinstall.postInstall (cognitive 71) code/addons/vitest/src/postinstall.ts:58 — postinstall.postInstall has cognitive complexity 71 (threshold 15). Drivers by points: if/else 27 (44 pts), ternaries 7 (17 pts), boolean chains 10 (nesting depth added 27). Of this number, 68 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · generate-docgen.extractDocgen (cognitive 71) · ×1
  • generate-docgen.extractDocgen (cognitive 71) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts:510 — generate-docgen.extractDocgen has cognitive complexity 71 (threshold 15). Drivers by points: if/else 17 (46 pts), boolean chains 17, ternaries 3 (5 pts), loops 1 (3 pts) (nesting depth added 33). Most of this is not in the body itself: 9 of the 71 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 625, 547, 578, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · esmWalker.esmWalker (cognitive 69) · ×1
  • esmWalker.esmWalker (cognitive 69) code/core/src/mocking-utils/esmWalker.ts:71 — esmWalker.esmWalker has cognitive complexity 69 (threshold 15). Drivers by points: if/else 34 (46 pts), boolean chains 21, ternaries 1 (2 pts) (nesting depth added 13). Of this number, 30 points are the body's own statements and 39 belong to 7 function items inside it that branch. This file's own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes — or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages.
D2 · Cognitive Complexity · exportNameHandler.exportNameHandler (cognitive 67) · ×1
  • exportNameHandler.exportNameHandler (cognitive 67) code/renderers/react/src/componentManifest/reactDocgen/exportNameHandler.ts:100 — exportNameHandler.exportNameHandler has cognitive complexity 67 (threshold 15). Drivers by points: if/else 13 (41 pts), loops 4 (11 pts), boolean chains 8, ternaries 2 (7 pts) (nesting depth added 40). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · componentMetaExtractor.extractStaticDefaultProps (cognitive 67) · ×1
  • componentMetaExtractor.extractStaticDefaultProps (cognitive 67) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1164 — componentMetaExtractor.extractStaticDefaultProps has cognitive complexity 67 (threshold 15). Drivers by points: if/else 17 (55 pts), boolean chains 5, loops 2 (4 pts), ternaries 1 (3 pts) (nesting depth added 42). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · shortcuts.init (cognitive 65) · ×1
  • shortcuts.init (cognitive 65) code/core/src/manager-api/modules/shortcuts.ts:197 — shortcuts.init has cognitive complexity 65 (threshold 15). Drivers by points: if/else 29 (54 pts), boolean chains 6, error handling 1 (3 pts), match/switch 1, ternaries 1 (nesting depth added 27). Of this number, 52 points are the body's own statements and 13 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · compare_stats.analyze (cognitive 64) · ×1
  • compare_stats.analyze (cognitive 64) agent-eval/scripts/compare_stats.py:148 — compare_stats.analyze has cognitive complexity 64 (threshold 15). Drivers by points: if/else 14 (41 pts), loops 8 (16 pts), ternaries 2 (6 pts), boolean chains 1 (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · index.runFixes (cognitive 62) · ×1
  • index.runFixes (cognitive 62) code/lib/cli-storybook/src/automigrate/index.ts:253 — index.runFixes has cognitive complexity 62 (threshold 15). Drivers by points: if/else 21 (37 pts), ternaries 6 (12 pts), error handling 2 (4 pts), loops 4, boolean chains 3, match/switch 1 (2 pts) (nesting depth added 25). Of this number, 60 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · createTab (cognitive 62) · ×1
  • createTab (cognitive 62) agent-eval/lib/mcp/codex-browser-client-mock.mjs:343 — createTab has cognitive complexity 62 (threshold 15). Drivers by points: if/else 21 (25 pts), other 20, error handling 3 (5 pts), loops 5, boolean chains 4, ternaries 2 (3 pts) (nesting depth added 7). None of this is in the body itself: all 62 points belong to 86 function items inside it that branch (a function literal at line 466, domSnapshot, scroll, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · task.run (cognitive 60) · ×1
  • task.run (cognitive 60) scripts/task.ts:411 — task.run has cognitive complexity 60 (threshold 15). Drivers by points: if/else 23 (40 pts), ternaries 6 (12 pts), boolean chains 4, error handling 1 (3 pts), loops 1 (nesting depth added 25). Of this number, 55 points are the body's own statements and 5 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · build-dev.buildDevStandalone (cognitive 57) · ×1
  • build-dev.buildDevStandalone (cognitive 57) code/core/src/core-server/build-dev.ts:75 — build-dev.buildDevStandalone has cognitive complexity 57 (threshold 15). Drivers by points: if/else 20 (28 pts), ternaries 9 (13 pts), boolean chains 12, error handling 3 (4 pts) (nesting depth added 13). Of this number, 56 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · check-docs.checkBareUrls (cognitive 57) · ×1
  • check-docs.checkBareUrls (cognitive 57) scripts/docs/check-docs.ts:357 — check-docs.checkBareUrls has cognitive complexity 57 (threshold 15). Drivers by points: if/else 12 (46 pts), loops 3 (6 pts), boolean chains 5 (nesting depth added 37). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · shell-parse.scanShellWords (cognitive 56) · ×1
  • shell-parse.scanShellWords (cognitive 56) agent-eval/lib/shell-parse.ts:438 — shell-parse.scanShellWords has cognitive complexity 56 (threshold 15). Drivers by points: if/else 26 (52 pts), boolean chains 13, ternaries 3 (8 pts), loops 3 (4 pts) (nesting depth added 32). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (shell-parse.scanShellWords::readHeredocBodies) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · pipeline.runTransforms (cognitive 56) · ×1
  • pipeline.runTransforms (cognitive 56) code/lib/cli-storybook/src/automigrate/pipeline.ts:170 — pipeline.runTransforms has cognitive complexity 56 (threshold 15). Drivers by points: if/else 9 (26 pts), ternaries 4 (10 pts), error handling 3 (8 pts), loops 3 (7 pts), boolean chains 5 (nesting depth added 32). Of this number, 49 points are the body's own statements and 7 belong to 4 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · vitest-setup-file.transformSetupFile (cognitive 56) · ×1
  • vitest-setup-file.transformSetupFile (cognitive 56) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:328 — vitest-setup-file.transformSetupFile has cognitive complexity 56 (threshold 15). Drivers by points: if/else 15 (25 pts), ternaries 7 (14 pts), loops 7 (9 pts), boolean chains 7, error handling 1 (nesting depth added 19). Of this number, 46 points are the body's own statements and 10 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · values.readResolved (cognitive 55) · ×1
  • values.readResolved (cognitive 55) code/core/src/csf-tools/estree/values.ts:167 — values.readResolved has cognitive complexity 55 (threshold 15). Drivers by points: if/else 18 (39 pts), ternaries 3 (7 pts), boolean chains 5, loops 2 (4 pts) (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · resolve.resolveScopedName (cognitive 54) · ×1
  • resolve.resolveScopedName (cognitive 54) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/resolve.ts:64 — resolve.resolveScopedName has cognitive complexity 54 (threshold 15). Drivers by points: if/else 10 (36 pts), loops 5 (12 pts), boolean chains 4, ternaries 1 (2 pts) (nesting depth added 34). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · componentMetaExtractor.serializeComponentDoc (cognitive 54) · ×1
  • componentMetaExtractor.serializeComponentDoc (cognitive 54) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1404 — componentMetaExtractor.serializeComponentDoc has cognitive complexity 54 (threshold 15). Drivers by points: if/else 13 (28 pts), loops 6 (11 pts), ternaries 6 (8 pts), boolean chains 7 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · tool-tokens.parseToolsTokens (cognitive 53) · ×1
  • tool-tokens.parseToolsTokens (cognitive 53) code/core/src/cli/tools/tool-tokens.ts:44 — tool-tokens.parseToolsTokens has cognitive complexity 53 (threshold 15). Drivers by points: if/else 19 (41 pts), boolean chains 6, ternaries 1 (3 pts), error handling 1 (2 pts), loops 1 (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · getComponentImports.getComponents (cognitive 53) · ×1
  • getComponentImports.getComponents (cognitive 53) code/renderers/react/src/componentManifest/getComponentImports.ts:63 — getComponentImports.getComponents has cognitive complexity 53 (threshold 15). Drivers by points: if/else 16 (25 pts), ternaries 6 (18 pts), error handling 3 (5 pts), boolean chains 4, loops 1 (nesting depth added 23). Most of this is not in the body itself: 2 of the 53 points are its own statements and the rest belongs to 4 function items inside it that branch (a function literal at line 145, a function literal at line 85, a function literal at line 99, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · Search.Search (cognitive 53) · ×1
  • Search.Search (cognitive 53) code/core/src/manager/components/sidebar/Search.tsx:177 — Search.Search has cognitive complexity 53 (threshold 15). Drivers by points: if/else 15 (22 pts), boolean chains 18, ternaries 5 (9 pts), loops 2 (3 pts), match/switch 1 (nesting depth added 12). Most of this is not in the body itself: 1 of the 53 points is its own statement and the rest belongs to 10 function literals inside it that branch (lines 194, 383, 322, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · runComputerAction (cognitive 53) · ×1
  • runComputerAction (cognitive 53) agent-eval/lib/mcp/claude-browser-mock.mjs:1429 — runComputerAction has cognitive complexity 53 (threshold 15). Drivers by points: if/else 15 (30 pts), ternaries 5 (10 pts), loops 2 (5 pts), other 5, boolean chains 2, match/switch 1 (nesting depth added 23). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · resolve.analyzeExpression (cognitive 51) · ×1
  • resolve.analyzeExpression (cognitive 51) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/resolve.ts:404 — resolve.analyzeExpression has cognitive complexity 51 (threshold 15). Drivers by points: if/else 19 (37 pts), boolean chains 7, ternaries 3 (7 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · forward-setup.readForwardableSetup (cognitive 51) · ×1
  • forward-setup.readForwardableSetup (cognitive 51) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts:90 — forward-setup.readForwardableSetup has cognitive complexity 51 (threshold 15). Drivers by points: if/else 23 (38 pts), boolean chains 7, loops 5, ternaries 1 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · generateCodeSnippet.rewriteJsx (cognitive 50) · ×1
  • generateCodeSnippet.rewriteJsx (cognitive 50) code/renderers/react/src/componentManifest/generateCodeSnippet.ts:328 — generateCodeSnippet.rewriteJsx has cognitive complexity 50 (threshold 15). Drivers by points: if/else 12 (27 pts), ternaries 3 (12 pts), boolean chains 8, loops 2 (3 pts) (nesting depth added 25). Of this number, 33 points are the body's own statements and 17 belong to 3 function items inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · template-print.resolveAttribute (cognitive 50) · ×1
  • template-print.resolveAttribute (cognitive 50) code/renderers/web-components/src/docgen/story-docs/template-print.ts:174 — template-print.resolveAttribute has cognitive complexity 50 (threshold 15). Drivers by points: if/else 17 (28 pts), ternaries 6 (13 pts), boolean chains 8, loops 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · layout.init (cognitive 49) · ×1
  • layout.init (cognitive 49) code/core/src/manager-api/modules/layout.ts:264 — layout.init has cognitive complexity 49 (threshold 15). Drivers by points: if/else 27 (28 pts), ternaries 11 (13 pts), boolean chains 8 (nesting depth added 3). Of this number, 18 points are the body's own statements and 31 belong to 9 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · server-code-elimination.eliminateServerCode (cognitive 49) · ×1
  • server-code-elimination.eliminateServerCode (cognitive 49) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts:77 — server-code-elimination.eliminateServerCode has cognitive complexity 49 (threshold 15). Drivers by points: if/else 22 (34 pts), boolean chains 13, ternaries 1 (2 pts) (nesting depth added 13). Most of this is not in the body itself: 4 of the 49 points are its own statements and the rest belongs to 4 function items inside it that branch (a function literal at line 110, a function literal at line 86, remove, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · index.displayDoctorResults (cognitive 49) · ×1
  • index.displayDoctorResults (cognitive 49) code/lib/cli-storybook/src/doctor/index.ts:61 — index.displayDoctorResults has cognitive complexity 49 (threshold 15). Drivers by points: if/else 16 (27 pts), ternaries 5 (19 pts), boolean chains 3 (nesting depth added 25). Of this number, 32 points are the body's own statements and 17 belong to 3 function literals inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · story-docs-markup.functionScope (cognitive 48) · ×1
  • story-docs-markup.functionScope (cognitive 48) code/frameworks/angular-vite/src/docgen/story-docs-markup.ts:551 — story-docs-markup.functionScope has cognitive complexity 48 (threshold 15). Drivers by points: if/else 13 (25 pts), loops 4 (10 pts), ternaries 4 (9 pts), boolean chains 4 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · story-docs-ng-modules.ngModulesFromDecorators (cognitive 48) · ×1
  • story-docs-ng-modules.ngModulesFromDecorators (cognitive 48) code/frameworks/angular-vite/src/docgen/story-docs-ng-modules.ts:24 — story-docs-ng-modules.ngModulesFromDecorators has cognitive complexity 48 (threshold 15). Drivers by points: if/else 11 (31 pts), boolean chains 8, loops 3 (6 pts), ternaries 2 (3 pts) (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · claude-code.logMessage (cognitive 48) · ×1
  • claude-code.logMessage (cognitive 48) scripts/eval/lib/agents/claude-code.ts:87 — claude-code.logMessage has cognitive complexity 48 (threshold 15). Drivers by points: if/else 12 (23 pts), ternaries 4 (20 pts), loops 2 (4 pts), match/switch 1 (nesting depth added 29). Of this number, 42 points are the body's own statements and 6 belong to one function literal inside it that branches. The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · A11yContext.A11yContextProvider (cognitive 47) · ×1
  • A11yContext.A11yContextProvider (cognitive 47) code/addons/a11y/src/components/A11yContext.tsx:111 — A11yContext.A11yContextProvider has cognitive complexity 47 (threshold 15). Drivers by points: if/else 25 (30 pts), boolean chains 12, ternaries 4 (5 pts) (nesting depth added 6). None of this is in the body itself: all 47 points belong to 18 function literals inside it that branch (lines 473, 265, 288, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · multi-project.runAutomigrationsForProjects (cognitive 47) · ×1
  • multi-project.runAutomigrationsForProjects (cognitive 47) code/lib/cli-storybook/src/automigrate/multi-project.ts:320 — multi-project.runAutomigrationsForProjects has cognitive complexity 47 (threshold 15). Drivers by points: if/else 11 (20 pts), ternaries 5 (16 pts), loops 5 (8 pts), boolean chains 3 (nesting depth added 23). Of this number, 46 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · shell-parse.parseToolArguments (cognitive 46) · ×1
  • shell-parse.parseToolArguments (cognitive 46) agent-eval/lib/shell-parse.ts:302 — shell-parse.parseToolArguments has cognitive complexity 46 (threshold 15). Drivers by points: if/else 14 (31 pts), ternaries 4 (7 pts), boolean chains 6, error handling 1, loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · churn.collectShellOperations (cognitive 46) · ×1
  • churn.collectShellOperations (cognitive 46) agent-eval/lib/agentic-reference/metrics/churn.ts:94 — churn.collectShellOperations has cognitive complexity 46 (threshold 15). Drivers by points: if/else 12 (26 pts), loops 5 (10 pts), boolean chains 6, ternaries 1 (4 pts) (nesting depth added 22). Of this number, 44 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · storySort.storySort (cognitive 46) · ×1
  • storySort.storySort (cognitive 46) code/core/src/shared/story-index/storySort.ts:10 — storySort.storySort has cognitive complexity 46 (threshold 15). Drivers by points: if/else 14 (36 pts), boolean chains 6, ternaries 1 (3 pts), loops 1 (nesting depth added 24). None of this is in the body itself: all 46 points belong to one function literal inside it that branches (line 11). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · census.censusReactTree (cognitive 45) · ×1
  • census.censusReactTree (cognitive 45) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/census.ts:80 — census.censusReactTree has cognitive complexity 45 (threshold 15). Drivers by points: if/else 12 (24 pts), ternaries 6 (14 pts), boolean chains 6, loops 1 (nesting depth added 20). Most of this is not in the body itself: 4 of the 45 points are its own statements and the rest belongs to 3 function items inside it that branch (count, walk, a function literal at line 116). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · index.storybookTest (cognitive 45) · ×1
  • index.storybookTest (cognitive 45) code/addons/vitest/src/vitest-plugin/index.ts:197 — index.storybookTest has cognitive complexity 45 (threshold 15). Drivers by points: if/else 20 (24 pts), ternaries 7, boolean chains 6, error handling 2 (4 pts), loops 2 (4 pts) (nesting depth added 8). Of this number, 42 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · automock.automockModule (cognitive 45) · ×1
  • automock.automockModule (cognitive 45) code/core/src/mocking-utils/automock.ts:46 — automock.automockModule has cognitive complexity 45 (threshold 15). Drivers by points: if/else 21 (39 pts), boolean chains 5, loops 1 (nesting depth added 18). Of this number, 25 points are the body's own statements and 20 belong to 4 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · parse-snapshot.parseArgTypesSnapshot (cognitive 45) · ×1
  • parse-snapshot.parseArgTypesSnapshot (cognitive 45) REDACTED:15 — parse-snapshot.parseArgTypesSnapshot has cognitive complexity 45 (threshold 15). Drivers by points: if/else 27 (34 pts), loops 5 (6 pts), boolean chains 3, ternaries 2 (nesting depth added 8). Most of this is not in the body itself: 7 of the 45 points are its own statements and the rest belongs to 6 function items inside it that branch (parseObject, parseBareToken, parseArray, …). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · StoryRender.render (cognitive 44) · ×1
  • StoryRender.render (cognitive 44) code/core/src/preview-api/modules/preview-web/render/StoryRender.ts:185 — StoryRender.render has cognitive complexity 44 (threshold 15). Drivers by points: if/else 24 (31 pts), boolean chains 9, error handling 2 (3 pts), ternaries 1 (nesting depth added 8). Of this number, 37 points are the body's own statements and 7 belong to 6 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · scope.analyzeScopes (cognitive 44) · ×1
  • scope.analyzeScopes (cognitive 44) code/core/src/csf-tools/estree/scope.ts:293 — scope.analyzeScopes has cognitive complexity 44 (threshold 15). Drivers by points: if/else 8 (17 pts), loops 8 (14 pts), boolean chains 8, ternaries 2 (5 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · componentMetaExtractor.extractDefaultsFromSourceFile (cognitive 44) · ×1
  • componentMetaExtractor.extractDefaultsFromSourceFile (cognitive 44) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1612 — componentMetaExtractor.extractDefaultsFromSourceFile has cognitive complexity 44 (threshold 15). Drivers by points: if/else 11 (24 pts), loops 4 (11 pts), ternaries 3 (5 pts), boolean chains 4 (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · transform-template.transformDirective (cognitive 44) · ×1
  • transform-template.transformDirective (cognitive 44) code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:520 — transform-template.transformDirective has cognitive complexity 44 (threshold 15). Drivers by points: if/else 18 (31 pts), boolean chains 11, ternaries 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · eslintPlugin.findConfigHelperNames (cognitive 43) · ×1
  • eslintPlugin.findConfigHelperNames (cognitive 43) code/core/src/cli/eslintPlugin.ts:78 — eslintPlugin.findConfigHelperNames has cognitive complexity 43 (threshold 15). Drivers by points: if/else 7 (26 pts), loops 4 (12 pts), boolean chains 5 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · componentMetaExtractor.extractDestructuringDefaults (cognitive 43) · ×1
  • componentMetaExtractor.extractDestructuringDefaults (cognitive 43) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1020 — componentMetaExtractor.extractDestructuringDefaults has cognitive complexity 43 (threshold 15). Drivers by points: if/else 13 (25 pts), loops 3 (10 pts), boolean chains 5, ternaries 2 (3 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · useDragging.useDragging (cognitive 43) · ×1
  • useDragging.useDragging (cognitive 43) code/core/src/manager/components/layout/useDragging.ts:109 — useDragging.useDragging has cognitive complexity 43 (threshold 15). Drivers by points: if/else 18 (26 pts), ternaries 10 (13 pts), boolean chains 4 (nesting depth added 11). None of this is in the body itself: all 43 points belong to 8 function literals inside it that branch (lines 212, 160, 311, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · sandbox.sandbox (cognitive 43) · ×1
  • sandbox.sandbox (cognitive 43) code/lib/cli-storybook/src/sandbox.ts:35 — sandbox.sandbox has cognitive complexity 43 (threshold 15). Drivers by points: if/else 12 (18 pts), boolean chains 12, ternaries 10 (11 pts), error handling 2 (nesting depth added 7). Of this number, 35 points are the body's own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · analyze-results.main (cognitive 42) · ×1
  • analyze-results.main (cognitive 42) agent-eval/scripts/analyze-results.ts:296 — analyze-results.main has cognitive complexity 42 (threshold 15). Drivers by points: if/else 15 (27 pts), ternaries 3 (6 pts), loops 5, boolean chains 2, error handling 1 (2 pts) (nesting depth added 16). Of this number, 41 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · PreviewWithSelection.renderSelection (cognitive 42) · ×1
  • PreviewWithSelection.renderSelection (cognitive 42) code/core/src/preview-api/modules/preview-web/PreviewWithSelection.tsx:304 — PreviewWithSelection.renderSelection has cognitive complexity 42 (threshold 15). Drivers by points: if/else 22 (29 pts), boolean chains 11, error handling 2 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · componentMetaExtractor.findImportSymbolInStoryFile (cognitive 42) · ×1
  • componentMetaExtractor.findImportSymbolInStoryFile (cognitive 42) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:242 — componentMetaExtractor.findImportSymbolInStoryFile has cognitive complexity 42 (threshold 15). Drivers by points: if/else 13 (31 pts), loops 3 (8 pts), boolean chains 3 (nesting depth added 23). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · print-template.printTemplate (cognitive 42) · ×1
  • print-template.printTemplate (cognitive 42) code/renderers/svelte/src/docgen/story-docs/print-template.ts:33 — print-template.printTemplate has cognitive complexity 42 (threshold 15). Drivers by points: boolean chains 16, if/else 12 (13 pts), ternaries 8 (10 pts), loops 2 (3 pts) (nesting depth added 4). Of this number, 32 points are the body's own statements and 10 belong to 7 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · check-playground-routes.collectExports (cognitive 40) · ×1
  • check-playground-routes.collectExports (cognitive 40) agent-eval/scripts/check-playground-routes.mjs:94 — check-playground-routes.collectExports has cognitive complexity 40 (threshold 15). Drivers by points: if/else 9 (25 pts), loops 3 (8 pts), boolean chains 5, ternaries 1 (2 pts) (nesting depth added 22). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · editor.appendFirst (cognitive 40) · ×1
  • editor.appendFirst (cognitive 40) code/core/src/csf-tools/estree/editor.ts:1082 — editor.appendFirst has cognitive complexity 40 (threshold 15). Drivers by points: if/else 12 (24 pts), boolean chains 9, ternaries 4 (7 pts) (nesting depth added 15). Of this number, 39 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · componentMetaExtractor.findExportedFunction (cognitive 40) · ×1
  • componentMetaExtractor.findExportedFunction (cognitive 40) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1724 — componentMetaExtractor.findExportedFunction has cognitive complexity 40 (threshold 15). Drivers by points: if/else 10 (24 pts), loops 3 (7 pts), boolean chains 5, ternaries 1 (4 pts) (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · TestingWidget.TestingWidget (cognitive 40) · ×1
  • TestingWidget.TestingWidget (cognitive 40) code/core/src/manager/components/sidebar/TestingWidget.tsx:159 — TestingWidget.TestingWidget has cognitive complexity 40 (threshold 15). Drivers by points: ternaries 9 (20 pts), boolean chains 14, if/else 5 (6 pts) (nesting depth added 12). Of this number, 31 points are the body's own statements and 9 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · parse.oxcParse (cognitive 40) · ×1
  • parse.oxcParse (cognitive 40) code/core/src/oxc-parser/parse.ts:20 — parse.oxcParse has cognitive complexity 40 (threshold 15). Drivers by points: if/else 12 (22 pts), loops 5 (9 pts), boolean chains 4, ternaries 2 (4 pts), error handling 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · story-docs-args.evaluateNode (cognitive 40) · ×1
  • story-docs-args.evaluateNode (cognitive 40) code/frameworks/angular-vite/src/docgen/story-docs-args.ts:125 — story-docs-args.evaluateNode has cognitive complexity 40 (threshold 15). Drivers by points: if/else 14 (25 pts), boolean chains 9, loops 2 (4 pts), ternaries 1 (2 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · compare-results.main (cognitive 39) · ×1
  • compare-results.main (cognitive 39) agent-eval/scripts/compare-results.ts:68 — compare-results.main has cognitive complexity 39 (threshold 15). Drivers by points: if/else 16 (22 pts), loops 3 (10 pts), ternaries 4 (5 pts), error handling 2 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · stories.transformStoryIndexToStoriesHash (cognitive 39) · ×1
  • stories.transformStoryIndexToStoriesHash (cognitive 39) code/core/src/manager-api/lib/stories.ts:106 — stories.transformStoryIndexToStoriesHash has cognitive complexity 39 (threshold 15). Drivers by points: if/else 19 (20 pts), boolean chains 12, ternaries 7 (nesting depth added 1). Most of this is not in the body itself: 3 of the 39 points are its own statements and the rest belongs to 14 function items inside it that branch (a function literal at line 167, a function literal at line 128, a function literal at line 185, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · scope.analyzeScopes.enterScope (cognitive 39) · ×1
  • scope.analyzeScopes.enterScope (cognitive 39) code/core/src/csf-tools/estree/scope.ts:396 — scope.analyzeScopes.enterScope has cognitive complexity 39 (threshold 15). Drivers by points: if/else 11 (19 pts), loops 4 (10 pts), boolean chains 8, ternaries 1 (2 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CsfFile._parseMeta (cognitive 39) · ×1
  • CsfFile._parseMeta (cognitive 39) REDACTED:731 — CsfFile._parseMeta has cognitive complexity 39 (threshold 15). Drivers by points: if/else 14 (34 pts), boolean chains 4, loops 1 (nesting depth added 20). Of this number, 38 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · ConfigFile.findCallArguments (cognitive 38) · ×1
  • ConfigFile.findCallArguments (cognitive 38) code/core/src/csf-tools/ConfigFile.ts:1003 — ConfigFile.findCallArguments has cognitive complexity 38 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 12, ternaries 3 (5 pts), loops 2 (4 pts) (nesting depth added 10). None of this is in the body itself: all 38 points belong to 2 function literals inside it that branch (lines 1014, 1056). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · vitest-setup-file.resolveStaticPath (cognitive 38) · ×1
  • vitest-setup-file.resolveStaticPath (cognitive 38) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:857 — vitest-setup-file.resolveStaticPath has cognitive complexity 38 (threshold 15). Drivers by points: if/else 17 (25 pts), boolean chains 6, ternaries 3 (6 pts), loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · generateCodeSnippet.functionSnippet (cognitive 38) · ×1
  • generateCodeSnippet.functionSnippet (cognitive 38) code/renderers/react/src/componentManifest/generateCodeSnippet.ts:176 — generateCodeSnippet.functionSnippet has cognitive complexity 38 (threshold 15). Drivers by points: ternaries 8 (20 pts), if/else 7 (11 pts), boolean chains 5, loops 1 (2 pts) (nesting depth added 17). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · post-analysis.printMisuseFindings (cognitive 37) · ×1
  • post-analysis.printMisuseFindings (cognitive 37) agent-eval/lib/agentic-reference/post-analysis.ts:324 — post-analysis.printMisuseFindings has cognitive complexity 37 (threshold 15). Drivers by points: ternaries 4 (16 pts), if/else 4 (11 pts), loops 4 (10 pts) (nesting depth added 25). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · preset.experimental_devServer (cognitive 37) · ×1
  • preset.experimental_devServer (cognitive 37) code/addons/mcp/src/preset.ts:32 — preset.experimental_devServer has cognitive complexity 37 (threshold 15). Drivers by points: if/else 16 (18 pts), ternaries 10, boolean chains 8, error handling 1 (nesting depth added 2). Most of this is not in the body itself: 7 of the 37 points are its own statements and the rest belongs to 6 function items inside it that branch (a function literal at line 189, rejectDisallowedOrigin, a function literal at line 157, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · markdown.formatComponentManifest (cognitive 37) · ×1
  • markdown.formatComponentManifest (cognitive 37) code/core/src/shared/open-service/toolsets/docs/manifest-formatter/markdown.ts:353 — markdown.formatComponentManifest has cognitive complexity 37 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 4 (11 pts), loops 3 (8 pts), boolean chains 3 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · react-loadable-plugin.default (cognitive 37) · ×1
  • react-loadable-plugin.default (cognitive 37) code/frameworks/nextjs/src/babel/plugins/react-loadable-plugin.ts:9 — react-loadable-plugin.default has cognitive complexity 37 (threshold 15). Drivers by points: if/else 22 (27 pts), boolean chains 6, ternaries 3 (4 pts) (nesting depth added 6). Most of this is not in the body itself: 3 of the 37 points are its own statements and the rest belongs to one function literal inside it that branches (line 34). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · parser.parseForIndexer (cognitive 37) · ×1
  • parser.parseForIndexer (cognitive 37) code/renderers/svelte/src/svelte-csf/indexer/parser.ts:56 — parser.parseForIndexer has cognitive complexity 37 (threshold 15). Drivers by points: if/else 20 (28 pts), boolean chains 7, loops 2 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · print-h.printProps (cognitive 37) · ×1
  • print-h.printProps (cognitive 37) code/renderers/vue3/src/docgen/story-docs/print-h/print-h.ts:300 — print-h.printProps has cognitive complexity 37 (threshold 15). Drivers by points: if/else 14 (27 pts), boolean chains 6, ternaries 2 (3 pts), loops 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · VitestManager.startVitest (cognitive 36) · ×1
  • VitestManager.startVitest (cognitive 36) code/addons/vitest/src/node/vitest-manager.ts:54 — VitestManager.startVitest has cognitive complexity 36 (threshold 15). Drivers by points: if/else 9 (19 pts), boolean chains 8, ternaries 2 (4 pts), loops 2 (3 pts), error handling 2 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · url.init (cognitive 36) · ×1
  • url.init (cognitive 36) code/core/src/manager-api/modules/url.ts:239 — url.init has cognitive complexity 36 (threshold 15). Drivers by points: ternaries 12 (13 pts), boolean chains 11, if/else 8 (11 pts), loops 1 (nesting depth added 4). Of this number, 28 points are the body's own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · Instrumenter.invoke (cognitive 36) · ×1
  • Instrumenter.invoke (cognitive 36) code/core/src/instrumenter/instrumenter.ts:491 — Instrumenter.invoke has cognitive complexity 36 (threshold 15). Drivers by points: if/else 22 (25 pts), ternaries 4 (6 pts), boolean chains 4, error handling 1 (nesting depth added 5). Most of this is not in the body itself: 8 of the 36 points are its own statements and the rest belongs to 5 function items inside it that branch (serializeValues, handleException, a function literal at line 613, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · parse.collectRequireSpecifiers (cognitive 36) · ×1
  • parse.collectRequireSpecifiers (cognitive 36) code/core/src/oxc-parser/parse.ts:185 — parse.collectRequireSpecifiers has cognitive complexity 36 (threshold 15). Drivers by points: if/else 7 (21 pts), loops 3 (6 pts), boolean chains 5, ternaries 1 (4 pts) (nesting depth added 20). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · duplicate-tree.resolveStoryLeaf (cognitive 36) · ×1
  • duplicate-tree.resolveStoryLeaf (cognitive 36) code/frameworks/tanstack-react/src/routing/duplicate-tree.ts:232 — duplicate-tree.resolveStoryLeaf has cognitive complexity 36 (threshold 15). Drivers by points: if/else 10 (21 pts), ternaries 4 (11 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · config-to-csf-factory.configToCsfFactory (cognitive 36) · ×1
  • config-to-csf-factory.configToCsfFactory (cognitive 36) code/lib/cli-storybook/src/codemod/helpers/config-to-csf-factory.ts:27 — config-to-csf-factory.configToCsfFactory has cognitive complexity 36 (threshold 15). Drivers by points: if/else 16 (21 pts), boolean chains 8, ternaries 4 (5 pts), error handling 1, loops 1 (nesting depth added 6). Of this number, 18 points are the body's own statements and 18 belong to 6 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · codemod.runSnippetCodemod (cognitive 36) · ×1
  • codemod.runSnippetCodemod (cognitive 36) scripts/snippets/codemod.ts:348 — codemod.runSnippetCodemod has cognitive complexity 36 (threshold 15). Drivers by points: if/else 11 (22 pts), error handling 3 (5 pts), ternaries 2 (5 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 17). Most of this is not in the body itself: 3 of the 36 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 386, 436, 423). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · resolve.styledTargetOf (cognitive 35) · ×1
  • resolve.styledTargetOf (cognitive 35) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/resolve.ts:155 — resolve.styledTargetOf has cognitive complexity 35 (threshold 15). Drivers by points: if/else 10 (31 pts), boolean chains 3, loops 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · html-report.buildFullReport (cognitive 35) · ×1
  • html-report.buildFullReport (cognitive 35) agent-eval/lib/agentic-reference/comparison/html-report.ts:1692 — html-report.buildFullReport has cognitive complexity 35 (threshold 15). Drivers by points: ternaries 15 (18 pts), if/else 6 (9 pts), loops 4 (5 pts), boolean chains 3 (nesting depth added 7). Of this number, 16 points are the body's own statements and 19 belong to 6 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · plugin.viteMockPlugin (cognitive 35) · ×1
  • plugin.viteMockPlugin (cognitive 35) code/builders/builder-vite/src/plugins/vite-mock/plugin.ts:41 — plugin.viteMockPlugin has cognitive complexity 35 (threshold 15). Drivers by points: if/else 11 (22 pts), loops 4 (6 pts), error handling 2 (4 pts), boolean chains 3 (nesting depth added 15). Of this number, 24 points are the body's own statements and 11 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CsfObjectPath.locate (cognitive 35) · ×1
  • CsfObjectPath.locate (cognitive 35) code/core/src/csf-tools/CsfObjectPath.ts:124 — CsfObjectPath.locate has cognitive complexity 35 (threshold 15). Drivers by points: if/else 11 (27 pts), ternaries 2 (5 pts), boolean chains 2, loops 1 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Button.StyledButton (cognitive 35) · ×1
  • Button.StyledButton (cognitive 35) code/core/src/components/components/Button/Button.tsx:185 — Button.StyledButton has cognitive complexity 35 (threshold 15). Drivers by points: ternaries 11 (16 pts), if/else 12, boolean chains 7 (nesting depth added 5). Most of this is not in the body itself: 11 of the 35 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 269, 251, 218, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ReviewProvider.ReviewProvider (cognitive 35) · ×1
  • ReviewProvider.ReviewProvider (cognitive 35) code/core/src/manager/components/review/components/ReviewProvider.tsx:69 — ReviewProvider.ReviewProvider has cognitive complexity 35 (threshold 15). Drivers by points: if/else 18 (20 pts), boolean chains 8, ternaries 6 (7 pts) (nesting depth added 3). Most of this is not in the body itself: 3 of the 35 points are its own statements and the rest belongs to 10 function literals inside it that branch (lines 134, 244, 285, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · analyze-file.analyzeSourceFile (cognitive 35) · ×1
  • analyze-file.analyzeSourceFile (cognitive 35) code/lib/angular-cm/src/analyzer/analyze-file.ts:24 — analyze-file.analyzeSourceFile has cognitive complexity 35 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 5 (15 pts), boolean chains 4, loops 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · generate-docgen.createDocgenProgram (cognitive 35) · ×1
  • generate-docgen.createDocgenProgram (cognitive 35) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts:379 — generate-docgen.createDocgenProgram has cognitive complexity 35 (threshold 15). Drivers by points: if/else 14 (23 pts), boolean chains 6, ternaries 3 (6 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CsfFile._visitCallExpression (cognitive 34) · ×1
  • CsfFile._visitCallExpression (cognitive 34) REDACTED:1142 — CsfFile._visitCallExpression has cognitive complexity 34 (threshold 15). Drivers by points: if/else 9 (20 pts), ternaries 2 (10 pts), boolean chains 4 (nesting depth added 19). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · componentMetaExtractor.resolveLiteralValue (cognitive 34) · ×1
  • componentMetaExtractor.resolveLiteralValue (cognitive 34) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:824 — componentMetaExtractor.resolveLiteralValue has cognitive complexity 34 (threshold 15). Drivers by points: if/else 13 (25 pts), boolean chains 7, ternaries 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · server-code-elimination.eliminateDeadCode (cognitive 34) · ×1
  • server-code-elimination.eliminateDeadCode (cognitive 34) code/frameworks/tanstack-react/src/plugins/server-code-elimination.ts:449 — server-code-elimination.eliminateDeadCode has cognitive complexity 34 (threshold 15). Drivers by points: if/else 5 (15 pts), ternaries 3 (9 pts), boolean chains 5, loops 3 (5 pts) (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · check-package.run (cognitive 34) · ×1
  • check-package.run (cognitive 34) scripts/check-package.ts:20 — check-package.run has cognitive complexity 34 (threshold 15). Drivers by points: if/else 9 (19 pts), boolean chains 5, error handling 2 (5 pts), ternaries 2 (3 pts), loops 1 (2 pts) (nesting depth added 15). Most of this is not in the body itself: 7 of the 34 points are its own statements and the rest belongs to 8 function items inside it that branch (runAllChecks, a function literal at line 24, a function literal at line 36, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · ComponentMetaManager.watchProgramSourceDirs (cognitive 33) · ×1
  • ComponentMetaManager.watchProgramSourceDirs (cognitive 33) code/core/src/component-meta/ComponentMetaManager.ts:405 — ComponentMetaManager.watchProgramSourceDirs has cognitive complexity 33 (threshold 15). Drivers by points: loops 8 (17 pts), if/else 6 (14 pts), boolean chains 2 (nesting depth added 17). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline.
D2 · Cognitive Complexity · Panel.Panel (cognitive 33) · ×1
  • Panel.Panel (cognitive 33) code/core/src/component-testing/components/Panel.tsx:223 — Panel.Panel has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (12 pts), ternaries 6 (12 pts), boolean chains 9 (nesting depth added 8). Most of this is not in the body itself: 4 of the 33 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 399, 416, 272, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · componentMetaExtractor.resolvePropsFromStoryFile · ×1
  • componentMetaExtractor.resolvePropsFromStoryFile::visit (cognitive 33) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:412 — componentMetaExtractor.resolvePropsFromStoryFile::visit has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (29 pts), boolean chains 4 (nesting depth added 19). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · get-dummy-args-from-argtypes.generateDummyValueFromSBType (cognitive 33) · ×1
  • get-dummy-args-from-argtypes.generateDummyValueFromSBType (cognitive 33) code/core/src/core-server/utils/get-dummy-args-from-argtypes.ts:146 — get-dummy-args-from-argtypes.generateDummyValueFromSBType has cognitive complexity 33 (threshold 15). Drivers by points: if/else 11 (23 pts), boolean chains 5, match/switch 2 (3 pts), loops 1 (2 pts) (nesting depth added 14). Of this number, 30 points are the body's own statements and 3 belong to one function literal inside it that branches. The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · TypeIndex.render (cognitive 33) · ×1
  • TypeIndex.render (cognitive 33) code/lib/angular-cm/src/analyzer/type-index.ts:37 — TypeIndex.render has cognitive complexity 33 (threshold 15). Drivers by points: ternaries 8 (17 pts), if/else 12 (14 pts), boolean chains 2 (nesting depth added 11). Of this number, 27 points are the body's own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · build-tag-index.buildTagIndex (cognitive 33) · ×1
  • build-tag-index.buildTagIndex (cognitive 33) code/renderers/web-components/src/docgen/component-docgen/manifest/build-tag-index.ts:6 — build-tag-index.buildTagIndex has cognitive complexity 33 (threshold 15). Drivers by points: if/else 6 (16 pts), ternaries 2 (7 pts), loops 4 (6 pts), boolean chains 4 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · module-graph.recordDeclaration (cognitive 32) · ×1
  • module-graph.recordDeclaration (cognitive 32) agent-eval/lib/agentic-reference/metrics/ds-coverage/module-graph.ts:209 — module-graph.recordDeclaration has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (22 pts), loops 2 (5 pts), boolean chains 3, ternaries 1 (2 pts) (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · format.formatA11yReportsSection (cognitive 32) · ×1
  • format.formatA11yReportsSection (cognitive 32) code/addons/vitest/src/node/toolset/format.ts:149 — format.formatA11yReportsSection has cognitive complexity 32 (threshold 15). Drivers by points: if/else 6 (19 pts), loops 3 (6 pts), ternaries 1 (4 pts), boolean chains 3 (nesting depth added 19). Most of this is not in the body itself: 14 of the 32 points are its own statements and the rest belongs to one function literal inside it that branches (line 174). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · componentMetaExtractor.resolveComponentSymbol (cognitive 32) · ×1
  • componentMetaExtractor.resolveComponentSymbol (cognitive 32) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:147 — componentMetaExtractor.resolveComponentSymbol has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (23 pts), boolean chains 9 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · build-static.buildStaticStandalone (cognitive 32) · ×1
  • build-static.buildStaticStandalone (cognitive 32) code/core/src/core-server/build-static.ts:40 — build-static.buildStaticStandalone has cognitive complexity 32 (threshold 15). Drivers by points: if/else 15 (18 pts), ternaries 4 (7 pts), boolean chains 5, error handling 1 (2 pts) (nesting depth added 7). Of this number, 24 points are the body's own statements and 8 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · decorators.readMetadataInputsOutputs (cognitive 32) · ×1
  • decorators.readMetadataInputsOutputs (cognitive 32) code/lib/angular-cm/src/analyzer/decorators.ts:171 — decorators.readMetadataInputsOutputs has cognitive complexity 32 (threshold 15). Drivers by points: if/else 6 (13 pts), ternaries 3 (12 pts), boolean chains 4, loops 2 (3 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · upgrade-deprecated-types.upgradeDeprecatedTypes (cognitive 32) · ×1
  • upgrade-deprecated-types.upgradeDeprecatedTypes (cognitive 32) code/lib/codemod/src/transforms/upgrade-deprecated-types.ts:57 — upgrade-deprecated-types.upgradeDeprecatedTypes has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (26 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 15). Of this number, 25 points are the body's own statements and 7 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · versions.init (cognitive 31) · ×1
  • versions.init (cognitive 31) code/core/src/manager-api/modules/versions.ts:74 — versions.init has cognitive complexity 31 (threshold 15). Drivers by points: if/else 12 (16 pts), boolean chains 10, ternaries 3 (5 pts) (nesting depth added 6). None of this is in the body itself: all 31 points belong to 3 function literals inside it that branch (lines 104, 148, 94). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · CsfObjectDiscovery.storyExports (cognitive 31) · ×1
  • CsfObjectDiscovery.storyExports (cognitive 31) code/core/src/csf-tools/CsfObjectDiscovery.ts:111 — CsfObjectDiscovery.storyExports has cognitive complexity 31 (threshold 15). Drivers by points: if/else 8 (22 pts), loops 3 (6 pts), boolean chains 3 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CsfObjectDiscovery.discoverStories (cognitive 31) · ×1
  • CsfObjectDiscovery.discoverStories (cognitive 31) code/core/src/csf-tools/CsfObjectDiscovery.ts:594 — CsfObjectDiscovery.discoverStories has cognitive complexity 31 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 7, ternaries 5 (7 pts) (nesting depth added 8). None of this is in the body itself: all 31 points belong to one function literal inside it that branches (line 600). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · changed-files-outside-stories.detectChangedFilesOutsideStories (cognitive 31) · ×1
  • changed-files-outside-stories.detectChangedFilesOutsideStories (cognitive 31) code/core/src/shared/open-service/toolsets/stories/changed-files-outside-stories.ts:45 — changed-files-outside-stories.detectChangedFilesOutsideStories has cognitive complexity 31 (threshold 15). Drivers by points: if/else 7 (16 pts), boolean chains 9, loops 3 (4 pts), error handling 1, ternaries 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Instrumenter.constructor (cognitive 31) · ×1
  • Instrumenter.constructor (cognitive 31) code/core/src/instrumenter/instrumenter.ts:103 — Instrumenter.constructor has cognitive complexity 31 (threshold 15). Drivers by points: if/else 19 (22 pts), boolean chains 6, ternaries 3 (nesting depth added 3). Most of this is not in the body itself: 1 of the 31 points is its own statement and the rest belongs to 9 function items inside it that branch (renderPhaseChanged, a function literal at line 179, a function literal at line 197, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · default-initializer.literalKind (cognitive 31) · ×1
  • default-initializer.literalKind (cognitive 31) code/lib/angular-cm/src/analyzer/default-initializer.ts:30 — default-initializer.literalKind has cognitive complexity 31 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 9, ternaries 3 (6 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · snippet-imports.markupReferences (cognitive 31) · ×1
  • snippet-imports.markupReferences (cognitive 31) code/renderers/svelte/src/docgen/story-docs/snippet-imports.ts:171 — snippet-imports.markupReferences has cognitive complexity 31 (threshold 15). Drivers by points: if/else 13 (16 pts), ternaries 6 (9 pts), loops 4, boolean chains 2 (nesting depth added 6). Most of this is not in the body itself: 12 of the 31 points are its own statements and the rest belongs to 4 function items inside it that branch (visitElement, read, a function literal at line 190, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · resolveViewport.resolveViewport (cognitive 30) · ×1
  • resolveViewport.resolveViewport (cognitive 30) code/core/src/viewport/resolveViewport.ts:43 — resolveViewport.resolveViewport has cognitive complexity 30 (threshold 15). Drivers by points: ternaries 11 (20 pts), boolean chains 7, if/else 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · storybook-metadata.computeStorybookMetadata (cognitive 30) · ×1
  • storybook-metadata.computeStorybookMetadata (cognitive 30) code/core/src/telemetry/storybook-metadata.ts:112 — storybook-metadata.computeStorybookMetadata has cognitive complexity 30 (threshold 15). Drivers by points: if/else 13 (16 pts), boolean chains 11, ternaries 2, error handling 1 (nesting depth added 3). Of this number, 18 points are the body's own statements and 12 belong to 5 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · jsx-pragma.jsxPragma (cognitive 30) · ×1
  • jsx-pragma.jsxPragma (cognitive 30) code/frameworks/nextjs/src/babel/plugins/jsx-pragma.ts:14 — jsx-pragma.jsxPragma has cognitive complexity 30 (threshold 15). Drivers by points: if/else 7 (13 pts), ternaries 2 (7 pts), loops 2 (6 pts), boolean chains 4 (nesting depth added 15). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · plugin.vitePluginNextImage.resolveId (cognitive 30) · ×1
  • plugin.vitePluginNextImage.resolveId (cognitive 30) code/lib/vite-plugin-storybook-nextjs/src/plugins/next-image/plugin.ts:94 — plugin.vitePluginNextImage.resolveId has cognitive complexity 30 (threshold 15). Drivers by points: if/else 12 (19 pts), boolean chains 6, error handling 1 (5 pts) (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · resolve-component.followExport (cognitive 30) · ×1
  • resolve-component.followExport (cognitive 30) code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts:69 — resolve-component.followExport has cognitive complexity 30 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 7, ternaries 2 (3 pts), loops 2 (nesting depth added 9). Of this number, 23 points are the body's own statements and 7 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · shell-segments.splitCommandSegments (cognitive 29) · ×1
  • shell-segments.splitCommandSegments (cognitive 29) agent-eval/lib/utils/shell-segments.ts:44 — shell-segments.splitCommandSegments has cognitive complexity 29 (threshold 15). Drivers by points: if/else 12 (26 pts), boolean chains 2, loops 1 (nesting depth added 14). Of this number, 28 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · preview.afterEach (cognitive 29) · ×1
  • preview.afterEach (cognitive 29) code/addons/a11y/src/preview.tsx:14 — preview.afterEach has cognitive complexity 29 (threshold 15). Drivers by points: if/else 6 (18 pts), ternaries 2 (5 pts), boolean chains 3, error handling 1 (2 pts), match/switch 1 (nesting depth added 16). Of this number, 28 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · Onboarding.Onboarding (cognitive 29) · ×1
  • Onboarding.Onboarding (cognitive 29) code/addons/onboarding/src/Onboarding.tsx:47 — Onboarding.Onboarding has cognitive complexity 29 (threshold 15). Drivers by points: if/else 10, ternaries 4 (10 pts), boolean chains 8, error handling 1 (nesting depth added 6). Most of this is not in the body itself: 9 of the 29 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 143, 72, 112, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · eslintPlugin.configureFlatConfig (cognitive 29) · ×1
  • eslintPlugin.configureFlatConfig (cognitive 29) code/core/src/cli/eslintPlugin.ts:244 — eslintPlugin.configureFlatConfig has cognitive complexity 29 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 4, ternaries 2 (4 pts), loops 2 (3 pts) (nesting depth added 11). Of this number, 25 points are the body's own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · eslintPlugin.configureEslintPlugin (cognitive 29) · ×1
  • eslintPlugin.configureEslintPlugin (cognitive 29) code/core/src/cli/eslintPlugin.ts:389 — eslintPlugin.configureEslintPlugin has cognitive complexity 29 (threshold 15). Drivers by points: if/else 11 (27 pts), boolean chains 2 (nesting depth added 16). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · transformer.vitestTransform (cognitive 29) · ×1
  • transformer.vitestTransform (cognitive 29) code/core/src/csf-tools/vitest-plugin/transformer.ts:101 — transformer.vitestTransform has cognitive complexity 29 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 8, loops 2 (4 pts), ternaries 4 (nesting depth added 5). Of this number, 20 points are the body's own statements and 9 belong to 4 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · util.generateUpgradeSpecs (cognitive 29) · ×1
  • util.generateUpgradeSpecs (cognitive 29) code/lib/cli-storybook/src/util.ts:434 — util.generateUpgradeSpecs has cognitive complexity 29 (threshold 15). Drivers by points: ternaries 5 (10 pts), if/else 5 (8 pts), error handling 2 (6 pts), boolean chains 5 (nesting depth added 12). Most of this is not in the body itself: 9 of the 29 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 454, 491, 485). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · html-tree.parseAttributes (cognitive 29) · ×1
  • html-tree.parseAttributes (cognitive 29) code/renderers/web-components/src/docgen/story-docs/html-tree.ts:176 — html-tree.parseAttributes has cognitive complexity 29 (threshold 15). Drivers by points: loops 7 (14 pts), if/else 4 (9 pts), boolean chains 4, ternaries 1 (2 pts) (nesting depth added 13). To reduce it, break up the iteration: give each loop body a named function, and split a multi-phase loop into one function per phase so no single body carries the whole pipeline.
D2 · Cognitive Complexity · complexity-jsx.jsxCognitiveForSource (cognitive 28) · ×1
  • complexity-jsx.jsxCognitiveForSource (cognitive 28) agent-eval/lib/agentic-reference/metrics/complexity-jsx.ts:265 — complexity-jsx.jsxCognitiveForSource has cognitive complexity 28 (threshold 15). Drivers by points: if/else 14 (20 pts), boolean chains 6, ternaries 1 (2 pts) (nesting depth added 7). Most of this is not in the body itself: 1 of the 28 points is its own statement and the rest belongs to one function literal inside it that branches (line 272). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · editor.printValue (cognitive 28) · ×1
  • editor.printValue (cognitive 28) code/core/src/csf-tools/estree/editor.ts:570 — editor.printValue has cognitive complexity 28 (threshold 15). Drivers by points: ternaries 5 (13 pts), if/else 11 (12 pts), boolean chains 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · markdown.formatMultiSourceManifestsToLists (cognitive 28) · ×1
  • markdown.formatMultiSourceManifestsToLists (cognitive 28) code/core/src/shared/open-service/toolsets/docs/manifest-formatter/markdown.ts:518 — markdown.formatMultiSourceManifestsToLists has cognitive complexity 28 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 4 (12 pts), boolean chains 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · definition.createDocsToolset (cognitive 28) · ×1
  • definition.createDocsToolset (cognitive 28) code/core/src/shared/open-service/toolsets/docs/definition.ts:399 — definition.createDocsToolset has cognitive complexity 28 (threshold 15). Drivers by points: ternaries 19 (20 pts), boolean chains 5, if/else 3 (nesting depth added 1). Most of this is not in the body itself: 5 of the 28 points are its own statements and the rest belongs to 7 function items inside it that branch (a function literal at line 581, recoverMissedId, a function literal at line 515, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · checklist.initializeChecklist (cognitive 28) · ×1
  • checklist.initializeChecklist (cognitive 28) code/core/src/core-server/utils/checklist.ts:28 — checklist.initializeChecklist has cognitive complexity 28 (threshold 15). Drivers by points: if/else 17, boolean chains 5, ternaries 2 (4 pts), error handling 2 (nesting depth added 2). Most of this is not in the body itself: 2 of the 28 points are its own statements and the rest belongs to 13 function items inside it that branch (isAiSetupCompleted, a function literal at line 246, scheduleIdleCheck, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · TreeNode.TreeNode (cognitive 28) · ×1
  • TreeNode.TreeNode (cognitive 28) code/core/src/manager/components/sidebar/TreeNode.tsx:270 — TreeNode.TreeNode has cognitive complexity 28 (threshold 15). Drivers by points: boolean chains 10, if/else 9, ternaries 6 (9 pts) (nesting depth added 3). Most of this is not in the body itself: 5 of the 28 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 422, 464, 403, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ShowChangesButton.ShowChangesButton (cognitive 28) · ×1
  • ShowChangesButton.ShowChangesButton (cognitive 28) code/core/src/manager/components/sidebar/ShowChangesButton.tsx:47 — ShowChangesButton.ShowChangesButton has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 10, ternaries 3 (4 pts), loops 1 (nesting depth added 5). Most of this is not in the body itself: 10 of the 28 points are its own statements and the rest belongs to 7 function items inside it that branch (a function literal at line 59, onClick, a function literal at line 67, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · members.visitAccessorPair (cognitive 28) · ×1
  • members.visitAccessorPair (cognitive 28) code/lib/angular-cm/src/analyzer/members.ts:456 — members.visitAccessorPair has cognitive complexity 28 (threshold 15). Drivers by points: ternaries 15 (20 pts), if/else 5, boolean chains 3 (nesting depth added 5). Of this number, 25 points are the body's own statements and 3 belong to 3 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · remove-unused-types.removeUnusedTypes (cognitive 28) · ×1
  • remove-unused-types.removeUnusedTypes (cognitive 28) code/lib/cli-storybook/src/codemod/helpers/remove-unused-types.ts:42 — remove-unused-types.removeUnusedTypes has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (19 pts), boolean chains 6, loops 2 (3 pts) (nesting depth added 10). Most of this is not in the body itself: 3 of the 28 points are its own statements and the rest belongs to 3 function items inside it that branch (a function literal at line 60, markOwner, a function literal at line 92). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · multi-project.collectAutomigrationsAcrossProjects (cognitive 28) · ×1
  • multi-project.collectAutomigrationsAcrossProjects (cognitive 28) code/lib/cli-storybook/src/automigrate/multi-project.ts:60 — multi-project.collectAutomigrationsAcrossProjects has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (11 pts), ternaries 3 (8 pts), loops 3 (5 pts), error handling 1 (3 pts), boolean chains 1 (nesting depth added 11). Of this number, 24 points are the body's own statements and 4 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · metroConfig.hasWithStorybookBinding (cognitive 28) · ×1
  • metroConfig.hasWithStorybookBinding (cognitive 28) code/lib/create-storybook/src/generators/REACT_NATIVE/metroConfig.ts:133 — metroConfig.hasWithStorybookBinding has cognitive complexity 28 (threshold 15). Drivers by points: if/else 6 (17 pts), loops 3 (6 pts), boolean chains 5 (nesting depth added 14). Of this number, 27 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · print-template.replaceArgsReads (cognitive 28) · ×1
  • print-template.replaceArgsReads (cognitive 28) code/renderers/svelte/src/docgen/story-docs/print-template.ts:251 — print-template.replaceArgsReads has cognitive complexity 28 (threshold 15). Drivers by points: if/else 13 (18 pts), boolean chains 5, ternaries 4 (5 pts) (nesting depth added 6). Most of this is not in the body itself: 4 of the 28 points are its own statements and the rest belongs to 2 function items inside it that branch (a function literal at line 266, valueOf). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · get-github-info.getPullInfoFromCommit (cognitive 28) · ×1
  • get-github-info.getPullInfoFromCommit (cognitive 28) scripts/release/utils/get-github-info.ts:175 — get-github-info.getPullInfoFromCommit has cognitive complexity 28 (threshold 15). Drivers by points: if/else 10 (15 pts), ternaries 9, boolean chains 4 (nesting depth added 5). Of this number, 17 points are the body's own statements and 11 belong to one function literal inside it that branches. This file's own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes — or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages.
D2 · Cognitive Complexity · jsdocParser.extractJsDocTags (cognitive 27) · ×1
  • jsdocParser.extractJsDocTags (cognitive 27) code/core/src/docs-tools/argTypes/jsdocParser.ts:104 — jsdocParser.extractJsDocTags has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (22 pts), match/switch 1 (3 pts), boolean chains 1, loops 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · shortcut.eventToShortcut (cognitive 27) · ×1
  • shortcut.eventToShortcut (cognitive 27) code/core/src/manager-api/lib/shortcut.ts:21 — shortcut.eventToShortcut has cognitive complexity 27 (threshold 15). Drivers by points: if/else 15 (16 pts), ternaries 4 (7 pts), boolean chains 4 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · wrap-utils.wrapTextForClackHint (cognitive 27) · ×1
  • wrap-utils.wrapTextForClackHint (cognitive 27) code/core/src/node-logger/wrap-utils.ts:218 — wrap-utils.wrapTextForClackHint has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 3 (6 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 10). Of this number, 24 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CsfObjectDiscovery.assignmentsOf (cognitive 27) · ×1
  • CsfObjectDiscovery.assignmentsOf (cognitive 27) code/core/src/csf-tools/CsfObjectDiscovery.ts:376 — CsfObjectDiscovery.assignmentsOf has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 10, loops 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · run.dispatchTools (cognitive 27) · ×1
  • run.dispatchTools (cognitive 27) code/core/src/cli/tools/run.ts:258 — run.dispatchTools has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (13 pts), ternaries 7 (9 pts), boolean chains 3, error handling 2 (nesting depth added 5). Of this number, 26 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · Modal.BaseModal (cognitive 27) · ×1
  • Modal.BaseModal (cognitive 27) code/core/src/components/components/Modal/Modal.tsx:78 — Modal.BaseModal has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 10, ternaries 2 (nesting depth added 3). Most of this is not in the body itself: 10 of the 27 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 196, 165, 175, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · summarizeIndex.summarizeIndex (cognitive 27) · ×1
  • summarizeIndex.summarizeIndex (cognitive 27) code/core/src/core-server/utils/summarizeIndex.ts:28 — summarizeIndex.summarizeIndex has cognitive complexity 27 (threshold 15). Drivers by points: if/else 17 (26 pts), boolean chains 1 (nesting depth added 9). None of this is in the body itself: all 27 points belong to 2 function literals inside it that branch (lines 43, 89). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · render-components-manifest.renderSubcomponentNote (cognitive 27) · ×1
  • render-components-manifest.renderSubcomponentNote (cognitive 27) code/core/src/core-server/utils/manifests/render-components-manifest.ts:1313 — render-components-manifest.renderSubcomponentNote has cognitive complexity 27 (threshold 15). Drivers by points: ternaries 18 (26 pts), boolean chains 1 (nesting depth added 8). Of this number, 25 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · render-components-manifest.serializeTsType (cognitive 27) · ×1
  • render-components-manifest.serializeTsType (cognitive 27) code/core/src/core-server/utils/manifests/render-components-manifest.ts:1472 — render-components-manifest.serializeTsType has cognitive complexity 27 (threshold 15). Drivers by points: if/else 14 (21 pts), boolean chains 3, ternaries 1 (3 pts) (nesting depth added 9). Of this number, 24 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · save-story.initializeSaveStory (cognitive 27) · ×1
  • save-story.initializeSaveStory (cognitive 27) code/core/src/core-server/utils/save-story/save-story.ts:33 — save-story.initializeSaveStory has cognitive complexity 27 (threshold 15). Drivers by points: ternaries 5 (10 pts), boolean chains 8, if/else 7 (8 pts), error handling 1 (nesting depth added 6). None of this is in the body itself: all 27 points belong to 2 function literals inside it that branch (lines 34, 61). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · Viewport.Viewport (cognitive 27) · ×1
  • Viewport.Viewport (cognitive 27) code/core/src/manager/components/preview/Viewport.tsx:200 — Viewport.Viewport has cognitive complexity 27 (threshold 15). Drivers by points: boolean chains 18, if/else 5, ternaries 4. Most of this is not in the body itself: 8 of the 27 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 224, 275, 243). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · server-only-stub.collectExports (cognitive 27) · ×1
  • server-only-stub.collectExports (cognitive 27) code/frameworks/tanstack-react/src/plugins/server-only-stub.ts:53 — server-only-stub.collectExports has cognitive complexity 27 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 3 (6 pts), ternaries 1 (3 pts), boolean chains 2, error handling 1 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · generate-docgen.convertType (cognitive 27) · ×1
  • generate-docgen.convertType (cognitive 27) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts:73 — generate-docgen.convertType has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 5, ternaries 2 (4 pts) (nesting depth added 4). Of this number, 24 points are the body's own statements and 3 belong to 3 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · parse-type-text.parseTypeText (cognitive 27) · ×1
  • parse-type-text.parseTypeText (cognitive 27) code/renderers/web-components/src/docgen/component-docgen/arg-types/parse-type-text.ts:31 — parse-type-text.parseTypeText has cognitive complexity 27 (threshold 15). Drivers by points: if/else 12 (18 pts), ternaries 3 (8 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ComponentMetaProject.extractPropsFromStories (cognitive 27) · ×1
  • ComponentMetaProject.extractPropsFromStories (cognitive 27) code/renderers/react/src/componentManifest/componentMeta/ComponentMetaProject.ts:168 — ComponentMetaProject.extractPropsFromStories has cognitive complexity 27 (threshold 15). Drivers by points: if/else 11 (20 pts), boolean chains 3, error handling 1 (2 pts), loops 1, ternaries 1 (nesting depth added 10). Of this number, 26 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · import-source.findMeta (cognitive 27) · ×1
  • import-source.findMeta (cognitive 27) code/renderers/svelte/src/svelte-csf/utils/import-source.ts:76 — import-source.findMeta has cognitive complexity 27 (threshold 15). Drivers by points: if/else 6 (15 pts), boolean chains 6, loops 2 (4 pts), ternaries 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · classify-args.classifyArg (cognitive 27) · ×1
  • classify-args.classifyArg (cognitive 27) code/renderers/vue3/src/docgen/story-docs/classify-args/classify-args.ts:127 — classify-args.classifyArg has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 4 (7 pts), boolean chains 5 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · compare_stats.draw_curves (cognitive 27) · ×1
  • compare_stats.draw_curves (cognitive 27) agent-eval/scripts/compare_stats.py:340 — compare_stats.draw_curves has cognitive complexity 27 (threshold 15). Drivers by points: if/else 5 (16 pts), loops 3 (6 pts), boolean chains 5 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · templates.replaceWorkspaceSpecs (cognitive 26) · ×1
  • templates.replaceWorkspaceSpecs (cognitive 26) agent-eval/lib/templates.ts:563 — templates.replaceWorkspaceSpecs has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (19 pts), loops 3 (6 pts), boolean chains 1 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · identify.createResolver · ×1
  • identify.createResolver::memberOf (cognitive 26) agent-eval/lib/agentic-reference/metrics/ds-coverage/identify.ts:449 — identify.createResolver::memberOf has cognitive complexity 26 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 6, ternaries 3 (6 pts), loops 1 (2 pts), match/switch 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · misuse.collectMisusePanel (cognitive 26) · ×1
  • misuse.collectMisusePanel (cognitive 26) agent-eval/lib/agentic-reference/comparison/misuse.ts:191 — misuse.collectMisusePanel has cognitive complexity 26 (threshold 15). Drivers by points: ternaries 3 (11 pts), if/else 2 (7 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 16). Of this number, 17 points are the body's own statements and 9 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · index.normaliseWebpackAlias (cognitive 26) · ×1
  • index.normaliseWebpackAlias (cognitive 26) code/builders/builder-webpack5/src/change-detection-adapter/index.ts:71 — index.normaliseWebpackAlias has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (11 pts), ternaries 4 (10 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · componentMetaExtractor.unwrapToFunction (cognitive 26) · ×1
  • componentMetaExtractor.unwrapToFunction (cognitive 26) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:759 — componentMetaExtractor.unwrapToFunction has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 4, ternaries 1 (3 pts), loops 1 (2 pts) (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · NumericInput.NumericInput (cognitive 26) · ×1
  • NumericInput.NumericInput (cognitive 26) code/core/src/manager/components/preview/NumericInput.tsx:82 — NumericInput.NumericInput has cognitive complexity 26 (threshold 15). Drivers by points: boolean chains 10, ternaries 6 (9 pts), if/else 7 (nesting depth added 3). Most of this is not in the body itself: 7 of the 26 points are its own statements and the rest belongs to 8 function literals inside it that branch (lines 160, 121, 111, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · preset.default (cognitive 26) · ×1
  • preset.default (cognitive 26) code/frameworks/nextjs/src/babel/preset.ts:68 — preset.default has cognitive complexity 26 (threshold 15). Drivers by points: boolean chains 22, if/else 2, ternaries 2. Of this number, 23 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · jsxDecorator.renderJsx (cognitive 26) · ×1
  • jsxDecorator.renderJsx (cognitive 26) code/renderers/react/src/docs/jsxDecorator.tsx:88 — jsxDecorator.renderJsx has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 6, ternaries 2, loops 1 (nesting depth added 6). Of this number, 21 points are the body's own statements and 5 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · named-type-detail.createNamedTypeDetailResolver (cognitive 26) · ×1
  • named-type-detail.createNamedTypeDetailResolver (cognitive 26) code/renderers/vue3/src/docgen/component-docgen/arg-types/named-type-detail.ts:35 — named-type-detail.createNamedTypeDetailResolver has cognitive complexity 26 (threshold 15). Drivers by points: if/else 14 (17 pts), ternaries 6, boolean chains 2, loops 1 (nesting depth added 3). Most of this is not in the body itself: 2 of the 26 points are its own statements and the rest belongs to 7 function items inside it that branch (a function literal at line 126, a function literal at line 89, resolveQualifiedName, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · extractArgTypes.convertVueComponentMetaProp (cognitive 26) · ×1
  • extractArgTypes.convertVueComponentMetaProp (cognitive 26) code/renderers/vue3/src/docgen/component-docgen/arg-types/extractArgTypes.ts:205 — extractArgTypes.convertVueComponentMetaProp has cognitive complexity 26 (threshold 15). Drivers by points: if/else 13 (23 pts), boolean chains 2, match/switch 1 (nesting depth added 10). Of this number, 20 points are the body's own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · compare_stats.write_report (cognitive 26) · ×1
  • compare_stats.write_report (cognitive 26) agent-eval/scripts/compare_stats.py:408 — compare_stats.write_report has cognitive complexity 26 (threshold 15). Drivers by points: if/else 13 (16 pts), loops 3 (4 pts), boolean chains 3, ternaries 2 (3 pts) (nesting depth added 5). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · multipliers.solveMultipliers (cognitive 25) · ×1
  • multipliers.solveMultipliers (cognitive 25) agent-eval/lib/agentic-reference/metrics/ds-coverage/multipliers.ts:21 — multipliers.solveMultipliers has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 8 (12 pts) (nesting depth added 10). Of this number, 17 points are the body's own statements and 8 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · prompt-functions.spinner (cognitive 25) · ×1
  • prompt-functions.spinner (cognitive 25) code/core/src/node-logger/prompts/prompt-functions.ts:122 — prompt-functions.spinner has cognitive complexity 25 (threshold 15). Drivers by points: if/else 12 (23 pts), ternaries 1 (2 pts) (nesting depth added 12). Most of this is not in the body itself: 4 of the 25 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 183, 128, 135, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · render-components-manifest.renderComponentsManifest (cognitive 25) · ×1
  • render-components-manifest.renderComponentsManifest (cognitive 25) code/core/src/core-server/utils/manifests/render-components-manifest.ts:63 — render-components-manifest.renderComponentsManifest has cognitive complexity 25 (threshold 15). Drivers by points: ternaries 15 (19 pts), boolean chains 6 (nesting depth added 4). Of this number, 21 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · members.visitClassMembers (cognitive 25) · ×1
  • members.visitClassMembers (cognitive 25) code/lib/angular-cm/src/analyzer/members.ts:82 — members.visitClassMembers has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (15 pts), ternaries 2 (6 pts), boolean chains 3, loops 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · addon-svelte-csf-to-core.storyTagAttributes (cognitive 25) · ×1
  • addon-svelte-csf-to-core.storyTagAttributes (cognitive 25) code/lib/cli-storybook/src/automigrate/fixes/addon-svelte-csf-to-core.ts:56 — addon-svelte-csf-to-core.storyTagAttributes has cognitive complexity 25 (threshold 15). Drivers by points: if/else 12 (21 pts), boolean chains 3, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · build-story-docs.snippetArg (cognitive 25) · ×1
  • build-story-docs.snippetArg (cognitive 25) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts:178 — build-story-docs.snippetArg has cognitive complexity 25 (threshold 15). Drivers by points: boolean chains 9, ternaries 4 (8 pts), if/else 5 (7 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · churn.computeChurn (cognitive 24) · ×1
  • churn.computeChurn (cognitive 24) agent-eval/lib/agentic-reference/metrics/churn.ts:170 — churn.computeChurn has cognitive complexity 24 (threshold 15). Drivers by points: if/else 6 (15 pts), boolean chains 4, ternaries 3, loops 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · claude-browser-mock.handleFormInput (cognitive 24) · ×1
  • claude-browser-mock.handleFormInput (cognitive 24) agent-eval/lib/mcp/claude-browser-mock.mjs:1569 — claude-browser-mock.handleFormInput has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (13 pts), ternaries 3 (7 pts), boolean chains 3, error handling 1 (nesting depth added 5). Most of this is not in the body itself: 7 of the 24 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 1573, 1583, 1590). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · refs.init (cognitive 24) · ×1
  • refs.init (cognitive 24) code/core/src/manager-api/modules/refs.ts:195 — refs.init has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8, ternaries 7 (8 pts), boolean chains 6, loops 1 (2 pts) (nesting depth added 2). Most of this is not in the body itself: 3 of the 24 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 229, 325, 384). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · Editor.moveValue (cognitive 24) · ×1
  • Editor.moveValue (cognitive 24) code/core/src/csf-tools/CsfObject.ts:615 — Editor.moveValue has cognitive complexity 24 (threshold 15). Drivers by points: if/else 14, boolean chains 6, ternaries 2 (4 pts) (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · resolve-members.exportedBinding (cognitive 24) · ×1
  • resolve-members.exportedBinding (cognitive 24) code/core/src/csf-tools/story-shape/resolve-members.ts:788 — resolve-members.exportedBinding has cognitive complexity 24 (threshold 15). Drivers by points: if/else 5 (11 pts), ternaries 4 (7 pts), boolean chains 5, loops 1 (nesting depth added 9). Of this number, 21 points are the body's own statements and 3 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · sync-main-preview-addons.syncPreviewAddonsWithMainConfig (cognitive 24) · ×1
  • sync-main-preview-addons.syncPreviewAddonsWithMainConfig (cognitive 24) code/core/src/common/utils/sync-main-preview-addons.ts:31 — sync-main-preview-addons.syncPreviewAddonsWithMainConfig has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 5, loops 1 (nesting depth added 8). Of this number, 23 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · create-tools.createTools (cognitive 24) · ×1
  • create-tools.createTools (cognitive 24) code/core/src/cli/tools/sdk/create-tools.ts:103 — create-tools.createTools has cognitive complexity 24 (threshold 15). Drivers by points: if/else 3 (10 pts), error handling 3 (7 pts), ternaries 2 (6 pts), match/switch 1 (nesting depth added 15). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · ChangeDetectionService.buildStatuses (cognitive 24) · ×1
  • ChangeDetectionService.buildStatuses (cognitive 24) code/core/src/core-server/change-detection/change-detection-service.ts:371 — ChangeDetectionService.buildStatuses has cognitive complexity 24 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 4 (7 pts), ternaries 2 (7 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · status.getGroupDualStatus (cognitive 24) · ×1
  • status.getGroupDualStatus (cognitive 24) code/core/src/manager/utils/status.tsx:192 — status.getGroupDualStatus has cognitive complexity 24 (threshold 15). Drivers by points: if/else 5 (9 pts), ternaries 2 (7 pts), loops 3 (6 pts), boolean chains 2 (nesting depth added 12). Of this number, 22 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · FilterPanel.FilterPanel (cognitive 24) · ×1
  • FilterPanel.FilterPanel (cognitive 24) code/core/src/manager/components/sidebar/FilterPanel.tsx:42 — FilterPanel.FilterPanel has cognitive complexity 24 (threshold 15). Drivers by points: boolean chains 14, if/else 5, ternaries 4 (5 pts) (nesting depth added 1). Most of this is not in the body itself: 11 of the 24 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 86, 59, 72, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · createFromRawDefaultProp.functionResolver (cognitive 24) · ×1
  • createFromRawDefaultProp.functionResolver (cognitive 24) code/renderers/react/src/docs/lib/defaultValues/createFromRawDefaultProp.ts:98 — createFromRawDefaultProp.functionResolver has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (19 pts), boolean chains 2, error handling 1 (2 pts), ternaries 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · inheritance.instantiateProperty (cognitive 24) · ×1
  • inheritance.instantiateProperty (cognitive 24) code/lib/angular-cm/src/analyzer/inheritance.ts:171 — inheritance.instantiateProperty has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 3, loops 1 (3 pts), ternaries 2 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · inheritance.instantiateMethod (cognitive 24) · ×1
  • inheritance.instantiateMethod (cognitive 24) code/lib/angular-cm/src/analyzer/inheritance.ts:266 — inheritance.instantiateMethod has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (20 pts), loops 1 (2 pts), boolean chains 1, ternaries 1 (nesting depth added 12). Of this number, 23 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · metroConfig.transformMetroConfigSource (cognitive 24) · ×1
  • metroConfig.transformMetroConfigSource (cognitive 24) code/lib/create-storybook/src/generators/REACT_NATIVE/metroConfig.ts:210 — metroConfig.transformMetroConfigSource has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (19 pts), boolean chains 4, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · argtypes.compareArgTypes (cognitive 24) · ×1
  • argtypes.compareArgTypes (cognitive 24) code/lib/docgen-harness/src/compare/argtypes.ts:39 — argtypes.compareArgTypes has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 4, ternaries 2 (4 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · build-package.run (cognitive 24) · ×1
  • build-package.run (cognitive 24) scripts/build-package.ts:31 — build-package.run has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 7, loops 2 (3 pts), ternaries 3 (nesting depth added 4). Of this number, 17 points are the body's own statements and 7 belong to 6 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · codemod.transformSvelteCsfNextFile (cognitive 24) · ×1
  • codemod.transformSvelteCsfNextFile (cognitive 24) scripts/snippets/codemod.ts:196 — codemod.transformSvelteCsfNextFile has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 5, ternaries 3 (5 pts), loops 2 (nesting depth added 7). Of this number, 21 points are the body's own statements and 3 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Object.ObjectControl (cognitive 23) · ×1
  • Object.ObjectControl (cognitive 23) code/addons/docs/src/blocks/controls/Object.tsx:166 — Object.ObjectControl has cognitive complexity 23 (threshold 15). Drivers by points: boolean chains 9, ternaries 6 (9 pts), if/else 4, error handling 1 (nesting depth added 3). Of this number, 13 points are the body's own statements and 10 belong to 6 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · TourGuide.TourGuide (cognitive 23) · ×1
  • TourGuide.TourGuide (cognitive 23) code/core/src/manager/components/TourGuide/TourGuide.tsx:71 — TourGuide.TourGuide has cognitive complexity 23 (threshold 15). Drivers by points: if/else 9 (10 pts), ternaries 9, boolean chains 4 (nesting depth added 1). Most of this is not in the body itself: 8 of the 23 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 151, 109, 128, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · editor.removeFromList (cognitive 23) · ×1
  • editor.removeFromList (cognitive 23) code/core/src/csf-tools/estree/editor.ts:1227 — editor.removeFromList has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 3, loops 2 (3 pts), ternaries 1 (3 pts) (nesting depth added 9). Of this number, 22 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · imports.setImport (cognitive 23) · ×1
  • imports.setImport (cognitive 23) code/core/src/csf-tools/estree/imports.ts:147 — imports.setImport has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 8, ternaries 2 (nesting depth added 3). Of this number, 16 points are the body's own statements and 7 belong to 3 function items inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · resolve-members.declaredMembers (cognitive 23) · ×1
  • resolve-members.declaredMembers (cognitive 23) code/core/src/csf-tools/story-shape/resolve-members.ts:521 — resolve-members.declaredMembers has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (11 pts), ternaries 3 (8 pts), boolean chains 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · resolve-meta-component.findImport (cognitive 23) · ×1
  • resolve-meta-component.findImport (cognitive 23) code/core/src/common/utils/resolve-meta-component.ts:156 — resolve-meta-component.findImport has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (17 pts), loops 2 (3 pts), ternaries 1 (3 pts) (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · access-provider.resolveComponentEntry (cognitive 23) · ×1
  • access-provider.resolveComponentEntry (cognitive 23) code/core/src/shared/open-service/toolsets/docs/access-provider.ts:317 — access-provider.resolveComponentEntry has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (9 pts), ternaries 7 (9 pts), boolean chains 3, loops 1 (2 pts) (nesting depth added 5). Of this number, 22 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · manager.default (cognitive 23) · ×1
  • manager.default (cognitive 23) code/core/src/controls/manager.tsx:24 — manager.default has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 4, error handling 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 9). Most of this is not in the body itself: 3 of the 23 points are its own statements and the rest belongs to 5 function items inside it that branch (saveStory, a function literal at line 140, createStory, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · previewThumbnailState.thumbnailReducer (cognitive 23) · ×1
  • previewThumbnailState.thumbnailReducer (cognitive 23) code/core/src/manager/components/review/components/previewThumbnailState.ts:45 — previewThumbnailState.thumbnailReducer has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (13 pts), ternaries 2 (6 pts), boolean chains 3, match/switch 1 (nesting depth added 11). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · preset.viteFinal (cognitive 23) · ×1
  • preset.viteFinal (cognitive 23) code/frameworks/angular-vite/src/preset.ts:81 — preset.viteFinal has cognitive complexity 23 (threshold 15). Drivers by points: ternaries 8, boolean chains 7, if/else 6, error handling 1 (2 pts) (nesting depth added 1). Of this number, 21 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · svelte-csf-to-csf-factory.transformModuleScript (cognitive 23) · ×1
  • svelte-csf-to-csf-factory.transformModuleScript (cognitive 23) code/lib/cli-storybook/src/codemod/helpers/svelte-csf-to-csf-factory.ts:132 — svelte-csf-to-csf-factory.transformModuleScript has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 4, loops 2 (4 pts), ternaries 2, error handling 1 (nesting depth added 6). Of this number, 20 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · sourceDecorator.generatePropsSourceCode (cognitive 23) · ×1
  • sourceDecorator.generatePropsSourceCode (cognitive 23) code/renderers/vue3/src/docgen/story-docs/source-decorator/sourceDecorator.ts:207 — sourceDecorator.generatePropsSourceCode has cognitive complexity 23 (threshold 15). Drivers by points: if/else 10 (11 pts), ternaries 4 (8 pts), loops 1 (2 pts), boolean chains 1, match/switch 1 (nesting depth added 6). None of this is in the body itself: all 23 points belong to 3 function literals inside it that branch (lines 227, 307, 273). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · sandbox-parts.addStories (cognitive 23) · ×1
  • sandbox-parts.addStories (cognitive 23) scripts/tasks/sandbox-parts.ts:713 — sandbox-parts.addStories has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 4, loops 1 (2 pts), ternaries 1 (2 pts) (nesting depth added 6). Of this number, 17 points are the body's own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · owner.ownerName (cognitive 22) · ×1
  • owner.ownerName (cognitive 22) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/owner.ts:24 — owner.ownerName has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 5, ternaries 1 (4 pts), loops 2 (3 pts) (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CompositionAuth.createManifestProvider (cognitive 22) · ×1
  • CompositionAuth.createManifestProvider (cognitive 22) code/addons/mcp/src/auth/composition-auth.ts:172 — CompositionAuth.createManifestProvider has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 4, ternaries 2, error handling 1 (nesting depth added 7). None of this is in the body itself: all 22 points belong to one function literal inside it that branches (line 173). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · add.add (cognitive 22) · ×1
  • add.add (cognitive 22) code/lib/cli-storybook/src/add.ts:87 — add.add has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 4, ternaries 2 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · DocsContext.resolveModuleExport (cognitive 22) · ×1
  • DocsContext.resolveModuleExport (cognitive 22) code/core/src/preview-api/modules/preview-web/docs-context/DocsContext.ts:162 — DocsContext.resolveModuleExport has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (14 pts), ternaries 2 (4 pts), boolean chains 2, loops 1 (2 pts) (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ObjectMembers.onlyRead (cognitive 22) · ×1
  • ObjectMembers.onlyRead (cognitive 22) code/core/src/csf-tools/ObjectMembers.ts:111 — ObjectMembers.onlyRead has cognitive complexity 22 (threshold 15). Drivers by points: boolean chains 12, if/else 5 (8 pts), loops 1, match/switch 1 (nesting depth added 3). None of this is in the body itself: all 22 points belong to one function literal inside it that branches (line 112). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · index._processAndSend (cognitive 22) · ×1
  • index._processAndSend (cognitive 22) code/core/src/telemetry/index.ts:149 — index._processAndSend has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (11 pts), ternaries 2 (5 pts), boolean chains 4, error handling 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · patch-recorder.recordPatch · ×1
  • patch-recorder.recordPatch::wrap (cognitive 22) code/core/src/shared/open-service/patch-recorder.ts:183 — patch-recorder.recordPatch::wrap has cognitive complexity 22 (threshold 15). Drivers by points: if/else 18 (20 pts), boolean chains 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · MatcherResult.MatcherResult (cognitive 22) · ×1
  • MatcherResult.MatcherResult (cognitive 22) code/core/src/component-testing/components/MatcherResult.tsx:56 — MatcherResult.MatcherResult has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 7, ternaries 2 (4 pts) (nesting depth added 5). None of this is in the body itself: all 22 points belong to one function literal inside it that branches (line 74). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · AliasNormalizer.normalize (cognitive 22) · ×1
  • AliasNormalizer.normalize (cognitive 22) code/core/src/shared/open-service/services/module-graph/engine/dependency-graph/resolver-factory.ts:27 — AliasNormalizer.normalize has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (11 pts), loops 4 (10 pts), ternaries 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · pipeline.applyFixes (cognitive 22) · ×1
  • pipeline.applyFixes (cognitive 22) code/lib/cli-storybook/src/automigrate/pipeline.ts:394 — pipeline.applyFixes has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (12 pts), ternaries 2 (4 pts), error handling 2 (3 pts), loops 3 (nesting depth added 8). Of this number, 19 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · baseGenerator.baseGenerator (cognitive 22) · ×1
  • baseGenerator.baseGenerator (cognitive 22) code/lib/create-storybook/src/generators/baseGenerator.ts:132 — baseGenerator.baseGenerator has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 8 (10 pts), if/else 7 (9 pts), boolean chains 2, error handling 1 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · transform-template.appendSetupStatements (cognitive 22) · ×1
  • transform-template.appendSetupStatements (cognitive 22) code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:269 — transform-template.appendSetupStatements has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 4 (16 pts), if/else 1 (3 pts), loops 2 (3 pts) (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · transform-template.transformElement (cognitive 22) · ×1
  • transform-template.transformElement (cognitive 22) code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:386 — transform-template.transformElement has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 4, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · template-holes.resolveHoleValue (cognitive 22) · ×1
  • template-holes.resolveHoleValue (cognitive 22) code/renderers/web-components/src/docgen/story-docs/template-holes.ts:39 — template-holes.resolveHoleValue has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (10 pts), ternaries 5 (10 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · version.run (cognitive 22) · ×1
  • version.run (cognitive 22) scripts/release/version.ts:238 — version.run has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (12 pts), ternaries 3 (7 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · runBatch (cognitive 22) · ×1
  • runBatch (cognitive 22) agent-eval/lib/mcp/claude-browser-mock.mjs:1962 — runBatch has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 5 (12 pts), if/else 3 (5 pts), boolean chains 2, error handling 1 (2 pts), loops 1 (nesting depth added 10). Of this number, 20 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · complexity-cognitive.cognitiveForSource · ×1
  • complexity-cognitive.cognitiveForSource::measure::walk (cognitive 21) agent-eval/lib/agentic-reference/metrics/complexity-cognitive.ts:127 — complexity-cognitive.cognitiveForSource::measure::walk has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 4, ternaries 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · tool-taxonomy.classifyToolUse (cognitive 21) · ×1
  • tool-taxonomy.classifyToolUse (cognitive 21) agent-eval/lib/agentic-reference/metrics/tool-taxonomy.ts:331 — tool-taxonomy.classifyToolUse has cognitive complexity 21 (threshold 15). Drivers by points: if/else 4 (9 pts), ternaries 2 (5 pts), loops 2 (4 pts), boolean chains 3 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ArgsTable.ArgsTable (cognitive 21) · ×1
  • ArgsTable.ArgsTable (cognitive 21) code/addons/docs/src/blocks/components/ArgsTable/ArgsTable.tsx:335 — ArgsTable.ArgsTable has cognitive complexity 21 (threshold 15). Drivers by points: boolean chains 11, if/else 6, ternaries 4. Of this number, 12 points are the body's own statements and 9 belong to 6 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · hooks.useHook (cognitive 21) · ×1
  • hooks.useHook (cognitive 21) code/core/src/preview-api/modules/addons/hooks.ts:244 — hooks.useHook has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 4, ternaries 1 (3 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · animation-utils.pauseAnimations (cognitive 21) · ×1
  • animation-utils.pauseAnimations (cognitive 21) code/core/src/preview-api/modules/preview-web/render/animation-utils.ts:18 — animation-utils.pauseAnimations has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 5, error handling 2 (5 pts), loops 2 (nesting depth added 6). Most of this is not in the body itself: 2 of the 21 points are its own statements and the rest belongs to 3 function items inside it that branch (pauseAllAnimations, a function literal at line 70, a function literal at line 38). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · import-statements.collectSpecifier (cognitive 21) · ×1
  • import-statements.collectSpecifier (cognitive 21) code/core/src/csf-tools/story-shape/import-statements.ts:128 — import-statements.collectSpecifier has cognitive complexity 21 (threshold 15). Drivers by points: if/else 13 (18 pts), ternaries 1 (2 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · service-transport.connectRuntimeToChannel (cognitive 21) · ×1
  • service-transport.connectRuntimeToChannel (cognitive 21) code/core/src/shared/open-service/service-transport.ts:160 — service-transport.connectRuntimeToChannel has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12, boolean chains 9. None of this is in the body itself: all 21 points belong to 6 function items inside it that branch (onEntry, onSyncReply, onSyncRequest, …). Those helpers are already separate functions, so extracting the branching again is not available. To reduce it, move them out of the body to the enclosing scope, where each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · parse-react-docgen.serializeTsType (cognitive 21) · ×1
  • parse-react-docgen.serializeTsType (cognitive 21) code/core/src/shared/open-service/toolsets/docs/manifest-formatter/parse-react-docgen.ts:86 — parse-react-docgen.serializeTsType has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3, ternaries 1 (3 pts), match/switch 1 (2 pts) (nesting depth added 6). Of this number, 18 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ConfigFile._getPresetValue (cognitive 21) · ×1
  • ConfigFile._getPresetValue (cognitive 21) code/core/src/csf-tools/ConfigFile.ts:776 — ConfigFile._getPresetValue has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (18 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · dev-server.storybookDevServer (cognitive 21) · ×1
  • dev-server.storybookDevServer (cognitive 21) code/core/src/core-server/dev-server.ts:32 — dev-server.storybookDevServer has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8, ternaries 5 (8 pts), error handling 3, boolean chains 2 (nesting depth added 3). Of this number, 18 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · type-detail.namedTypeDetail (cognitive 21) · ×1
  • type-detail.namedTypeDetail (cognitive 21) code/lib/angular-cm/src/type-detail.ts:24 — type-detail.namedTypeDetail has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (18 pts), boolean chains 2, loops 1 (nesting depth added 10). Of this number, 20 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · tag-filter-api.renameSetFilterIdentifiers (cognitive 21) · ×1
  • tag-filter-api.renameSetFilterIdentifiers (cognitive 21) code/lib/cli-storybook/src/automigrate/fixes/tag-filter-api.ts:32 — tag-filter-api.renameSetFilterIdentifiers has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 3, loops 2 (3 pts), ternaries 2 (3 pts), error handling 1 (nesting depth added 6). Of this number, 12 points are the body's own statements and 9 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · argtypes.typeCurrentOrBetter (cognitive 21) · ×1
  • argtypes.typeCurrentOrBetter (cognitive 21) code/lib/docgen-harness/src/compare/argtypes.ts:243 — argtypes.typeCurrentOrBetter has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (12 pts), boolean chains 9 (nesting depth added 2). Of this number, 20 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · argtypes.splitTopLevelUnion (cognitive 21) · ×1
  • argtypes.splitTopLevelUnion (cognitive 21) code/lib/docgen-harness/src/compare/argtypes.ts:455 — argtypes.splitTopLevelUnion has cognitive complexity 21 (threshold 15). Drivers by points: if/else 12 (17 pts), boolean chains 3, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · parse-type-text.splitTopLevel (cognitive 21) · ×1
  • parse-type-text.splitTopLevel (cognitive 21) code/renderers/web-components/src/docgen/component-docgen/arg-types/parse-type-text.ts:189 — parse-type-text.splitTopLevel has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 6, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · extend.getStoryParents (cognitive 21) · ×1
  • extend.getStoryParents (cognitive 21) code/renderers/svelte/src/svelte-csf/parser/analyse/story/extend.ts:40 — extend.getStoryParents has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 4, loops 2 (nesting depth added 8). Of this number, 20 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · build-story-docs.buildStoryDocsPayload (cognitive 21) · ×1
  • build-story-docs.buildStoryDocsPayload (cognitive 21) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts:34 — build-story-docs.buildStoryDocsPayload has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 10 (15 pts), boolean chains 2, error handling 1 (2 pts), if/else 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · print-h.printChildValue (cognitive 21) · ×1
  • print-h.printChildValue (cognitive 21) code/renderers/vue3/src/docgen/story-docs/print-h/print-h.ts:434 — print-h.printChildValue has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (13 pts), boolean chains 3, ternaries 2 (3 pts), loops 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · check-package.checkProject (cognitive 21) · ×1
  • check-package.checkProject (cognitive 21) scripts/check/check-package.ts:32 — check-package.checkProject has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (15 pts), ternaries 2 (4 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · check-docs.checkRelativeLinks (cognitive 21) · ×1
  • check-docs.checkRelativeLinks (cognitive 21) scripts/docs/check-docs.ts:37 — check-docs.checkRelativeLinks has cognitive complexity 21 (threshold 15). Drivers by points: if/else 4 (14 pts), error handling 1 (3 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 13). Most of this is not in the body itself: 1 of the 21 points is its own statement and the rest belongs to one function literal inside it that branches (line 50). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · publish.publishAllPackages (cognitive 21) · ×1
  • publish.publishAllPackages (cognitive 21) scripts/release/publish.ts:92 — publish.publishAllPackages has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (15 pts), loops 2 (4 pts), error handling 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · cells.buildCells (cognitive 20) · ×1
  • cells.buildCells (cognitive 20) agent-eval/lib/agentic-reference/comparison/cells.ts:169 — cells.buildCells has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 2 (9 pts), loops 3 (6 pts), if/else 1 (3 pts), boolean chains 2 (nesting depth added 12). Of this number, 18 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · rewriteStyleSheet.rewriteRuleContainer (cognitive 20) · ×1
  • rewriteStyleSheet.rewriteRuleContainer (cognitive 20) code/addons/pseudo-states/src/preview/rewriteStyleSheet.ts:296 — rewriteStyleSheet.rewriteRuleContainer has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (15 pts), ternaries 1 (3 pts), boolean chains 1, loops 1 (nesting depth added 11). Of this number, 13 points are the body's own statements and 7 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · decorator.withBackgroundAndGrid (cognitive 20) · ×1
  • decorator.withBackgroundAndGrid (cognitive 20) code/core/src/backgrounds/decorator.ts:21 — decorator.withBackgroundAndGrid has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 11 (12 pts), boolean chains 6, if/else 2 (nesting depth added 1). Of this number, 18 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · args.map (cognitive 20) · ×1
  • args.map (cognitive 20) code/core/src/preview-api/modules/store/args.ts:15 — args.map has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 5, ternaries 1 (2 pts), match/switch 1 (nesting depth added 6). Of this number, 16 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ast.normalize (cognitive 20) · ×1
  • ast.normalize (cognitive 20) code/core/src/csf-tools/estree/ast.ts:481 — ast.normalize has cognitive complexity 20 (threshold 15). Drivers by points: if/else 4 (11 pts), loops 3 (7 pts), boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · StoryIndexGenerator.chooseDuplicate (cognitive 20) · ×1
  • StoryIndexGenerator.chooseDuplicate (cognitive 20) code/core/src/core-server/utils/StoryIndexGenerator.ts:649 — StoryIndexGenerator.chooseDuplicate has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (14 pts), ternaries 3 (4 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · ChangeDetectionService.scan (cognitive 20) · ×1
  • ChangeDetectionService.scan (cognitive 20) code/core/src/core-server/change-detection/change-detection-service.ts:301 — ChangeDetectionService.scan has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (11 pts), ternaries 2 (6 pts), boolean chains 2, error handling 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · esmWalker.isRefIdentifier (cognitive 20) · ×1
  • esmWalker.isRefIdentifier (cognitive 20) code/core/src/mocking-utils/esmWalker.ts:252 — esmWalker.isRefIdentifier has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 7 (nesting depth added 2). This file's own header attributes it to another copyright holder, so it is code this repository carries rather than code it wrote: restructuring the body in place forks it from upstream and turns every future re-sync into a manual merge. The performable moves are to leave the body as close to its upstream form as possible and keep it behind a narrow interface of your own, and to re-sync it when upstream changes — or, if it has already diverged far enough that you maintain it here, adopt it deliberately and then split the body into named stages.
D2 · Cognitive Complexity · story-docs-markup.substituteExpression (cognitive 20) · ×1
  • story-docs-markup.substituteExpression (cognitive 20) code/frameworks/angular-vite/src/docgen/story-docs-markup.ts:292 — story-docs-markup.substituteExpression has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (11 pts), ternaries 4 (7 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · project.importClosure (cognitive 20) · ×1
  • project.importClosure (cognitive 20) code/lib/angular-cm/src/project.ts:219 — project.importClosure has cognitive complexity 20 (threshold 15). Drivers by points: if/else 3 (9 pts), loops 3 (6 pts), ternaries 1 (3 pts), boolean chains 2 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · flatten-inheritance.mergeInherited (cognitive 20) · ×1
  • flatten-inheritance.mergeInherited (cognitive 20) code/renderers/web-components/src/docgen/component-docgen/manifest/flatten-inheritance.ts:157 — flatten-inheritance.mergeInherited has cognitive complexity 20 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 4 (8 pts), boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · cem-manager.buildSnapshot (cognitive 20) · ×1
  • cem-manager.buildSnapshot (cognitive 20) code/renderers/web-components/src/docgen/component-docgen/manifest/cem-manager.ts:165 — cem-manager.buildSnapshot has cognitive complexity 20 (threshold 15). Drivers by points: if/else 3 (8 pts), ternaries 2 (8 pts), loops 2 (4 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · get-font-face-declarations.getFontFaceDeclarations (cognitive 20) · ×1
  • get-font-face-declarations.getFontFaceDeclarations (cognitive 20) code/lib/vite-plugin-storybook-nextjs/src/plugins/next-font/local/get-font-face-declarations.ts:46 — get-font-face-declarations.getFontFaceDeclarations has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 8 (17 pts), if/else 2 (3 pts) (nesting depth added 10). Most of this is not in the body itself: 2 of the 20 points are its own statements and the rest belongs to 2 function items inside it that branch (getFontFaceCSS, a function literal at line 85). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · svelte-csf-file.templateParameter (cognitive 20) · ×1
  • svelte-csf-file.templateParameter (cognitive 20) code/renderers/svelte/src/docgen/story-docs/svelte-csf-file.ts:136 — svelte-csf-file.templateParameter has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (9 pts), ternaries 4 (8 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · extractArgTypes.extractFromVueDocgenApi (cognitive 20) · ×1
  • extractArgTypes.extractFromVueDocgenApi (cognitive 20) code/renderers/vue3/src/docgen/component-docgen/arg-types/extractArgTypes.ts:74 — extractArgTypes.extractFromVueDocgenApi has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (12 pts), ternaries 4 (7 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · codemod.buildSvelteCsfNextFence (cognitive 20) · ×1
  • codemod.buildSvelteCsfNextFence (cognitive 20) scripts/snippets/codemod.ts:135 — codemod.buildSvelteCsfNextFence has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 1, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · complexity-cyclomatic.nameOfFunctionLike (cognitive 19) · ×1
  • complexity-cyclomatic.nameOfFunctionLike (cognitive 19) agent-eval/lib/agentic-reference/metrics/complexity-cyclomatic.ts:43 — complexity-cyclomatic.nameOfFunctionLike has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 6, ternaries 1 (2 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · shell-parse.parseStorybookCliWorkflowCalls (cognitive 19) · ×1
  • shell-parse.parseStorybookCliWorkflowCalls (cognitive 19) agent-eval/lib/shell-parse.ts:94 — shell-parse.parseStorybookCliWorkflowCalls has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (11 pts), ternaries 1 (4 pts), boolean chains 3, loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · run-plan.main (cognitive 19) · ×1
  • run-plan.main (cognitive 19) agent-eval/scripts/run-plan.ts:390 — run-plan.main has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (13 pts), error handling 1 (2 pts), ternaries 2, boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · scope.analyzeScopes.declareLexical (cognitive 19) · ×1
  • scope.analyzeScopes.declareLexical (cognitive 19) code/core/src/csf-tools/estree/scope.ts:366 — scope.analyzeScopes.declareLexical has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 5, if/else 4 (5 pts), ternaries 2 (5 pts), loops 2 (4 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CsfFile.parse (cognitive 19) · ×1
  • CsfFile.parse (cognitive 19) REDACTED:1212 — CsfFile.parse has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 11, if/else 5 (6 pts), loops 1, match/switch 1 (nesting depth added 1). Of this number, 16 points are the body's own statements and 3 belong to 3 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · child-client.spawnChildHost (cognitive 19) · ×1
  • child-client.spawnChildHost (cognitive 19) code/core/src/cli/tools/sdk/child-client.ts:73 — child-client.spawnChildHost has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8, ternaries 4 (6 pts), error handling 3, boolean chains 2 (nesting depth added 2). Most of this is not in the body itself: 9 of the 19 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 174, 147, 160). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ComponentMetaManager.watchDirectory (cognitive 19) · ×1
  • ComponentMetaManager.watchDirectory (cognitive 19) code/core/src/component-meta/ComponentMetaManager.ts:461 — ComponentMetaManager.watchDirectory has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3, loops 2, error handling 1 (nesting depth added 3). Most of this is not in the body itself: 9 of the 19 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 486, 509). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · Button.Button (cognitive 19) · ×1
  • Button.Button (cognitive 19) code/core/src/components/components/Button/Button.tsx:60 — Button.Button has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 7, ternaries 7, if/else 5. Of this number, 15 points are the body's own statements and 4 belong to 3 function items inside it that branch. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · exportNameHandler.getLocalName (cognitive 19) · ×1
  • exportNameHandler.getLocalName (cognitive 19) code/renderers/react/src/componentManifest/reactDocgen/exportNameHandler.ts:56 — exportNameHandler.getLocalName has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · withTelemetry.sendTelemetryError (cognitive 19) · ×1
  • withTelemetry.sendTelemetryError (cognitive 19) code/core/src/core-server/withTelemetry.ts:101 — withTelemetry.sendTelemetryError has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (6 pts), boolean chains 4, ternaries 2 (4 pts), loops 1 (3 pts), error handling 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · SummaryScreen.SummaryScreen (cognitive 19) · ×1
  • SummaryScreen.SummaryScreen (cognitive 19) code/core/src/manager/components/review/screens/SummaryScreen.tsx:295 — SummaryScreen.SummaryScreen has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 10 (14 pts), if/else 4, boolean chains 1 (nesting depth added 4). Most of this is not in the body itself: 8 of the 19 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 456, 383, 316, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ContextMenu.ContextMenu (cognitive 19) · ×1
  • ContextMenu.ContextMenu (cognitive 19) code/core/src/manager/components/sidebar/ContextMenu.tsx:95 — ContextMenu.ContextMenu has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 5, ternaries 3 (4 pts) (nesting depth added 3). Most of this is not in the body itself: 7 of the 19 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 111, 138). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · extract.extractMockCalls (cognitive 19) · ×1
  • extract.extractMockCalls (cognitive 19) code/core/src/mocking-utils/extract.ts:112 — extract.extractMockCalls has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (9 pts), boolean chains 7, error handling 1, loops 1, ternaries 1 (nesting depth added 1). Of this number, 10 points are the body's own statements and 9 belong to one function item inside it that branches. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · index.parseReExports (cognitive 19) · ×1
  • index.parseReExports (cognitive 19) code/core/src/oxc-parser/index.ts:203 — index.parseReExports has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 2 (3 pts), boolean chains 2, error handling 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · create-server-arg-types.createServerArgTypes (cognitive 19) · ×1
  • create-server-arg-types.createServerArgTypes (cognitive 19) code/renderers/svelte/src/docgen/component-docgen/arg-types/create-server-arg-types.ts:58 — create-server-arg-types.createServerArgTypes has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 7, loops 4 (6 pts), ternaries 3 (6 pts) (nesting depth added 5). Of this number, 16 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · forward-setup.collectFreeExpression (cognitive 19) · ×1
  • forward-setup.collectFreeExpression (cognitive 19) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts:355 — forward-setup.collectFreeExpression has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 11, if/else 4 (7 pts), match/switch 1 (nesting depth added 3). Of this number, 11 points are the body's own statements and 8 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · check-docs.checkHeadingHierarchy (cognitive 19) · ×1
  • check-docs.checkHeadingHierarchy (cognitive 19) scripts/docs/check-docs.ts:211 — check-docs.checkHeadingHierarchy has cognitive complexity 19 (threshold 15). Drivers by points: if/else 3 (9 pts), ternaries 2 (6 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · grade.collectGhostStoriesGrade (cognitive 19) · ×1
  • grade.collectGhostStoriesGrade (cognitive 19) scripts/eval/lib/grade.ts:263 — grade.collectGhostStoriesGrade has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 6 (13 pts), if/else 4, boolean chains 1, error handling 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · getWebpackConfig (cognitive 19) · ×1
  • getWebpackConfig (cognitive 19) code/frameworks/angular/src/server/angular-cli-webpack.js:31 — getWebpackConfig has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 5 (6 pts), if/else 4 (5 pts), other 4, boolean chains 3, error handling 1 (nesting depth added 2). Most of this is not in the body itself: 8 of the 19 points are its own statements and the rest belongs to 13 function items inside it that branch (getCustomStylesConfig, a function literal at line 112, getCustomStylesConfig::isTailwind4, …). The named helpers are already separate functions; the literals' work cannot be called, reviewed or tested from outside this body. To reduce it, move the named helpers out of the body to the enclosing scope and lift each literal's work into a named function there, so each is measured, reviewed and tested on its own, and reduce whichever one then reads as the largest.
D2 · Cognitive Complexity · (anonymous) (cognitive 19) · ×1
  • (anonymous) (cognitive 19) agent-eval/lib/checkout-registry-server.mjs:42 — (anonymous) has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (10 pts), error handling 2 (4 pts), boolean chains 3, other 1, ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · handleResizeWindow (cognitive 19) · ×1
  • handleResizeWindow (cognitive 19) agent-eval/lib/mcp/claude-browser-mock.mjs:1803 — handleResizeWindow has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 4, ternaries 2 (3 pts), error handling 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · resolve.analyzeFunctionComponent (cognitive 18) · ×1
  • resolve.analyzeFunctionComponent (cognitive 18) agent-eval/lib/agentic-reference/metrics/ds-coverage/react/resolve.ts:375 — resolve.analyzeFunctionComponent has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 3 (7 pts), if/else 3 (6 pts), boolean chains 5 (nesting depth added 7). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
D2 · Cognitive Complexity · tree-diff.diffTrees (cognitive 18) · ×1
  • tree-diff.diffTrees (cognitive 18) agent-eval/lib/agentic-reference/tree/tree-diff.ts:76 — tree-diff.diffTrees has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (8 pts), ternaries 2 (6 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · post-analysis.summarize (cognitive 18) · ×1
  • post-analysis.summarize (cognitive 18) agent-eval/lib/agentic-reference/post-analysis.ts:577 — post-analysis.summarize has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (11 pts), boolean chains 5, ternaries 1 (2 pts) (nesting depth added 2). Of this number, 16 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · claude-browser-mock.buildAccessibilityTree (cognitive 18) · ×1
  • claude-browser-mock.buildAccessibilityTree (cognitive 18) agent-eval/lib/mcp/claude-browser-mock.mjs:892 — claude-browser-mock.buildAccessibilityTree has cognitive complexity 18 (threshold 15). Drivers by points: if/else 37 (56 pts), boolean chains 24, ternaries 9 (21 pts), loops 5 (9 pts) (nesting depth added 35). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · judge-ds-misuse.main (cognitive 18) · ×1
  • judge-ds-misuse.main (cognitive 18) agent-eval/scripts/judge-ds-misuse.ts:314 — judge-ds-misuse.main has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12 (15 pts), error handling 1 (2 pts), loops 1 (nesting depth added 4). Of this number, 16 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · Number.NumberControl (cognitive 18) · ×1
  • Number.NumberControl (cognitive 18) code/addons/docs/src/blocks/controls/Number.tsx:28 — Number.NumberControl has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 4, ternaries 3 (nesting depth added 3). Most of this is not in the body itself: 4 of the 18 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 48, 89, 95). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · CompositionAuth.initialize (cognitive 18) · ×1
  • CompositionAuth.initialize (cognitive 18) code/addons/mcp/src/auth/composition-auth.ts:78 — CompositionAuth.initialize has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (12 pts), ternaries 1 (3 pts), error handling 1 (2 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · ToolbarMenuSelect.ToolbarMenuSelect (cognitive 18) · ×1
  • ToolbarMenuSelect.ToolbarMenuSelect (cognitive 18) code/core/src/toolbar/components/ToolbarMenuSelect.tsx:28 — ToolbarMenuSelect.ToolbarMenuSelect has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 6, if/else 6, ternaries 4 (6 pts) (nesting depth added 2). Of this number, 9 points are the body's own statements and 9 belong to 4 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · PostMessageTransport.handleEvent (cognitive 18) · ×1
  • PostMessageTransport.handleEvent (cognitive 18) code/core/src/channels/postmessage/index.ts:382 — PostMessageTransport.handleEvent has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (8 pts), ternaries 4 (7 pts), boolean chains 2, error handling 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · scope.patternParts (cognitive 18) · ×1
  • scope.patternParts (cognitive 18) code/core/src/csf-tools/estree/scope.ts:232 — scope.patternParts has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 3 (5 pts), match/switch 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · resolve-members.assignedMembers (cognitive 18) · ×1
  • resolve-members.assignedMembers (cognitive 18) code/core/src/csf-tools/story-shape/resolve-members.ts:695 — resolve-members.assignedMembers has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 5, loops 2 (3 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · StoryIndexGenerator.extractDocs (cognitive 18) · ×1
  • StoryIndexGenerator.extractDocs (cognitive 18) code/core/src/core-server/utils/StoryIndexGenerator.ts:527 — StoryIndexGenerator.extractDocs has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 5, error handling 1, ternaries 1 (nesting depth added 5). Of this number, 13 points are the body's own statements and 5 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · withTelemetry.getErrorLevel (cognitive 18) · ×1
  • withTelemetry.getErrorLevel (cognitive 18) code/core/src/core-server/withTelemetry.ts:50 — withTelemetry.getErrorLevel has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (10 pts), ternaries 3 (7 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · duplicate-story-with-new-name.duplicateStoryWithNewName (cognitive 18) · ×1
  • duplicate-story-with-new-name.duplicateStoryWithNewName (cognitive 18) code/core/src/core-server/utils/save-story/duplicate-story-with-new-name.ts:9 — duplicate-story-with-new-name.duplicateStoryWithNewName has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (7 pts), boolean chains 5, ternaries 4 (5 pts), match/switch 1 (nesting depth added 2). Of this number, 14 points are the body's own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · component-transformer.componentTransform (cognitive 18) · ×1
  • component-transformer.componentTransform (cognitive 18) code/core/src/csf-tools/vitest-plugin/component-transformer.ts:214 — component-transformer.componentTransform has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (10 pts), ternaries 2 (4 pts), boolean chains 3, loops 1 (nesting depth added 4). Of this number, 10 points are the body's own statements and 8 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · authored-source.authoredSource (cognitive 18) · ×1
  • authored-source.authoredSource (cognitive 18) code/core/src/csf-tools/story-shape/authored-source.ts:22 — authored-source.authoredSource has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Menu.useMenu (cognitive 18) · ×1
  • Menu.useMenu (cognitive 18) code/core/src/manager/container/Menu.tsx:32 — Menu.useMenu has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 15, boolean chains 3. None of this is in the body itself: all 18 points belong to 12 function literals inside it that branch (lines 217, 95, 108, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · index.parseBarrelInfo (cognitive 18) · ×1
  • index.parseBarrelInfo (cognitive 18) code/core/src/oxc-parser/index.ts:60 — index.parseBarrelInfo has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 2 (3 pts), boolean chains 1, error handling 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · toHaveLiveRegion.toHaveLiveRegion (cognitive 18) · ×1
  • toHaveLiveRegion.toHaveLiveRegion (cognitive 18) code/core/src/shared/utils/toHaveLiveRegion.ts:23 — toHaveLiveRegion.toHaveLiveRegion has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · index.commandBuilder (cognitive 18) · ×1
  • index.commandBuilder (cognitive 18) code/frameworks/angular/src/builders/start-storybook/index.ts:77 — index.commandBuilder has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 6 (7 pts), error handling 3 (6 pts), if/else 4 (5 pts) (nesting depth added 5). None of this is in the body itself: all 18 points belong to one function literal inside it that branches (line 82). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · helpers.getVariableMetasBySpecifier (cognitive 18) · ×1
  • helpers.getVariableMetasBySpecifier (cognitive 18) code/frameworks/nextjs/src/font/babel/helpers.ts:274 — helpers.getVariableMetasBySpecifier has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9, boolean chains 7, ternaries 2. None of this is in the body itself: all 18 points belong to 2 function literals inside it that branch (lines 283, 334). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · extract-arg-types.extractType (cognitive 18) · ×1
  • extract-arg-types.extractType (cognitive 18) code/lib/angular-cm/src/extract-arg-types.ts:256 — extract-arg-types.extractType has cognitive complexity 18 (threshold 15). Drivers by points: if/else 3 (7 pts), ternaries 3 (6 pts), boolean chains 4, match/switch 1 (nesting depth added 7). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
D2 · Cognitive Complexity · vitest-setup-file.extractSetupFileEntries (cognitive 18) · ×1
  • vitest-setup-file.extractSetupFileEntries (cognitive 18) code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:590 — vitest-setup-file.extractSetupFileEntries has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 5 (9 pts), if/else 3 (6 pts), loops 2 (3 pts) (nesting depth added 8). None of this is in the body itself: all 18 points belong to 2 function literals inside it that branch (lines 603, 611). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · initiate.doInitiate (cognitive 18) · ×1
  • initiate.doInitiate (cognitive 18) code/lib/create-storybook/src/initiate.ts:74 — initiate.doInitiate has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 7, if/else 6, ternaries 1 (3 pts), error handling 1 (2 pts) (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · compare-baselines.compareComponent (cognitive 18) · ×1
  • compare-baselines.compareComponent (cognitive 18) code/lib/docgen-harness/src/sandbox-baselines/compare-baselines.ts:25 — compare-baselines.compareComponent has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 3 (8 pts), if/else 4 (6 pts), boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · react-docgen-loader.actualNameHandler (cognitive 18) · ×1
  • react-docgen-loader.actualNameHandler (cognitive 18) code/presets/react-webpack/src/loaders/react-docgen-loader.ts:27 — react-docgen-loader.actualNameHandler has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (12 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · snippet-imports.readScript (cognitive 18) · ×1
  • snippet-imports.readScript (cognitive 18) code/renderers/svelte/src/docgen/story-docs/snippet-imports.ts:322 — snippet-imports.readScript has cognitive complexity 18 (threshold 15). Drivers by points: loops 4 (8 pts), if/else 3 (5 pts), boolean chains 3, ternaries 1 (2 pts) (nesting depth added 7). Of this number, 17 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · build-story-docs.storySnippet (cognitive 18) · ×1
  • build-story-docs.storySnippet (cognitive 18) code/renderers/svelte/src/docgen/story-docs/build-story-docs.ts:109 — build-story-docs.storySnippet has cognitive complexity 18 (threshold 15). Drivers by points: if/else 3 (5 pts), ternaries 4 (5 pts), boolean chains 4, loops 3 (4 pts) (nesting depth added 4). Of this number, 16 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · utils.getLineContexts (cognitive 18) · ×1
  • utils.getLineContexts (cognitive 18) scripts/docs/utils.ts:42 — utils.getLineContexts has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · run-batch.runBatch (cognitive 18) · ×1
  • run-batch.runBatch (cognitive 18) scripts/eval/run-batch.ts:151 — run-batch.runBatch has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 6 (8 pts), if/else 3 (5 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 5). Of this number, 14 points are the body's own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · baseline.loadOrBuildBaselineAnalysis (cognitive 17) · ×1
  • baseline.loadOrBuildBaselineAnalysis (cognitive 17) agent-eval/lib/post-analysis/baseline.ts:140 — baseline.loadOrBuildBaselineAnalysis has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 4 (7 pts), boolean chains 5, if/else 5 (nesting depth added 3). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · A11YPanel.A11YPanel (cognitive 17) · ×1
  • A11YPanel.A11YPanel (cognitive 17) code/addons/a11y/src/components/A11YPanel.tsx:56 — A11YPanel.A11YPanel has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 8, ternaries 6 (8 pts), if/else 1 (nesting depth added 2). Of this number, 14 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · index.starter (cognitive 17) · ×1
  • index.starter (cognitive 17) code/builders/builder-webpack5/src/index.ts:139 — index.starter has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 4 (nesting depth added 3). Most of this is not in the body itself: 6 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 172). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · generate-source-files.generateExportsFile (cognitive 17) · ×1
  • generate-source-files.generateExportsFile (cognitive 17) code/core/scripts/generate-source-files.ts:176 — generate-source-files.generateExportsFile has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (8 pts), error handling 1 (3 pts), boolean chains 2, loops 2, ternaries 1 (2 pts) (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Store.setState (cognitive 17) · ×1
  • Store.setState (cognitive 17) code/core/src/manager-api/store.ts:99 — Store.setState has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (12 pts), ternaries 1 (3 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · presets.resolveAddonName (cognitive 17) · ×1
  • presets.resolveAddonName (cognitive 17) code/core/src/common/presets.ts:78 — presets.resolveAddonName has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (9 pts), ternaries 4 (6 pts), boolean chains 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · JsPackageManagerFactory.getPackageManagerType (cognitive 17) · ×1
  • JsPackageManagerFactory.getPackageManagerType (cognitive 17) code/core/src/common/js-package-manager/JsPackageManagerFactory.ts:57 — JsPackageManagerFactory.getPackageManagerType has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8, boolean chains 7, ternaries 1 (2 pts) (nesting depth added 1). Of this number, 15 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · ObjectMembers.lookupProperty (cognitive 17) · ×1
  • ObjectMembers.lookupProperty (cognitive 17) code/core/src/csf-tools/ObjectMembers.ts:25 — ObjectMembers.lookupProperty has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 3, ternaries 1 (2 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · resolve-members.membersOf (cognitive 17) · ×1
  • resolve-members.membersOf (cognitive 17) code/core/src/csf-tools/story-shape/resolve-members.ts:198 — resolve-members.membersOf has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (9 pts), loops 3 (5 pts), boolean chains 3 (nesting depth added 7). Of this number, 16 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · toolset-registry.assertNoDerivedNameCollisions (cognitive 17) · ×1
  • toolset-registry.assertNoDerivedNameCollisions (cognitive 17) code/core/src/shared/open-service/toolset-registry.ts:30 — toolset-registry.assertNoDerivedNameCollisions has cognitive complexity 17 (threshold 15). Drivers by points: if/else 3 (8 pts), loops 3 (6 pts), error handling 1 (2 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · IncrementalPatcher.patch (cognitive 17) · ×1
  • IncrementalPatcher.patch (cognitive 17) code/core/src/shared/open-service/services/module-graph/engine/dependency-graph/incremental-patcher.ts:91 — IncrementalPatcher.patch has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (13 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · reactDocgenTypescript.getExportNameMap (cognitive 17) · ×1
  • reactDocgenTypescript.getExportNameMap (cognitive 17) code/renderers/react/src/componentManifest/reactDocgenTypescript.ts:114 — reactDocgenTypescript.getExportNameMap has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 3, ternaries 1 (2 pts), loops 1 (nesting depth added 7). Of this number, 15 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · componentMetaExtractor.resolvePropsFromComponentExport (cognitive 17) · ×1
  • componentMetaExtractor.resolvePropsFromComponentExport (cognitive 17) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:523 — componentMetaExtractor.resolvePropsFromComponentExport has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 2, ternaries 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · componentMetaExtractor.unwrapToFunctionAST (cognitive 17) · ×1
  • componentMetaExtractor.unwrapToFunctionAST (cognitive 17) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1802 — componentMetaExtractor.unwrapToFunctionAST has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · manifests.registerManifests (cognitive 17) · ×1
  • manifests.registerManifests (cognitive 17) REDACTED:380 — manifests.registerManifests has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 4 (7 pts), if/else 5, boolean chains 3, error handling 2 (nesting depth added 3). None of this is in the body itself: all 17 points belong to 2 function literals inside it that branch (lines 390, 421). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ai-setup-channel.initAIAnalyticsChannel (cognitive 17) · ×1
  • ai-setup-channel.initAIAnalyticsChannel (cognitive 17) code/core/src/core-server/server-channel/ai-setup-channel.ts:20 — ai-setup-channel.initAIAnalyticsChannel has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 3, ternaries 1 (2 pts), error handling 1, loops 1 (nesting depth added 2). None of this is in the body itself: all 17 points belong to one function literal inside it that branches (line 26). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · status.getGroupStatus (cognitive 17) · ×1
  • status.getGroupStatus (cognitive 17) code/core/src/manager/utils/status.tsx:139 — status.getGroupStatus has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 2 (3 pts), ternaries 1 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · preset.angularOptionsPlugin.transform (cognitive 17) · ×1
  • preset.angularOptionsPlugin.transform (cognitive 17) code/frameworks/angular-vite/src/preset.ts:481 — preset.angularOptionsPlugin.transform has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (8 pts), ternaries 2 (7 pts), boolean chains 2 (nesting depth added 9). Most of this is not in the body itself: 6 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 487). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · component-declaration.ioMapEntries (cognitive 17) · ×1
  • component-declaration.ioMapEntries (cognitive 17) code/lib/angular-cm/src/analyzer/component-declaration.ts:102 — component-declaration.ioMapEntries has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 5 (10 pts), boolean chains 3, if/else 2 (3 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · addon-svelte-csf-to-core.mergeImports (cognitive 17) · ×1
  • addon-svelte-csf-to-core.mergeImports (cognitive 17) code/lib/cli-storybook/src/automigrate/fixes/addon-svelte-csf-to-core.ts:178 — addon-svelte-csf-to-core.mergeImports has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 2 (6 pts), if/else 3 (5 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · index.runCodemod (cognitive 17) · ×1
  • index.runCodemod (cognitive 17) code/lib/codemod/src/index.ts:28 — index.runCodemod has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 2, ternaries 1 (2 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · snippets-svelte.findOpenTagEnd (cognitive 17) · ×1
  • snippets-svelte.findOpenTagEnd (cognitive 17) code/lib/docgen-harness/src/compare/snippets-svelte.ts:59 — snippets-svelte.findOpenTagEnd has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 3, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · snippets-svelte.findBalancedEnd (cognitive 17) · ×1
  • snippets-svelte.findBalancedEnd (cognitive 17) code/lib/docgen-harness/src/compare/snippets-svelte.ts:168 — snippets-svelte.findBalancedEnd has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (14 pts), boolean chains 2, loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · generate-docgen.initializerToDefaultValue (cognitive 17) · ×1
  • generate-docgen.initializerToDefaultValue (cognitive 17) code/renderers/svelte/src/docgen/component-docgen/svelte2tsx/generate-docgen.ts:155 — generate-docgen.initializerToDefaultValue has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 3, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
D2 · Cognitive Complexity · attributes.getArrayOfStringsValueFromAttribute (cognitive 17) · ×1
  • attributes.getArrayOfStringsValueFromAttribute (cognitive 17) code/renderers/svelte/src/svelte-csf/parser/analyse/story/attributes.ts:72 — attributes.getArrayOfStringsValueFromAttribute has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 3, loops 2 (3 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · svelte-csf-file.readSvelteCsfFile (cognitive 17) · ×1
  • svelte-csf-file.readSvelteCsfFile (cognitive 17) code/renderers/svelte/src/docgen/story-docs/svelte-csf-file.ts:44 — svelte-csf-file.readSvelteCsfFile has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 6 (9 pts), boolean chains 3, if/else 2 (3 pts), loops 2 (nesting depth added 4). Of this number, 14 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · template-holes.resolveArgReference (cognitive 17) · ×1
  • template-holes.resolveArgReference (cognitive 17) code/renderers/web-components/src/docgen/story-docs/template-holes.ts:169 — template-holes.resolveArgReference has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 3 (7 pts), if/else 4 (5 pts), boolean chains 4, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · story-render.runStoryRenderPass (cognitive 17) · ×1
  • story-render.runStoryRenderPass (cognitive 17) scripts/eval/lib/story-render.ts:63 — story-render.runStoryRenderPass has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (7 pts), ternaries 4 (6 pts), boolean chains 3, error handling 1 (nesting depth added 3). Of this number, 16 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · usage.collectTranscriptUsage (cognitive 16) · ×1
  • usage.collectTranscriptUsage (cognitive 16) agent-eval/lib/usage.ts:76 — usage.collectTranscriptUsage has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 3, ternaries 2, loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · shell-parse.scanShellWords · ×1
  • shell-parse.scanShellWords::readHeredocBodies (cognitive 16) agent-eval/lib/shell-parse.ts:591 — shell-parse.scanShellWords::readHeredocBodies has cognitive complexity 16 (threshold 15). Drivers by points: if/else 2 (6 pts), ternaries 2 (6 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body. This shape REPEATS in the file: one other method here (shell-parse.scanShellWords) has the same decision points, in the same order, at the same nesting depths — so this is one pattern written twice rather than two separate problems. Splitting this body alone leaves the other exactly as it is. Where these are variations on one operation, the change that clears both is the shared one: lift the common shape into a single routine the variants call, parameterised by whatever genuinely differs between them, and keep in each method only the part that is not shared.
D2 · Cognitive Complexity · tool-taxonomy.classifySegmentTokens (cognitive 16) · ×1
  • tool-taxonomy.classifySegmentTokens (cognitive 16) agent-eval/lib/agentic-reference/metrics/tool-taxonomy.ts:209 — tool-taxonomy.classifySegmentTokens has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, boolean chains 5, ternaries 1 (2 pts) (nesting depth added 1). Of this number, 15 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · run-plan.printReport (cognitive 16) · ×1
  • run-plan.printReport (cognitive 16) agent-eval/scripts/run-plan.ts:267 — run-plan.printReport has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (7 pts), loops 3 (5 pts), ternaries 2 (4 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Source.useSourceProps (cognitive 16) · ×1
  • Source.useSourceProps (cognitive 16) code/addons/docs/src/blocks/blocks/Source.tsx:127 — Source.useSourceProps has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7, ternaries 4, boolean chains 3, error handling 1 (2 pts) (nesting depth added 1). Of this number, 12 points are the body's own statements and 4 belong to one function literal inside it that branches. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · GlobalErrorModal.GlobalErrorModal (cognitive 16) · ×1
  • GlobalErrorModal.GlobalErrorModal (cognitive 16) code/addons/vitest/src/components/GlobalErrorModal.tsx:78 — GlobalErrorModal.GlobalErrorModal has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 10, ternaries 3 (6 pts) (nesting depth added 3). Of this number, 8 points are the body's own statements and 8 belong to one function literal inside it that branches. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · utils.createElement (cognitive 16) · ×1
  • utils.createElement (cognitive 16) REDACTED:8 — utils.createElement has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 2, error handling 1, ternaries 1 (nesting depth added 5). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 13, 35, 17). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · useHighlights.useHighlights · ×1
  • useHighlights.useHighlights::renderMenu (cognitive 16) code/core/src/highlight/useHighlights.ts:310 — useHighlights.useHighlights::renderMenu has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (9 pts), ternaries 3 (5 pts), boolean chains 2 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · ObjectMembers.carriedSpreads (cognitive 16) · ×1
  • ObjectMembers.carriedSpreads (cognitive 16) code/core/src/csf-tools/ObjectMembers.ts:219 — ObjectMembers.carriedSpreads has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), ternaries 2 (4 pts), boolean chains 1, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · CsfFile._visitExpressionStatement (cognitive 16) · ×1
  • CsfFile._visitExpressionStatement (cognitive 16) REDACTED:1081 — CsfFile._visitExpressionStatement has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (9 pts), ternaries 2 (4 pts), boolean chains 3 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · AddonVitestService.installPlaywright (cognitive 16) · ×1
  • AddonVitestService.installPlaywright (cognitive 16) code/core/src/cli/AddonVitestService.ts:150 — AddonVitestService.installPlaywright has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (12 pts), ternaries 2, boolean chains 1, error handling 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · StatelessTabList.StatelessTabList (cognitive 16) · ×1
  • StatelessTabList.StatelessTabList (cognitive 16) code/core/src/components/components/Tabs/StatelessTabList.tsx:66 — StatelessTabList.StatelessTabList has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, boolean chains 5, ternaries 2. Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 129, 74, 102, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ghost-stories-channel.initGhostStoriesChannel (cognitive 16) · ×1
  • ghost-stories-channel.initGhostStoriesChannel (cognitive 16) code/core/src/core-server/server-channel/ghost-stories-channel.ts:13 — ghost-stories-channel.initGhostStoriesChannel has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (11 pts), boolean chains 3, error handling 2 (nesting depth added 2). None of this is in the body itself: all 16 points belong to 2 function literals inside it that branch (lines 32, 15). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · render.readRender (cognitive 16) · ×1
  • render.readRender (cognitive 16) code/core/src/csf-tools/story-shape/render.ts:106 — render.readRender has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (7 pts), ternaries 3 (5 pts), boolean chains 3, loops 1 (nesting depth added 4). Of this number, 14 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · useChecklist.useChecklist (cognitive 16) · ×1
  • useChecklist.useChecklist (cognitive 16) code/core/src/manager/components/sidebar/useChecklist.ts:116 — useChecklist.useChecklist has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 5, loops 1 (nesting depth added 4). None of this is in the body itself: all 16 points belong to 2 function literals inside it that branch (lines 200, 242). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · ChecklistWidget.ChecklistWidget (cognitive 16) · ×1
  • ChecklistWidget.ChecklistWidget (cognitive 16) code/core/src/manager/components/sidebar/ChecklistWidget.tsx:216 — ChecklistWidget.ChecklistWidget has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 9, ternaries 4, if/else 3. Most of this is not in the body itself: 4 of the 16 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 277, 356, 240, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · Refs.Ref (cognitive 16) · ×1
  • Refs.Ref (cognitive 16) code/core/src/manager/components/sidebar/Refs.tsx:81 — Refs.Ref has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 13, ternaries 2, if/else 1. Of this number, 12 points are the body's own statements and 4 belong to 3 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · template-grammar.parseMarkup (cognitive 16) · ×1
  • template-grammar.parseMarkup (cognitive 16) code/frameworks/angular-vite/src/template-grammar.ts:181 — template-grammar.parseMarkup has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), ternaries 2 (3 pts), boolean chains 2, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · input-transform.analyzeInputTransform (cognitive 16) · ×1
  • input-transform.analyzeInputTransform (cognitive 16) code/lib/angular-cm/src/analyzer/input-transform.ts:17 — input-transform.analyzeInputTransform has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 6, ternaries 5, if/else 2 (3 pts), loops 2 (nesting depth added 1). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
D2 · Cognitive Complexity · custom-args-type.customArgsTypes (cognitive 16) · ×1
  • custom-args-type.customArgsTypes (cognitive 16) code/lib/cli-storybook/src/codemod/helpers/custom-args-type.ts:15 — custom-args-type.customArgsTypes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 3 (8 pts), loops 2 (4 pts), boolean chains 2, ternaries 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · resolve-component.resolveStoryComponent (cognitive 16) · ×1
  • resolve-component.resolveStoryComponent (cognitive 16) code/renderers/svelte/src/docgen/component-docgen/resolve-component/resolve-component.ts:142 — resolve-component.resolveStoryComponent has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (13 pts), loops 1 (2 pts), ternaries 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · component-meta.collectComponentMetaSources (cognitive 16) · ×1
  • component-meta.collectComponentMetaSources (cognitive 16) code/renderers/vue3/src/docgen/component-docgen/component-meta/component-meta.ts:110 — component-meta.collectComponentMetaSources has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (8 pts), ternaries 2 (3 pts), boolean chains 2, error handling 1 (2 pts), loops 1 (nesting depth added 3). Of this number, 8 points are the body's own statements and 8 belong to 4 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
D2 · Cognitive Complexity · VueComponentMetaProject.onFilesChanged (cognitive 16) · ×1
  • VueComponentMetaProject.onFilesChanged (cognitive 16) code/renderers/vue3/src/docgen/component-docgen/component-meta/vue-project-manager.ts:148 — VueComponentMetaProject.onFilesChanged has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (15 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · forward-setup.collectArgsReads (cognitive 16) · ×1
  • forward-setup.collectArgsReads (cognitive 16) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts:268 — forward-setup.collectArgsReads has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 6, if/else 5, ternaries 4 (5 pts) (nesting depth added 1). Most of this is not in the body itself: 2 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 276). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
D2 · Cognitive Complexity · bind-args.bindArgs (cognitive 16) · ×1
  • bind-args.bindArgs (cognitive 16) code/renderers/web-components/src/bind-args.ts:23 — bind-args.bindArgs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (13 pts), boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · html-tree.parseHtml (cognitive 16) · ×1
  • html-tree.parseHtml (cognitive 16) code/renderers/web-components/src/docgen/story-docs/html-tree.ts:52 — html-tree.parseHtml has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (11 pts), boolean chains 2, match/switch 1 (2 pts), loops 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · template-scope.addVariableAliases (cognitive 16) · ×1
  • template-scope.addVariableAliases (cognitive 16) code/renderers/web-components/src/docgen/story-docs/template-scope.ts:176 — template-scope.addVariableAliases has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (15 pts), loops 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · build-story-docs.argsSnippet (cognitive 16) · ×1
  • build-story-docs.argsSnippet (cognitive 16) code/renderers/web-components/src/docgen/story-docs/build-story-docs.ts:290 — build-story-docs.argsSnippet has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (10 pts), match/switch 1 (2 pts), ternaries 2, boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · sync-storybook-version.syncStorybookVersion (cognitive 16) · ×1
  • sync-storybook-version.syncStorybookVersion (cognitive 16) scripts/eval/sync-storybook-version.ts:108 — sync-storybook-version.syncStorybookVersion has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), boolean chains 2, loops 2, ternaries 1 (nesting depth added 5). Of this number, 14 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · event-log-collector.server (cognitive 16) · ×1
  • event-log-collector.server (cognitive 16) scripts/event-log-collector.ts:61 — event-log-collector.server has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (5 pts), ternaries 2 (5 pts), boolean chains 4, error handling 1 (2 pts) (nesting depth added 5). Of this number, 8 points are the body's own statements and 8 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · version.optionsSchema (cognitive 16) · ×1
  • version.optionsSchema (cognitive 16) scripts/release/version.ts:54 — version.optionsSchema has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 12, if/else 4. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
D2 · Cognitive Complexity · parseBatch (cognitive 16) · ×1
  • parseBatch (cognitive 16) agent-eval/lib/mcp/claude-browser-mock.mjs:1935 — parseBatch has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 3, ternaries 1 (2 pts), loops 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D23 · Boundary Type-Coupling · Cross-context type SyntaxHighlighterFormatTypes (core → docs) · ×1
  • Cross-context type SyntaxHighlighterFormatTypes (core → docs) code/addons/docs/src/blocks/blocks/SourceContainer.tsx:17 — SyntaxHighlighterFormatTypes (context core) is exposed in docs's public surface via SourceItem.format — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type SelectStoryPayload (core → links) · ×1
  • Cross-context type SelectStoryPayload (core → links) code/addons/links/src/utils.ts:26 — SelectStoryPayload (context core) is exposed in links's public surface via utils.navigate — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type PreviewAnnotation (core → vitest) · ×1
  • Cross-context type PreviewAnnotation (core → vitest) code/addons/vitest/src/node/test-manager.ts:92 — PreviewAnnotation (context core) is exposed in vitest's public surface via TestManager.previewAnnotations — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type RequestData (scripts → core) · ×1
  • Cross-context type RequestData (scripts → core) code/core/src/preview-api/modules/preview-web/Preview.tsx:372 — RequestData (context scripts) is exposed in core's public surface via Preview.onRequestArgTypesInfo — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type Entry (angular-cm → core) · ×1
  • Cross-context type Entry (angular-cm → core) code/core/src/types/modules/core-common.ts:757 — Entry (context angular-cm) is exposed in core's public surface via StorybookConfigRaw.previewAnnotations — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type StoryAnnotationsOrFn (core → react) · ×1
  • Cross-context type StoryAnnotationsOrFn (core → react) code/renderers/react/src/portable-stories.tsx:106 — StoryAnnotationsOrFn (context core) is exposed in react's public surface via portable-stories.composeStory — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type StoryAnnotationsOrFn (core → nextjs-vite) · ×1
  • Cross-context type StoryAnnotationsOrFn (core → nextjs-vite) code/frameworks/nextjs-vite/src/portable-stories.ts:90 — StoryAnnotationsOrFn (context core) is exposed in nextjs-vite's public surface via portable-stories.composeStory — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type StoryAnnotationsOrFn (core → nextjs) · ×1
  • Cross-context type StoryAnnotationsOrFn (core → nextjs) code/frameworks/nextjs/src/portable-stories.ts:90 — StoryAnnotationsOrFn (context core) is exposed in nextjs's public surface via portable-stories.composeStory — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type SBType (core → angular-compodoc) · ×1
  • Cross-context type SBType (core → angular-compodoc) code/lib/angular-compodoc/src/extract-arg-types.ts:264 — SBType (context core) is exposed in angular-compodoc's public surface via extract-arg-types.extractType — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type TemplateResult (angular-vite → docgen-harness) · ×1
  • Cross-context type TemplateResult (angular-vite → docgen-harness) code/lib/docgen-harness/src/web-components/__testfixtures__/lit-schema-warning/lit-schema-warning.ts:12 — TemplateResult (context angular-vite) is exposed in docgen-harness's public surface via LitSchemaWarning.render — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type TemplateResult (angular-vite → web-components) · ×1
  • Cross-context type TemplateResult (angular-vite → web-components) code/renderers/web-components/src/types.ts:17 — TemplateResult (context angular-vite) is exposed in web-components's public surface via StoryFnHtmlReturnType.StoryFnHtmlReturnType — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type SBType (core → web-components) · ×1
  • Cross-context type SBType (core → web-components) code/renderers/web-components/src/docgen/component-docgen/arg-types/parse-type-text.ts:7 — SBType (context core) is exposed in web-components's public surface via ParsedTypeText.type — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type SBType (core → react) · ×1
  • Cross-context type SBType (core → react) code/renderers/react/src/componentManifest/reactDocgen/utils.ts:93 — SBType (context core) is exposed in react's public surface via utils.mapCommonTypes — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type StoryAnnotationsOrFn (core → svelte) · ×1
  • Cross-context type StoryAnnotationsOrFn (core → svelte) code/renderers/svelte/src/portable-stories.ts:119 — StoryAnnotationsOrFn (context core) is exposed in svelte's public surface via portable-stories.composeStory — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type SBType (core → vue3) · ×1
  • Cross-context type SBType (core → vue3) code/renderers/vue3/src/docgen/component-docgen/arg-types/extractArgTypes.ts:205 — SBType (context core) is exposed in vue3's public surface via extractArgTypes.convertVueComponentMetaProp — couples the contexts.
D23 · Boundary Type-Coupling · Cross-context type StoryAnnotationsOrFn (core → vue3) · ×1
  • Cross-context type StoryAnnotationsOrFn (core → vue3) code/renderers/vue3/src/portable-stories.ts:107 — StoryAnnotationsOrFn (context core) is exposed in vue3's public surface via portable-stories.composeStory — couples the contexts.
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D35 · Change Coupling · Change coupling clique · ×1
  • Change coupling clique: REDACTED, REDACTED, preview.tsx, REDACTED, REDACTED code/frameworks/angular-vite/src/client/preview.ts — 5 files — `code/frameworks/angular-vite/src/client/preview.ts`, `code/frameworks/angular/src/client/preview.ts`, `code/renderers/react/src/preview.tsx`, `code/renderers/vue3/src/preview.ts`, `code/renderers/web-components/src/preview.ts` — all change together with no explicit dependency: a fully-connected co-change clique, not 10 separate couplings. They share one concern (thin parallel siblings over a common abstraction), so extract the shared part into ONE unit and the whole clique's coupling clears at once — you do not need to break each pair individually.
D35 · Change Coupling · Change-coupling hub · ×1
  • Change-coupling hub: test-utils.ts → EVAL.ts, EVAL.ts, EVAL.ts, EVAL.ts, EVAL.ts, EVAL.ts agent-eval/lib/test-utils.ts — `agent-eval/lib/test-utils.ts` changes together with 6 other files — `agent-eval/evals/802-create-component/EVAL.ts`, `agent-eval/evals/803-edit-component/EVAL.ts`, `agent-eval/evals/804-write-story-for-existing-component/EVAL.ts`, `agent-eval/evals/808-shared-infra-fallback/EVAL.ts`, `agent-eval/evals/812-first-story-empty-project/EVAL.ts`, `agent-eval/evals/813-monorepo-leaf-create-component/EVAL.ts` — none of which declares a dependency on it: one file is the hub of 6 separate couplings, not 6 unrelated pairs. Read the hub first: if the others each duplicate a part of what it does, the shared concern belongs in ONE unit and extracting it clears every edge at once; if the hub is a registry, dispatcher or barrel that must name each of them, the coupling is structural and the question is whether that list can be discovered instead of enumerated. Fixing the hub is one change; breaking the couplings one pair at a time is 6.
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
IC1 · Incompleteness & stubs · Empty method body · ×1
  • Empty method body — does nothing with its inputs code/renderers/server/src/render.ts:46 — `render` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it.
R10 · Code Duplication · Forked directory tree (11 identical files, ~1029 lines × 2 trees) · ×1
  • Forked directory tree (11 identical files, ~1029 lines × 2 trees) code/frameworks/angular-vite/src/client/renderer/StorybookModule.test.ts:1 — code/frameworks/angular-vite/src/client/renderer/ and code/frameworks/angular/src/client/angular-beta/ are near-verbatim copies of each other: 11 files are byte-identical under the same relative paths (~1029 lines; the trees hold 22 and 23 files). That is one structural fact, not 11 local ones: every edit made to one tree and not the other drifts silently, which is the failure whole-tree forks guarantee. Pick one tree as the single source and produce the other from it (generated, copied at build or release time, or re-exported) — or, if the copy is a stale snapshot nothing produces any more, delete it. Check first whether the copy is a deliberately published deliverable (a template consumers copy verbatim, a released sample frozen at a version); where it is, keep it produced from the source tree rather than edited in place.
R10 · Code Duplication · Forked directory tree (6 identical files, ~330 lines × 2 trees) · ×1
  • Forked directory tree (6 identical files, ~330 lines × 2 trees) code/frameworks/nextjs/template/stories_nextjs-default-ts/ServerActions.stories.tsx:1 — code/frameworks/nextjs/template/stories_nextjs-default-ts/ and code/frameworks/nextjs/template/stories_nextjs-prerelease/ are near-verbatim copies of each other: 6 files are byte-identical under the same relative paths (~330 lines; the trees hold 6 and 6 files). That is one structural fact, not 6 local ones: every edit made to one tree and not the other drifts silently, which is the failure whole-tree forks guarantee. Pick one tree as the single source and produce the other from it (generated, copied at build or release time, or re-exported) — or, if the copy is a stale snapshot nothing produces any more, delete it. Check first whether the copy is a deliberately published deliverable (a template consumers copy verbatim, a released sample frozen at a version); where it is, keep it produced from the source tree rather than edited in place.
R10 · Code Duplication · Forked directory tree (5 identical files, ~224 lines × 2 trees) · ×1
  • Forked directory tree (5 identical files, ~224 lines × 2 trees) code/frameworks/angular/template/stories_angular-cli-default-ts/model-signal/color-picker.stories.ts:1 — code/frameworks/angular/template/stories_angular-cli-default-ts/ and code/frameworks/angular/template/stories_angular-cli-prerelease/ are near-verbatim copies of each other: 5 files are byte-identical under the same relative paths (~224 lines; the trees hold 6 and 6 files). That is one structural fact, not 5 local ones: every edit made to one tree and not the other drifts silently, which is the failure whole-tree forks guarantee. Pick one tree as the single source and produce the other from it (generated, copied at build or release time, or re-exported) — or, if the copy is a stale snapshot nothing produces any more, delete it. Check first whether the copy is a deliberately published deliverable (a template consumers copy verbatim, a released sample frozen at a version); where it is, keep it produced from the source tree rather than edited in place.
R10 · Code Duplication · Duplication concentrated across 16 sibling directories (98 clone groups) · ×1
  • Duplication concentrated across 16 sibling directories (98 clone groups) code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts:1 — 98 duplicated blocks under code/frameworks/ have copies in at least two of the sibling directories angular, angular-vite, ember, html-vite, nextjs, nextjs-vite (+10 more sibling(s) not listed) — 72 of them are reported below, and 26 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 98 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 98 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 98 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplication concentrated across 8 sibling directories (92 clone groups) · ×1
  • Duplication concentrated across 8 sibling directories (92 clone groups) code/frameworks/html-vite/template/cli/ts/Page.ts:8 — 92 duplicated blocks under code/ have copies in at least two of the sibling directories .storybook, addons, builders, core, frameworks, lib (+2 more sibling(s) not listed) — 74 of them are reported below, and 18 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 92 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 92 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 92 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplication concentrated across 7 sibling directories (22 clone groups) · ×1
  • Duplication concentrated across 7 sibling directories (22 clone groups) code/renderers/svelte/src/parsers/svelteImportParser.ts:92 — 22 duplicated blocks under code/renderers/ have copies in at least two of the sibling directories html, preact, react, server, svelte, vue3 (+1 more sibling(s) not listed) — 14 of them are reported below, and 8 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 22 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 22 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 22 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplication concentrated across 20 sibling directories (21 clone groups) · ×1
  • Duplication concentrated across 20 sibling directories (21 clone groups) code/core/src/preview-api/modules/preview-web/parseArgsParam.ts:9 — 21 duplicated blocks under code/core/src/ have copies in at least two of the sibling directories actions, backgrounds, cli, client-logger, common, component-testing (+14 more sibling(s) not listed) — 13 of them are reported below, and 8 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 21 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 21 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 21 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplication concentrated across 21 sibling directories (16 clone groups) · ×1
  • Duplication concentrated across 21 sibling directories (16 clone groups) agent-eval/evals/803-edit-component/src/components/ReviewCard.tsx:9 — 16 duplicated blocks under agent-eval/evals/ have copies in at least two of the sibling directories 801-create-accessible-component, 802-create-component, 803-edit-component, 804-write-story-for-existing-component, 805-non-visual-refactor, 806-browse-request (+15 more sibling(s) not listed) — 13 of them are reported below, and 3 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 16 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 16 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 16 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplication concentrated across 10 sibling directories (7 clone groups) · ×1
  • Duplication concentrated across 10 sibling directories (7 clone groups) code/renderers/react/template/stories/docgen-components/ts-react-fc/input.tsx:4 — 7 duplicated blocks under code/renderers/react/template/stories/docgen-components/ have copies in at least two of the sibling directories js-class-component, js-function-component, js-function-component-inline-defaults, js-function-component-inline-defaults-no-propTypes, js-proptypes, jsdoc (+4 more sibling(s) not listed) — 4 of them are reported below, and 3 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 7 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 7 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 7 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplication concentrated across 14 sibling directories (6 clone groups) · ×1
  • Duplication concentrated across 14 sibling directories (6 clone groups) code/lib/create-storybook/src/generators/ANGULAR/index.ts:22 — 6 duplicated blocks under code/lib/create-storybook/src/generators/ have copies in at least two of the sibling directories ANGULAR, EMBER, HTML, NEXTJS, NUXT, PREACT (+8 more sibling(s) not listed) — 2 of them are reported below, and 4 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 6 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 6 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 6 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplication concentrated across 2 sibling directories (5 clone groups) · ×1
  • Duplication concentrated across 2 sibling directories (5 clone groups) code/core/src/manager/components/sidebar/SearchResults.tsx:241 — 5 duplicated blocks under code/core/src/manager/ have copies in at least two of the sibling directories components, settings — 1 of them are reported below, and 4 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 5 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 5 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 5 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplication concentrated across 5 sibling directories (5 clone groups) · ×1
  • Duplication concentrated across 5 sibling directories (5 clone groups) code/lib/angular-cm/src/extract-arg-types.ts:95 — 5 duplicated blocks under code/lib/ have copies in at least two of the sibling directories angular-cm, angular-compodoc, cli-storybook, codemod, create-storybook — 3 of them are reported below, and 2 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 5 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 5 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 5 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
R10 · Code Duplication · Duplicated block with local edits (285 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (285 matched lines × 2 locations) REDACTED:33 — REDACTED:33 · code/core/src/common/js-package-manager/NPMProxy.ts:36 — the two spans are one implementation copied and then locally edited — 1635 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block with local edits (204 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (204 matched lines × 2 locations) code/lib/angular-cm/src/extract-arg-types.ts:95 — code/lib/angular-cm/src/extract-arg-types.ts:95 · code/lib/angular-compodoc/src/extract-arg-types.ts:89 — the two spans are one implementation copied and then locally edited — 1242 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block with local edits (201 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (201 matched lines × 2 locations) code/core/src/common/js-package-manager/PNPMProxy.ts:480 — code/core/src/common/js-package-manager/PNPMProxy.ts:480 · code/core/src/common/js-package-manager/Yarn2Proxy.ts:211 — the two spans are one implementation copied and then locally edited — 1023 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block with local edits (115 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (115 matched lines × 2 locations) agent-eval/lib/agentic-reference/metrics/complexity-cognitive.ts:21 — agent-eval/lib/agentic-reference/metrics/complexity-cognitive.ts:21 · agent-eval/lib/agentic-reference/metrics/complexity-jsx.ts:46 — the two spans are one implementation copied and then locally edited — 833 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Wholesale file copy (103 identical lines × 2 files) · ×1
  • Wholesale file copy (103 identical lines × 2 files) code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts:1 — code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts:1 · code/frameworks/angular/src/client/angular-beta/utils/NgComponentAnalyzer.ts:1 — these 2 files are line-for-line copies of one another — 103 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication · Duplicated block with local edits (93 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (93 matched lines × 2 locations) code/lib/angular-cm/src/extract-arg-types.ts:434 — code/lib/angular-cm/src/extract-arg-types.ts:434 · code/lib/angular-compodoc/src/extract-arg-types.ts:430 — the two spans are one implementation copied and then locally edited — 664 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Wholesale file copy (91 identical lines × 2 files) · ×1
  • Wholesale file copy (91 identical lines × 2 files) code/frameworks/angular-vite/src/client/renderer/utils/PropertyExtractor.ts:1 — code/frameworks/angular-vite/src/client/renderer/utils/PropertyExtractor.ts:1 · code/frameworks/angular/src/client/angular-beta/utils/PropertyExtractor.ts:1 — these 2 files are line-for-line copies of one another — 91 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication · Duplicated block (91 lines × 2 locations) · ×1
  • Duplicated block (91 lines × 2 locations) code/frameworks/html-vite/template/cli/ts/Page.ts:8 — code/frameworks/html-vite/template/cli/ts/Page.ts:8 · code/renderers/html/template/cli/ts/Page.ts:8 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another.
R10 · Code Duplication · Wholesale file copy (88 identical lines × 2 files) · ×1
  • Wholesale file copy (88 identical lines × 2 files) code/frameworks/nextjs-vite/src/routing/app-router-provider.tsx:1 — code/frameworks/nextjs-vite/src/routing/app-router-provider.tsx:1 · code/frameworks/nextjs/src/routing/app-router-provider.tsx:6 — these 2 files are line-for-line copies of one another — 88 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication · Duplicated block with local edits (85 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (85 matched lines × 2 locations) scripts/build-package.ts:31 — scripts/build-package.ts:31 · scripts/check-package.ts:20 — the two spans are one implementation copied and then locally edited — 575 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block (81 lines × 2 locations) · ×1
  • Duplicated block (81 lines × 2 locations) code/core/src/components/components/Tabs/StatelessTabList.tsx:68 — code/core/src/components/components/Tabs/StatelessTabList.tsx:68 · code/core/src/components/components/Tabs/TabList.tsx:158 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported.
R10 · Code Duplication · Duplicated block (77 lines × 2 locations) · ×1
  • Duplicated block (77 lines × 2 locations) code/renderers/react/template/stories/docgen-components/ts-react-fc/input.tsx:4 — code/renderers/react/template/stories/docgen-components/ts-react-fc/input.tsx:4 · code/renderers/react/template/stories/docgen-components/ts-types/input.tsx:8 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are.
R10 · Code Duplication · Duplicated block (65 lines × 2 locations) · ×1
  • Duplicated block (65 lines × 2 locations) code/frameworks/angular-vite/src/client/decorators.ts:11 — code/frameworks/angular-vite/src/client/decorators.ts:11 · code/frameworks/angular/src/client/decorators.ts:11 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are.
R10 · Code Duplication · Duplicated block (65 lines × 3 locations) · ×1
  • Duplicated block (65 lines × 3 locations) code/frameworks/angular-vite/src/client/preview.ts:95 — code/frameworks/angular-vite/src/client/preview.ts:95 · code/frameworks/angular/src/client/preview.ts:95 · code/renderers/web-components/src/preview.ts:108 — the 3 copies are spread across 3 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are.
R10 · Code Duplication · Wholesale file copy (64 identical lines × 2 files) · ×1
  • Wholesale file copy (64 identical lines × 2 files) code/frameworks/angular-vite/src/client/preview.ts:1 — code/frameworks/angular-vite/src/client/preview.ts:1 · code/frameworks/angular/src/client/preview.ts:1 — these 2 files are line-for-line copies of one another — 64 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication · Duplicated block (64 lines × 5 locations) · ×1
  • Duplicated block (64 lines × 5 locations) code/frameworks/nextjs-vite/template/cli/ts/Page.tsx:10 — code/frameworks/nextjs-vite/template/cli/ts/Page.tsx:10 · code/frameworks/nextjs/template/cli/ts/Page.tsx:10 · code/frameworks/react-vite/template/cli/ts/Page.tsx:10 · code/frameworks/react-webpack5/template/cli/ts/Page.tsx:10 · +1 more site(s) not listed — the 5 copies are spread across 5 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. There is one copy in each of 5 separate files rather than several in one place, so check first whether these are sibling modules that each declare their own version of one shape — one per entity, per provider, per language. Where they are, no single extracted module collapses them: each module still has to be written, and what recurs is the TEMPLATE. The moves that do collapse a template are to generate these modules from the set they enumerate, or to replace the repeated construction with one factory each site calls with its own values — and where the set is the point, each module pinning one distinct thing, the repetition IS the enumeration and there is nothing to delete.
R10 · Code Duplication · Duplicated block with local edits (62 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (62 matched lines × 2 locations) code/core/src/preview-api/modules/preview-web/render/CsfDocsRender.ts:48 — code/core/src/preview-api/modules/preview-web/render/CsfDocsRender.ts:48 · code/core/src/preview-api/modules/preview-web/render/MdxDocsRender.ts:53 — the two spans are one implementation copied and then locally edited — 399 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block with local edits (61 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (61 matched lines × 2 locations) agent-eval/lib/mcp/claude-browser-mock.mjs:2007 — agent-eval/lib/mcp/claude-browser-mock.mjs:2007 · agent-eval/lib/mcp/node-repl-mock.mjs:299 — the two spans are one implementation copied and then locally edited — 377 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block (60 lines × 2 locations) · ×1
  • Duplicated block (60 lines × 2 locations) code/core/src/cli/skills/content/setup-prompts/monorepo-optimized-tests-relaxed-limits-no-story-deletion.ts:40 — code/core/src/cli/skills/content/setup-prompts/monorepo-optimized-tests-relaxed-limits-no-story-deletion.ts:40 · code/core/src/cli/skills/content/setup-prompts/monorepo.ts:40 — the 2 copies sit in sibling files in one directory, so check first whether one of them (or an existing module there) already owns this behaviour and the others should call it; otherwise extract it into one module in that directory and have each site call it.
R10 · Code Duplication · Duplicated block with local edits (60 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (60 matched lines × 2 locations) code/core/src/preview-api/modules/preview-web/parseArgsParam.ts:9 — code/core/src/preview-api/modules/preview-web/parseArgsParam.ts:9 · code/core/src/router/utils.ts:80 — the two spans are one implementation copied and then locally edited — 342 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Duplicated block with local edits (54 matched lines × 2 locations) · ×1
  • Duplicated block with local edits (54 matched lines × 2 locations) code/frameworks/nextjs-vite/src/preview.tsx:21 — code/frameworks/nextjs-vite/src/preview.tsx:21 · code/frameworks/nextjs/src/preview.tsx:22 — the two spans are one implementation copied and then locally edited — 302 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
R10 · Code Duplication · Wholesale file copy (54 identical lines × 2 files) · ×1
  • Wholesale file copy (54 identical lines × 2 files) code/frameworks/react-native-web-vite/template/cli/js/Button.jsx:2 — code/frameworks/react-native-web-vite/template/cli/js/Button.jsx:2 · code/frameworks/react-native-web-vite/template/cli/ts/Button.tsx:2 — these 2 files are line-for-line copies of one another — 54 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 85, cognitive 95) · ×1
  • Complex function (anonymous) (cyclomatic 85, cognitive 95) code/core/src/csf-tools/estree/scope.ts:569 — (anonymous) has cyclomatic complexity 85 and cognitive complexity 95; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function _visitExportNamed (cyclomatic 58, cognitive 142) · ×1
  • Complex function _visitExportNamed (cyclomatic 58, cognitive 142) REDACTED:891 — _visitExportNamed has cyclomatic complexity 58 and cognitive complexity 142; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function handleShortcutFeature (cyclomatic 51, cognitive 50) · ×1
  • Complex function handleShortcutFeature (cyclomatic 51, cognitive 50) code/core/src/manager-api/modules/shortcuts.ts:291 — handleShortcutFeature has cyclomatic complexity 51 and cognitive complexity 50; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 48, cognitive 70) · ×1
  • Complex function (anonymous) (cyclomatic 48, cognitive 70) code/core/src/csf-tools/ConfigObject.ts:81 — (anonymous) has cyclomatic complexity 48 and cognitive complexity 70; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function renderComponentCard (cyclomatic 48, cognitive 46) · ×1
  • Complex function renderComponentCard (cyclomatic 48, cognitive 46) code/core/src/core-server/utils/manifests/render-components-manifest.ts:973 — renderComponentCard has cyclomatic complexity 48 and cognitive complexity 46; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function TestProviderRender (cyclomatic 47, cognitive 43) · ×1
  • Complex function TestProviderRender (cyclomatic 47, cognitive 43) code/addons/vitest/src/components/TestProviderRender.tsx:98 — TestProviderRender has cyclomatic complexity 47 and cognitive complexity 43; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function groupValues (cyclomatic 45, cognitive 77) · ×1
  • Complex function groupValues (cyclomatic 45, cognitive 77) code/core/src/csf-tools/CsfObject.ts:692 — groupValues has cyclomatic complexity 45 and cognitive complexity 77; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function buildDevStandalone (cyclomatic 45, cognitive 60) · ×1
  • Complex function buildDevStandalone (cyclomatic 45, cognitive 60) code/core/src/core-server/build-dev.ts:75 — buildDevStandalone has cyclomatic complexity 45 and cognitive complexity 60; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function upgrade (cyclomatic 44, cognitive 71) · ×1
  • Complex function upgrade (cyclomatic 44, cognitive 71) code/lib/cli-storybook/src/upgrade.ts:352 — upgrade has cyclomatic complexity 44 and cognitive complexity 71; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function runComputerAction (cyclomatic 43, cognitive 53) · ×1
  • Complex function runComputerAction (cyclomatic 43, cognitive 53) agent-eval/lib/mcp/claude-browser-mock.mjs:1429 — runComputerAction has cyclomatic complexity 43 and cognitive complexity 53; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 41, cognitive 93) · ×1
  • Complex function (anonymous) (cyclomatic 41, cognitive 93) code/core/src/csf-tools/ConfigFile.ts:539 — (anonymous) has cyclomatic complexity 41 and cognitive complexity 93; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function transformDirective (cyclomatic 40, cognitive 45) · ×1
  • Complex function transformDirective (cyclomatic 40, cognitive 45) code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:520 — transformDirective has cyclomatic complexity 40 and cognitive complexity 45; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function generateDummyValueFromSBType (cyclomatic 40, cognitive 34) · ×1
  • Complex function generateDummyValueFromSBType (cyclomatic 40, cognitive 34) code/core/src/core-server/utils/get-dummy-args-from-argtypes.ts:146 — generateDummyValueFromSBType has cyclomatic complexity 40 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function readForwardableSetup (cyclomatic 39, cognitive 52) · ×1
  • Complex function readForwardableSetup (cyclomatic 39, cognitive 52) code/renderers/vue3/src/docgen/story-docs/transform-template/forward-setup.ts:90 — readForwardableSetup has cyclomatic complexity 39 and cognitive complexity 52; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function serializeComponentDoc (cyclomatic 38, cognitive 60) · ×1
  • Complex function serializeComponentDoc (cyclomatic 38, cognitive 60) code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1404 — serializeComponentDoc has cyclomatic complexity 38 and cognitive complexity 60; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function postInstall (cyclomatic 37, cognitive 68) · ×1
  • Complex function postInstall (cyclomatic 37, cognitive 68) code/addons/vitest/src/postinstall.ts:58 — postInstall has cyclomatic complexity 37 and cognitive complexity 68; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function runFixes (cyclomatic 37, cognitive 65) · ×1
  • Complex function runFixes (cyclomatic 37, cognitive 65) code/lib/cli-storybook/src/automigrate/index.ts:253 — runFixes has cyclomatic complexity 37 and cognitive complexity 65; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function scanShellWords (cyclomatic 37, cognitive 63) · ×1
  • Complex function scanShellWords (cyclomatic 37, cognitive 63) agent-eval/lib/shell-parse.ts:438 — scanShellWords has cyclomatic complexity 37 and cognitive complexity 63; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function parseToolsTokens (cyclomatic 35, cognitive 58) · ×1
  • Complex function parseToolsTokens (cyclomatic 35, cognitive 58) code/core/src/cli/tools/tool-tokens.ts:44 — parseToolsTokens has cyclomatic complexity 35 and cognitive complexity 58; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R2 · Cyclomatic Complexity · Complex function (anonymous) (cyclomatic 35, cognitive 43) · ×1
  • Complex function (anonymous) (cyclomatic 35, cognitive 43) code/frameworks/angular-vite/src/docgen/story-docs-args.ts:125 — (anonymous) has cyclomatic complexity 35 and cognitive complexity 43; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
R3 · Large Files · agent-eval/lib/agentic-reference/comparison/html-report.ts · ×1
  • agent-eval/lib/agentic-reference/comparison/html-report.ts: 3345 lines of code agent-eval/lib/agentic-reference/comparison/html-report.ts:1 — agent-eval/lib/agentic-reference/comparison/html-report.ts has 3345 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · agent-eval/lib/mcp/claude-browser-mock.mjs · ×1
  • agent-eval/lib/mcp/claude-browser-mock.mjs: 1966 lines of code agent-eval/lib/mcp/claude-browser-mock.mjs:1 — agent-eval/lib/mcp/claude-browser-mock.mjs has 1966 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/csf-tools/estree/editor.ts · ×1
  • code/core/src/csf-tools/estree/editor.ts: 1732 lines of code code/core/src/csf-tools/estree/editor.ts:1 — code/core/src/csf-tools/estree/editor.ts has 1732 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts · ×1
  • code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts: 1678 lines of code code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts:1 — code/renderers/react/src/componentManifest/componentMeta/componentMetaExtractor.ts has 1678 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · scripts/eval/collect-pr-data.ts · ×1
  • scripts/eval/collect-pr-data.ts: 1423 lines of code scripts/eval/collect-pr-data.ts:1 — scripts/eval/collect-pr-data.ts has 1423 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · REDACTED · ×1
  • REDACTED: 1382 lines of code REDACTED:1 — REDACTED has 1382 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/core-server/utils/manifests/render-components-manifest.ts · ×1
  • code/core/src/core-server/utils/manifests/render-components-manifest.ts: 1364 lines of code code/core/src/core-server/utils/manifests/render-components-manifest.ts:1 — code/core/src/core-server/utils/manifests/render-components-manifest.ts has 1364 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/components/components/Select/Select.stories.tsx · ×1
  • code/core/src/components/components/Select/Select.stories.tsx: 1319 lines of code code/core/src/components/components/Select/Select.stories.tsx:1 — code/core/src/components/components/Select/Select.stories.tsx has 1319 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/shared/checklist-store/checklistData.tsx · ×1
  • code/core/src/shared/checklist-store/checklistData.tsx: 1297 lines of code code/core/src/shared/checklist-store/checklistData.tsx:1 — code/core/src/shared/checklist-store/checklistData.tsx has 1297 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/manager/components/sidebar/Tree.stories.tsx · ×1
  • code/core/src/manager/components/sidebar/Tree.stories.tsx: 1276 lines of code code/core/src/manager/components/sidebar/Tree.stories.tsx:1 — code/core/src/manager/components/sidebar/Tree.stories.tsx has 1276 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/manager-api/modules/stories.ts · ×1
  • code/core/src/manager-api/modules/stories.ts: 1263 lines of code code/core/src/manager-api/modules/stories.ts:1 — code/core/src/manager-api/modules/stories.ts has 1263 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/server-errors.ts · ×1
  • code/core/src/server-errors.ts: 1192 lines of code code/core/src/server-errors.ts:1 — code/core/src/server-errors.ts has 1192 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · scripts/tasks/sandbox-parts.ts · ×1
  • scripts/tasks/sandbox-parts.ts: 1187 lines of code scripts/tasks/sandbox-parts.ts:1 — scripts/tasks/sandbox-parts.ts has 1187 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · agent-eval/lib/test-utils.ts · ×1
  • agent-eval/lib/test-utils.ts: 1140 lines of code agent-eval/lib/test-utils.ts:1 — agent-eval/lib/test-utils.ts has 1140 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/lib/cli-storybook/src/sandbox-templates.ts · ×1
  • code/lib/cli-storybook/src/sandbox-templates.ts: 1140 lines of code code/lib/cli-storybook/src/sandbox-templates.ts:1 — code/lib/cli-storybook/src/sandbox-templates.ts has 1140 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · agent-eval/lib/templates.ts · ×1
  • agent-eval/lib/templates.ts: 1080 lines of code agent-eval/lib/templates.ts:1 — agent-eval/lib/templates.ts has 1080 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/components/components/Modal/Modal.stories.tsx · ×1
  • code/core/src/components/components/Modal/Modal.stories.tsx: 1074 lines of code code/core/src/components/components/Modal/Modal.stories.tsx:1 — code/core/src/components/components/Modal/Modal.stories.tsx has 1074 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/shared/open-service/query-runtime.ts · ×1
  • code/core/src/shared/open-service/query-runtime.ts: 1059 lines of code code/core/src/shared/open-service/query-runtime.ts:1 — code/core/src/shared/open-service/query-runtime.ts has 1059 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/csf-tools/ConfigFile.ts · ×1
  • code/core/src/csf-tools/ConfigFile.ts: 1054 lines of code code/core/src/csf-tools/ConfigFile.ts:1 — code/core/src/csf-tools/ConfigFile.ts has 1054 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · scripts/eval/lib/baseline-template-files.ts · ×1
  • scripts/eval/lib/baseline-template-files.ts: 1041 lines of code scripts/eval/lib/baseline-template-files.ts:1 — scripts/eval/lib/baseline-template-files.ts has 1041 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts · ×1
  • code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts: 1005 lines of code code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts:1 — code/renderers/vue3/src/docgen/story-docs/transform-template/transform-template.ts has 1005 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/csf-tools/CsfObject.ts · ×1
  • code/core/src/csf-tools/CsfObject.ts: 936 lines of code code/core/src/csf-tools/CsfObject.ts:1 — code/core/src/csf-tools/CsfObject.ts has 936 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · agent-eval/lib/mcp/codex-browser-client-mock.mjs · ×1
  • agent-eval/lib/mcp/codex-browser-client-mock.mjs: 916 lines of code agent-eval/lib/mcp/codex-browser-client-mock.mjs:1 — agent-eval/lib/mcp/codex-browser-client-mock.mjs has 916 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts · ×1
  • code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts: 891 lines of code code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts:1 — code/lib/cli-storybook/src/automigrate/fixes/vitest-setup-file.ts has 891 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/types/modules/core-common.ts · ×1
  • code/core/src/types/modules/core-common.ts: 873 lines of code code/core/src/types/modules/core-common.ts:1 — code/core/src/types/modules/core-common.ts has 873 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/common/js-package-manager/JsPackageManager.ts · ×1
  • code/core/src/common/js-package-manager/JsPackageManager.ts: 846 lines of code code/core/src/common/js-package-manager/JsPackageManager.ts:1 — code/core/src/common/js-package-manager/JsPackageManager.ts has 846 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/csf-tools/estree/scope.ts · ×1
  • code/core/src/csf-tools/estree/scope.ts: 841 lines of code code/core/src/csf-tools/estree/scope.ts:1 — code/core/src/csf-tools/estree/scope.ts has 841 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/core-server/utils/StoryIndexGenerator.ts · ×1
  • code/core/src/core-server/utils/StoryIndexGenerator.ts: 811 lines of code code/core/src/core-server/utils/StoryIndexGenerator.ts:1 — code/core/src/core-server/utils/StoryIndexGenerator.ts has 811 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/manager/components/sidebar/Tree.tsx · ×1
  • code/core/src/manager/components/sidebar/Tree.tsx: 802 lines of code code/core/src/manager/components/sidebar/Tree.tsx:1 — code/core/src/manager/components/sidebar/Tree.tsx has 802 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · agent-eval/lib/agentic-reference/post-analysis.ts · ×1
  • agent-eval/lib/agentic-reference/post-analysis.ts: 768 lines of code agent-eval/lib/agentic-reference/post-analysis.ts:1 — agent-eval/lib/agentic-reference/post-analysis.ts has 768 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/csf-tools/story-shape/resolve-members.ts · ×1
  • code/core/src/csf-tools/story-shape/resolve-members.ts: 764 lines of code code/core/src/csf-tools/story-shape/resolve-members.ts:1 — code/core/src/csf-tools/story-shape/resolve-members.ts has 764 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · scripts/eval/run-batch.ts · ×1
  • scripts/eval/run-batch.ts: 755 lines of code scripts/eval/run-batch.ts:1 — scripts/eval/run-batch.ts has 755 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/instrumenter/instrumenter.ts · ×1
  • code/core/src/instrumenter/instrumenter.ts: 743 lines of code code/core/src/instrumenter/instrumenter.ts:1 — code/core/src/instrumenter/instrumenter.ts has 743 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/common/js-package-manager/PNPMProxy.ts · ×1
  • code/core/src/common/js-package-manager/PNPMProxy.ts: 736 lines of code code/core/src/common/js-package-manager/PNPMProxy.ts:1 — code/core/src/common/js-package-manager/PNPMProxy.ts has 736 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/manager/components/review/ReviewPage.stories.tsx · ×1
  • code/core/src/manager/components/review/ReviewPage.stories.tsx: 736 lines of code code/core/src/manager/components/review/ReviewPage.stories.tsx:1 — code/core/src/manager/components/review/ReviewPage.stories.tsx has 736 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/lib/cli-storybook/src/util.ts · ×1
  • code/lib/cli-storybook/src/util.ts: 736 lines of code code/lib/cli-storybook/src/util.ts:1 — code/lib/cli-storybook/src/util.ts has 736 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/csf-tools/CsfObjectDiscovery.ts · ×1
  • code/core/src/csf-tools/CsfObjectDiscovery.ts: 722 lines of code code/core/src/csf-tools/CsfObjectDiscovery.ts:1 — code/core/src/csf-tools/CsfObjectDiscovery.ts has 722 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/cli/skills/content/setup-prompts/pattern-copy-play.ts · ×1
  • code/core/src/cli/skills/content/setup-prompts/pattern-copy-play.ts: 679 lines of code code/core/src/cli/skills/content/setup-prompts/pattern-copy-play.ts:1 — code/core/src/cli/skills/content/setup-prompts/pattern-copy-play.ts has 679 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · scripts/ci/common-jobs.ts · ×1
  • scripts/ci/common-jobs.ts: 658 lines of code scripts/ci/common-jobs.ts:1 — scripts/ci/common-jobs.ts has 658 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files · code/core/src/shared/open-service/service-transport.ts · ×1
  • code/core/src/shared/open-service/service-transport.ts: 651 lines of code code/core/src/shared/open-service/service-transport.ts:1 — code/core/src/shared/open-service/service-transport.ts has 651 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R6 · Tooling · The declared test suite includes a file that cannot be loaded · ×1
  • The declared test suite includes a file that cannot be loaded agent-eval/evals/821-upgrade-from-sb9/stories/Button.stories.tsx:2 — This repository declares test tooling, and the ✓ above records that declaration — but agent-eval/evals/821-upgrade-from-sb9/stories/Button.stories.tsx and 13 other test file(s) in this workspace cannot be loaded at all: it imports a module that names no file in this repository, so the runner throws while collecting it and none of its cases execute. The wiring is present and the suite it points at does not run as written, which is why the tooling tick must not be read as a statement that the tests pass. Fix the unloadable file(s) — each one is reported with its failing import under Test Coverage — then the declared script exercises what it claims to.
R7 · Dead Code · Dead file (~953 LoC) · ×1
  • Dead file (~953 LoC) agent-eval/lib/mcp/codex-browser-client-mock.mjs — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~450 LoC) · ×1
  • Dead file (~450 LoC) code/renderers/react/template/stories/docgen-components/js-proptypes/input.jsx — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~329 LoC) · ×1
  • Dead file (~329 LoC) scripts/display-review.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~278 LoC) · ×1
  • Dead file (~278 LoC) code/lib/cli-storybook/src/sandbox.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~251 LoC) · ×1
  • Dead file (~251 LoC) code/renderers/react/template/stories/docgen-components/jsdoc/input.jsx — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~215 LoC) · ×1
  • Dead file (~215 LoC) agent-eval/lib/mcp/start-storybook-mcp.mjs — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~154 LoC) · ×1
  • Dead file (~154 LoC) scripts/event-log-checker.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~151 LoC) · ×1
  • Dead file (~151 LoC) scripts/ci/main.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~103 LoC) · ×1
  • Dead file (~103 LoC) code/lib/cli-storybook/src/link.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~101 LoC) · ×1
  • Dead file (~101 LoC) agent-eval/evals/808-shared-infra-fallback/EVAL.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~94 LoC) · ×1
  • Dead file (~94 LoC) scripts/combine-compodoc.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~89 LoC) · ×1
  • Dead file (~89 LoC) code/renderers/vue3/template/stories_vue3-vite-default-ts/component-meta/reference-type-props/my-props.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 2 in-repo import(s) from 2 other file(s) do name it (code/renderers/vue3/template/stories_vue3-vite-default-ts/component-meta/reference-type-props/component-js-setup.vue, code/renderers/vue3/template/stories_vue3-vite-default-ts/component-meta/reference-type-props/component-js.vue) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~88 LoC) · ×1
  • Dead file (~88 LoC) code/addons/mcp/src/utils/module-graph.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~87 LoC) · ×1
  • Dead file (~87 LoC) agent-eval/evals/815-write-stories-for-fetching-component-without-msw/EVAL.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~81 LoC) · ×1
  • Dead file (~81 LoC) code/renderers/web-components/template/components/Form.js — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/renderers/web-components/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~69 LoC) · ×1
  • Dead file (~69 LoC) code/renderers/web-components/template/components/Button.js — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/renderers/web-components/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~67 LoC) · ×1
  • Dead file (~67 LoC) scripts/utils/tools.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~65 LoC) · ×1
  • Dead file (~65 LoC) code/frameworks/angular/build-config.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~64 LoC) · ×1
  • Dead file (~64 LoC) code/frameworks/angular-vite/build-config.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~59 LoC) · ×1
  • Dead file (~59 LoC) agent-eval/evals/812-first-story-empty-project/EVAL.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~58 LoC) · ×1
  • Dead file (~58 LoC) code/frameworks/nextjs-vite/build-config.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~57 LoC) · ×1
  • Dead file (~57 LoC) code/renderers/vue3/template/stories_vue3-vite-default-ts/component-meta/reference-type-props/component-js-setup.vue — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~54 LoC) · ×1
  • Dead file (~54 LoC) code/renderers/react/template/stories/docgen-components/js-class-component/input.jsx — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R7 · Dead Code · Dead file (~52 LoC) · ×1
  • Dead file (~52 LoC) code/renderers/vue3/template/components/Button.vue — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (code/renderers/vue3/template/components/index.js) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
R7 · Dead Code · Dead file (~41 LoC) · ×1
  • Dead file (~41 LoC) code/frameworks/tanstack-react/build-config.ts — no import path from any entry point (901 application, 230 tooling, 2121 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make
R8 · Dependency Hygiene · Unlisted import '@standard-schema/spec' · ×1
  • Unlisted import '@standard-schema/spec' code/addons/mcp/src/tools/toolset-tools.ts:9 — Imported only as a TYPE and declared in no reachable REDACTED. The import is erased at compile time, so nothing is installed and no runtime resolution depends on it — but type-checking a clean clone will fail. Declare the typings it resolves through (or the package itself) in the owning REDACTED.
R8 · Dependency Hygiene · Unused dependency 'mock-require' · ×1
  • Unused dependency 'mock-require' — Declared in code/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
R8 · Dependency Hygiene · Unused dependency 'react-resize-detector' · ×1
  • Unused dependency 'react-resize-detector' — Declared in code/addons/a11y/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
R8 · Dependency Hygiene · Unused dependency 'istanbul-reports' · ×1
  • Unused dependency 'istanbul-reports' — Declared in code/addons/vitest/package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
S1 · Web-Security Posture · Weak hash algorithm · ×1
  • Weak hash algorithm agent-eval/lib/checkout-registry-server.mjs:34 — MD5/SHA1 is computed here, and both are collision-broken. If this digest protects anything — a signature, an integrity or tamper check, a credential, or any value an attacker can influence — that is a real weakness: use SHA-256+ (`createHash("sha256")`) for content integrity, or a KDF (bcrypt/Argon2/scrypt) for password storage. If it only derives a non-security identifier (a cache key, an avatar URL, an ETag), collision resistance carries no security consequence here; make that intent explicit instead — a non-cryptographic hash such as xxhash or murmurhash says it in code — since the algorithm alone cannot distinguish the two uses. Where a protocol this code does not own fixes the digest (a k-anonymity range query, a legacy signature format), the protocol decides; say so beside the call.
X13 · Undrained process stream · Redirected process stream is never drained (deadlock) · ×1
  • Redirected process stream is never drained (deadlock) scripts/reset.js:12 — `spawn` pipes `stderr` here — it is given no `stdio` option, or `'pipe'` — but nothing in this scope ever reads `cleaningProcess.stderr`, while `cleaningProcess.stdout` is read and the child's end is awaited. Node holds an unread pipe's output only up to its buffer: once the child writes more than that to stderr (measured on Linux: about 128 KB — the 64 KB pipe plus Node's 64 KB read-ahead — and less elsewhere), the child blocks on the write, never exits, and the `close`/`exit` this code waits for never fires. Nothing fails loudly: the promise never settles, the request never returns, and the stuck child holds its resources until something kills it. Consume both streams (`cleaningProcess.stderr.on('data', …)`, or `cleaningProcess.stderr.resume()` to discard it), or stop piping the one you do not want — `stdio: ['pipe', 'pipe', 'inherit']` or `'ignore'` in that slot.
Minor — 362 finding(s)
D10 · Test Quality · Mock-dominated test · ×121
  • Mock-dominated test: should handle DocumentFragment stories code/renderers/web-components/src/docs/sourceDecorator.test.ts:85 — This test sets up 3 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should track prompt cancellation for builder selection and exit cleanly code/lib/create-storybook/src/services/FrameworkDetectionService.test.ts:268 — This test sets up 5 test doubles (for example `vi.spyOn`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should not install Playwright when vitest addon is not configured code/lib/create-storybook/src/commands/AddonConfigurationCommand.test.ts:185 — This test sets up 4 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should track skipped Playwright installation code/lib/create-storybook/src/commands/AddonConfigurationCommand.test.ts:197 — This test sets up 4 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 1 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should track aborted Playwright installation code/lib/create-storybook/src/commands/AddonConfigurationCommand.test.ts:212 — This test sets up 4 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 1 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should track failed Playwright installation code/lib/create-storybook/src/commands/AddonConfigurationCommand.test.ts:227 — This test sets up 4 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 1 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should pass yes option to addon postinstall functions code/lib/create-storybook/src/commands/AddonConfigurationCommand.test.ts:242 — This test sets up 4 test doubles (for example `vi.mock/jest.mock of an imported module`) against 1 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should update gitignore and print success message code/lib/create-storybook/src/commands/FinalizationCommand.test.ts:37 — This test sets up 3 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 4 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should not update gitignore if file not found code/lib/create-storybook/src/commands/FinalizationCommand.test.ts:55 — This test sets up 3 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 3 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should not update gitignore if file is outside project root code/lib/create-storybook/src/commands/FinalizationCommand.test.ts:67 — This test sets up 3 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should pass correct options to generator code/lib/create-storybook/src/commands/GeneratorExecutionCommand.test.ts:131 — This test sets up 3 test doubles (for example `a double assigned in a shared setup`) against 1 real object(s) of its own, and its only verification is 3 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should log the detected package manager code/lib/create-storybook/src/commands/PreflightCheckCommand.test.ts:176 — This test sets up 3 test doubles (for example `vi.mock/jest.mock of an imported module`) against 0 real object(s) of its own, and its only verification is 1 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should track prompt cancellation for the React Native variant prompt and exit cleanly code/lib/create-storybook/src/commands/ProjectDetectionCommand.test.ts:146 — This test sets up 4 test doubles (for example `vi.spyOn`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should exit if user declines to force install code/lib/create-storybook/src/commands/ProjectDetectionCommand.test.ts:211 — This test sets up 3 test doubles (for example `vi.spyOn`) against 0 real object(s) of its own, and its only verification is 1 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: shows why it failed in the project task log code/lib/cli-storybook/src/automigrate/runner.test.ts:68 — This test sets up 4 test doubles (for example `vi.fn`) against 0 real object(s) of its own, and its only verification is 1 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: should call listeners when events are sent via the channel code/core/src/shared/universal-store/index.test.ts:1020 — This test sets up 3 test doubles (for example `vi.fn`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: imports with a new path for a story id if provided code/core/src/preview-api/modules/store/StoryStore.test.ts:283 — This test sets up 3 test doubles (for example `vi.fn`) against 1 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: cleans the hooks from the context code/core/src/preview-api/modules/store/StoryStore.test.ts:498 — This test sets up 3 test doubles (for example `vi.fn`) against 1 real object(s) of its own, and its only verification is 1 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: triggers only the last effect when updating state synchronously code/core/src/preview-api/modules/store/hooks.test.ts:430 — This test sets up 3 test doubles (for example `vi.fn`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: composes beforeAll hooks code/core/src/preview-api/modules/store/csf/composeConfigs.test.ts:320 — This test sets up 3 test doubles (for example `vi.fn`) against 0 real object(s) of its own, and its only verification is 3 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: produces a story with inherited decorators applied code/core/src/preview-api/modules/store/csf/prepareStory.test.ts:493 — This test sets up 6 test doubles (for example `vi.fn`) against 1 real object(s) of its own, and its only verification is 4 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: uses the attached CSF story docs parameters for attached MDX docs code/core/src/preview-api/modules/preview-web/render/MdxDocsRender.test.ts:133 — This test sets up 4 test doubles (for example `vi.fn`) against 2 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: leaves non-CSS Web Animations untouched code/core/src/preview-api/modules/preview-web/render/animation-utils.test.ts:134 — This test sets up 3 test doubles (for example `vi.fn`) against 0 real object(s) of its own, and its only verification is 3 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: %s aborts immediately when stdin has already ended before the prompt runs code/core/src/node-logger/prompts/prompt-provider-clack.test.ts:179 — This test sets up 3 test doubles (for example `vi.spyOn`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • Mock-dominated test: calls clear() on every test provider that has it code/core/src/manager-api/tests/addons.test.js:119 — This test sets up 3 test doubles (for example `vi.fn`) against 0 real object(s) of its own, and its only verification is 2 check(s) that the doubles were called. It pins how the code is wired, not what it does: it passes with a wrong result and fails when a call is harmlessly reordered or merged. Assert the outcome instead (the value returned, the state left behind), build collaborators and value objects for real or with a small hand-written fake, and keep doubles for the boundaries the test cannot own — the network, the clock, the file system.
  • + 96 more in this group — see findings.md.
D12 · Dependency Hygiene · Deprecated · ×40
  • Deprecated: @babel/plugin-proposal-class-properties REDACTED:1137 — @babel/plugin-proposal-class-properties 7.18.6 is resolved in REDACTED and is marked deprecated by its publisher: "This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-class-properties instead.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @babel/plugin-proposal-private-methods REDACTED:1162 — @babel/plugin-proposal-private-methods 7.18.6 is resolved in REDACTED and is marked deprecated by its publisher: "This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-private-methods instead.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @babel/plugin-proposal-private-property-in-object REDACTED:1183 — @babel/plugin-proposal-private-property-in-object 7.21.11 is resolved in REDACTED and is marked deprecated by its publisher: "This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-private-property-in-object instead.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @babel/polyfill REDACTED:2060 — @babel/polyfill 7.12.1 is resolved in REDACTED and is marked deprecated by its publisher: "🚨 This package has been deprecated in favor of separate inclusion of a polyfill and regenerator-runtime (when needed). See the @babel/polyfill docs (https://babeljs.io/docs/en/babel-polyfill) for more information.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @humanwhocodes/config-array REDACTED:3402 — @humanwhocodes/config-array 0.13.0 is resolved in REDACTED and is marked deprecated by its publisher: "Use @eslint/config-array instead". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @humanwhocodes/config-array REDACTED:3413 — @humanwhocodes/config-array 0.9.5 is resolved in REDACTED and is marked deprecated by its publisher: "Use @eslint/config-array instead". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @humanwhocodes/object-schema REDACTED:3431 — @humanwhocodes/object-schema 1.2.1 is resolved in REDACTED and is marked deprecated by its publisher: "Use @eslint/object-schema instead". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @humanwhocodes/object-schema REDACTED:3438 — @humanwhocodes/object-schema 2.0.3 is resolved in REDACTED and is marked deprecated by its publisher: "Use @eslint/object-schema instead". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @verdaccio/commons-api REDACTED:13957 — @verdaccio/commons-api 10.2.0 is resolved in REDACTED and is marked deprecated by its publisher: "Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: @verdaccio/logger-7 REDACTED:14054 — @verdaccio/logger-7 8.0.0-next-8.1 is resolved in REDACTED and is marked deprecated by its publisher: "Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: are-we-there-yet REDACTED:15453 — are-we-there-yet 4.0.2 is resolved in REDACTED and is marked deprecated by its publisher: "This package is no longer supported.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: are-we-there-yet REDACTED:15460 — are-we-there-yet 1.1.7 is resolved in REDACTED and is marked deprecated by its publisher: "This package is no longer supported.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: argv REDACTED:15493 — argv 0.0.2 is resolved in REDACTED and is marked deprecated by its publisher: "Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: core-js REDACTED:17988 — core-js 2.6.12 is resolved in REDACTED and is marked deprecated by its publisher: "core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: deep-diff REDACTED:18523 — deep-diff 1.0.2 is resolved in REDACTED and is marked deprecated by its publisher: "Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: eslint REDACTED:20292 — eslint 8.4.1 is resolved in REDACTED and is marked deprecated by its publisher: "This version is no longer supported. Please see https://eslint.org/version-support for other options.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: gauge REDACTED:21900 — gauge 5.0.2 is resolved in REDACTED and is marked deprecated by its publisher: "This package is no longer supported.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: gauge REDACTED:21916 — gauge 2.7.4 is resolved in REDACTED and is marked deprecated by its publisher: "This package is no longer supported.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: glob REDACTED:22225 — glob 11.1.0 is resolved in REDACTED and is marked deprecated by its publisher: "Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: glob REDACTED:22252 — glob 5.0.15 is resolved in REDACTED and is marked deprecated by its publisher: "Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: glob REDACTED:22265 — glob 6.0.4 is resolved in REDACTED and is marked deprecated by its publisher: "Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: google-p12-pem REDACTED:22383 — google-p12-pem 4.0.1 is resolved in REDACTED and is marked deprecated by its publisher: "Package is no longer maintained". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: har-validator REDACTED:22546 — har-validator 5.1.5 is resolved in REDACTED and is marked deprecated by its publisher: "this library is no longer supported". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: inflight REDACTED:23378 — inflight 1.0.6 is resolved in REDACTED and is marked deprecated by its publisher: "This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • Deprecated: lodash.omit REDACTED:25520 — lodash.omit 4.5.0 is resolved in REDACTED and is marked deprecated by its publisher: "This package is deprecated. Use destructuring assignment syntax instead.". This repository does not declare it — a direct dependency pulls it in, so the move is to upgrade or replace that dependency.
  • + 15 more in this group — see findings.md.
P2 · Observability · Console output used as the logging channel · ×39
  • Console output used as the logging channel code/core/src/toolbar/components/ToolbarMenuSelect.tsx:58 — `code/core/src/toolbar/components/ToolbarMenuSelect.tsx` reports through `console.*` at line 58 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/shared/utils/module.ts:22 — `code/core/src/shared/utils/module.ts` reports through `console.*` at line 22 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/shared/open-service/sync-test/remote-command/server.ts:22 — `code/core/src/shared/open-service/sync-test/remote-command/server.ts` reports through `console.*` at line 22 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/shared/open-service/sync-test/remote-command/server.ts:26 — `code/core/src/shared/open-service/sync-test/remote-command/server.ts` reports through `console.*` at line 26 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/shared/open-service/sync-test/local-command/server.ts:12 — `code/core/src/shared/open-service/sync-test/local-command/server.ts` reports through `console.*` at line 12 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/shared/open-service/sync-test/local-command/server.ts:14 — `code/core/src/shared/open-service/sync-test/local-command/server.ts` reports through `console.*` at line 14 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/shared/open-service/sync-test/concurrent-writes/server.ts:12 — `code/core/src/shared/open-service/sync-test/concurrent-writes/server.ts` reports through `console.*` at line 12 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/shared/open-service/sync-test/concurrent-writes/server.ts:14 — `code/core/src/shared/open-service/sync-test/concurrent-writes/server.ts` reports through `console.*` at line 14 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/store/StoryStore.ts:312 — `code/core/src/preview-api/modules/store/StoryStore.ts` reports through `console.*` at line 312 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/store/StoryStore.ts:361 — `code/core/src/preview-api/modules/store/StoryStore.ts` reports through `console.*` at line 361 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/preview-web/render/StoryRender.ts:369 — `code/core/src/preview-api/modules/preview-web/render/StoryRender.ts` reports through `console.*` at line 369 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/addons/hooks.ts:521 — `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 521 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/addons/hooks.ts:552 — `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 552 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/addons/hooks.ts:553 — `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 553 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/addons/hooks.ts:581 — `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 581 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/addons/hooks.ts:605 — `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 605 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/preview-api/modules/addons/hooks.ts:642 — `code/core/src/preview-api/modules/addons/hooks.ts` reports through `console.*` at line 642 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/node-logger/logger/console.ts:126 — `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 126 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/node-logger/logger/console.ts:159 — `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 159 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/node-logger/logger/console.ts:202 — `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 202 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/node-logger/logger/console.ts:214 — `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 214 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/node-logger/logger/console.ts:296 — `code/core/src/node-logger/logger/console.ts` reports through `console.*` at line 296 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/node-logger/logger/logger.ts:178 — `code/core/src/node-logger/logger/logger.ts` reports through `console.*` at line 178 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/node-logger/logger/logger.ts:195 — `code/core/src/node-logger/logger/logger.ts` reports through `console.*` at line 195 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • Console output used as the logging channel code/core/src/manager/provider.ts:13 — `code/core/src/manager/provider.ts` reports through `console.*` at line 13 although other files in its module log through a logger. Console lines carry no level, fields or correlation and never reach the log pipeline.
  • + 14 more in this group — see findings.md.
X10 · Duplicated predicate · Duplicated predicate · ×25
  • Duplicated predicate code/renderers/web-components/src/docgen/story-docs/template-holes.ts:322 — `!!binding && sources.includes(binding.importId) && binding.importName === importName` appears character-identically in 2 files — code/renderers/web-components/src/docgen/story-docs/template-holes.ts, code/renderers/web-components/src/docgen/story-docs/template-scope.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/lib/cli-storybook/src/upgrade.ts:430 — `!!options.yes || !process.stdout.isTTY || !!isCI()` appears character-identically in 2 files — code/lib/cli-storybook/src/upgrade.ts, code/lib/create-storybook/src/commands/PreflightCheckCommand.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts:243 — `!!storyFnAngular?.template && previousStoryRenderInfo?.storyFnAngular?.template !== storyFnAngular.template` appears character-identically in 2 files — code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts, code/frameworks/angular/src/client/angular-beta/AbstractRenderer.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/core/src/manager-api/lib/addons.ts:73 — `!!this.channel || !!readInstalledChannel()` appears character-identically in 2 files — code/core/src/manager-api/lib/addons.ts, code/core/src/preview-api/modules/addons/main.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts:40 — `!appRef.destroyed && (!domNode || appDOMNode === domNode)` appears character-identically in 2 files — code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts, code/frameworks/angular/src/client/angular-beta/AbstractRenderer.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/angular-vite/src/docgen/story-docs-ng-modules.ts:34 — `!element || element.type === 'SpreadElement'` appears character-identically in 2 files — code/frameworks/angular-vite/src/docgen/story-docs-ng-modules.ts, code/renderers/vue3/src/docgen/story-docs/print-h/print-h.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/angular-vite/src/docgen/preset.ts:40 — `!features?.docgenServer || !features?.componentsManifest` appears character-identically in 2 files — code/frameworks/angular-vite/src/docgen/preset.ts, code/renderers/web-components/src/docgen/preset.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/renderers/html/src/docs/sourceDecorator.ts:20 — `!isArgsStory || sourceParams?.code || sourceParams?.type === SourceType.CODE` appears character-identically in 6 files — code/renderers/html/src/docs/sourceDecorator.ts, code/renderers/react/src/docs/jsxDecorator.tsx, code/renderers/svelte/src/docs/sourceDecorator.ts, code/renderers/svelte/src/svelte-csf/runtime/emit-code.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate agent-eval/lib/agentic-reference/metrics/churn.ts:178 — `!isRecord(event) || event.type !== 'tool_call' || !isRecord(event.tool)` appears character-identically in 2 files — agent-eval/lib/agentic-reference/metrics/churn.ts, agent-eval/lib/agentic-reference/metrics/tool-taxonomy.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/lib/eslint-plugin/src/rules/hierarchy-separator.ts:44 — `!isSpreadElement(prop) && 'name' in prop.key && prop.key?.name === 'title'` appears character-identically in 2 files — code/lib/eslint-plugin/src/rules/hierarchy-separator.ts, code/lib/eslint-plugin/src/rules/no-title-property-in-meta.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/lib/cli-storybook/src/automigrate/fixes/csf-next-mocked-args.ts:18 — `!requested && !(beforeVersion && crossesVersionBoundary(beforeVersion, storybookVersion, introducedIn))` appears character-identically in 3 files — code/lib/cli-storybook/src/automigrate/fixes/csf-next-mocked-args.ts, code/lib/cli-storybook/src/automigrate/fixes/experimental-features.ts, code/lib/cli-storybook/src/automigrate/fixes/skills.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/core/src/components/components/Tabs/StatelessTabList.tsx:133 — `!scrollContainer || !container || typeof window === 'undefined'` appears character-identically in 2 files — code/core/src/components/components/Tabs/StatelessTabList.tsx, code/core/src/components/components/Tabs/TabList.tsx. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/core/src/components/components/Tabs/StatelessTabList.tsx:104 — `!scrollContainer || typeof window === 'undefined'` appears character-identically in 2 files — code/core/src/components/components/Tabs/StatelessTabList.tsx, code/core/src/components/components/Tabs/TabList.tsx. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/nextjs-vite/src/routing/app-router-provider.tsx:43 — `!segmentValue || segmentValue.startsWith(PAGE_SEGMENT_KEY)` appears character-identically in 2 files — code/frameworks/nextjs-vite/src/routing/app-router-provider.tsx, code/frameworks/nextjs/src/routing/app-router-provider.tsx. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/nextjs/src/images/next-image-default-loader.tsx:34 — `!src.startsWith('http://') && !src.startsWith('https://')` appears character-identically in 2 files — code/frameworks/nextjs/src/images/next-image-default-loader.tsx, code/lib/vite-plugin-storybook-nextjs/src/plugins/next-image/alias/image-default-loader.tsx. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/angular-vite/src/docgen/docgen-worker.ts:43 — `!storyImportPath || !STORY_FILE_TEST_REGEXP.test(storyImportPath)` appears character-identically in 2 files — code/frameworks/angular-vite/src/docgen/docgen-worker.ts, code/renderers/react/src/docgen/story-docs-preset.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/core/src/common/utils/lazy-docgen-middleware.ts:40 — `!storyImportPath || !storyFileTest.test(storyImportPath)` appears character-identically in 2 files — code/core/src/common/utils/lazy-docgen-middleware.ts, code/core/src/shared/open-service/services/story-docs/provider.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate agent-eval/lib/shell-parse.ts:338 — `!token.startsWith('--') || token === '--'` appears character-identically in 2 files — agent-eval/lib/shell-parse.ts, code/core/src/cli/tools/tool-tokens.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/nextjs/src/images/next-image-default-loader.tsx:29 — `!url.searchParams.has('w') && !url.searchParams.has('q')` appears character-identically in 2 files — code/frameworks/nextjs/src/images/next-image-default-loader.tsx, code/lib/vite-plugin-storybook-nextjs/src/plugins/next-image/alias/image-default-loader.tsx. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/core/src/common/js-package-manager/util.ts:79 — `!value || typeof value !== 'object' || Array.isArray(value)` appears character-identically in 2 files — code/core/src/common/js-package-manager/util.ts, scripts/eval/collect-pr-data.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/core/src/shared/open-service/services/story-docs/preview.ts:12 — `'FEATURES' in globalThis && globalThis.FEATURES?.docgenServer` appears character-identically in 3 files — code/core/src/shared/open-service/services/story-docs/preview.ts, code/renderers/web-components/src/entry-preview-argtypes.ts, code/renderers/web-components/src/entry-preview-docs.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/lib/eslint-plugin/src/rules/default-exports.ts:70 — `'name' in node.imported && node.imported.name === 'storiesOf'` appears character-identically in 4 files — code/lib/eslint-plugin/src/rules/default-exports.ts, code/lib/eslint-plugin/src/rules/no-stories-of.ts, code/lib/eslint-plugin/src/rules/prefer-pascal-case.ts, code/lib/eslint-plugin/src/rules/story-exports.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/core/src/components/components/Select/Select.tsx:360 — `'type' in option && option.type === 'reset'` appears character-identically in 2 files — code/core/src/components/components/Select/Select.tsx, code/core/src/components/components/Select/helpers.tsx. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/react-vite/src/plugins/docgen-handlers/actualNameHandler.ts:21 — `(componentDefinition.isClassDeclaration() || componentDefinition.isFunctionDeclaration()) && componentDefinition.has('id')` appears character-identically in 4 files — code/frameworks/react-vite/src/plugins/docgen-handlers/actualNameHandler.ts, code/presets/react-webpack/src/loaders/react-docgen-loader.ts, code/renderers/react/src/componentManifest/reactDocgen/actualNameHandler.ts, code/renderers/react/src/componentManifest/reactDocgen/exportNameHandler.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts:178 — `(d instanceof Component || d instanceof Directive || d instanceof Pipe) && d.standalone` appears character-identically in 2 files — code/frameworks/angular-vite/src/client/renderer/utils/NgComponentAnalyzer.ts, code/frameworks/angular/src/client/angular-beta/utils/NgComponentAnalyzer.ts. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
X7 · Silent fallback defaults · Silent fallback default in catch · ×23
  • Silent fallback default in catch agent-eval/lib/usage.ts:60 — `parseJsonLines` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch agent-eval/lib/agentic-reference/metrics/complexity-cognitive.ts:118 — `cognitiveForSource` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch agent-eval/lib/agentic-reference/metrics/complexity-cyclomatic.ts:100 — `complexityForSource` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch agent-eval/lib/agentic-reference/tree/tree-diff.ts:67 — `readStripped` swallows every exception into `return ''` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch agent-eval/lib/agentic-reference/metrics/ds-misuse/ds-docs.ts:49 — `mdxUnder` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch agent-eval/lib/mcp/claude-browser-mock.mjs:491 — `hostnameOf` swallows every exception into `return ''` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/channels/postmessage/index.ts:217 — `getFrames` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/channels/postmessage/index.ts:65 — `getOriginValidator` swallows every exception into `return false` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/manager-api/modules/versions.ts:22 — `getVersionCheckData` swallows every exception into `return {}` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/common/js-package-manager/JsPackageManager.ts:277 — `#getIndent` swallows every exception into `return 2` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/common/js-package-manager/Yarn2Proxy.ts:542 — `getPreapprovedPackages` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch REDACTED:153 — `inheritedTags` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/telemetry/get-known-packages.ts:75 — `getSafeVersionSpecifier` swallows every exception into `return 'could-not-be-parsed-by-semver'` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/telemetry/storybook-metadata.ts:332 — `hashMainConfig` swallows every exception into `return 'unknown'` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/telemetry/telemetry.ts:45 — `getOperatingSystem` swallows every exception into `return 'Unknown'` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/cli/installSkills.ts:75 — `getStorybookSkillNames` swallows every exception into `return []` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/core/src/instrumenter/instrumenter.ts:60 — `construct` swallows every exception into `return {}` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/frameworks/nextjs/src/config/webpack.ts:14 — `tryResolve` swallows every exception into `return false` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/frameworks/tanstack-react/src/export-mocks/start.ts:504 — `unsealSession` swallows every exception into `return {}` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/lib/vite-plugin-storybook-nextjs/src/utils.ts:23 — `getNextjsMajorVersion` swallows every exception into `return 16` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/lib/vite-plugin-storybook-nextjs/src/utils.ts:32 — `getViteMajorVersion` swallows every exception into `return 7` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch code/renderers/react/src/componentManifest/reactDocgen/utils.ts:147 — `getTsConfig` swallows every exception into `return {}` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
  • Silent fallback default in catch scripts/eval/run-batch.ts:286 — `readFailureReason` swallows every exception into `return ''` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
D34 · Knowledge Freshness · Orphaned file · ×22
  • Orphaned file code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file REDACTED:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/core/src/common/utils/file-cache.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/core/src/viewport/defaults.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/nextjs-vite/src/export-mocks/router/index.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/nextjs/src/export-mocks/router/index.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/angular-vite/src/client/argsToTemplate.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/angular-vite/src/client/decorators.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/renderers/html/template/cli/ts/Page.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/angular-vite/template/cli/page.component.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/renderers/preact/src/public-types.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/angular/template/cli/page.component.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/presets/react-webpack/src/loaders/docgen-resolver.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/react-vite/src/plugins/docgen-resolver.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/angular-vite/template/stories/core/decorators/componentWrapperDecorator/decorators.stories.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/renderers/react/template/cli/ts/Page.tsx:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/react-vite/template/cli/ts/Page.tsx:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/nextjs-vite/template/cli/ts/Page.tsx:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/nextjs/template/cli/ts/Page.tsx:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/renderers/web-components/template/stories/demo-wc-card/DemoWcCard.js:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/renderers/web-components/template/cli/ts/Page.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file code/frameworks/web-components-vite/template/cli/ts/Page.ts:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
D10 · Test Quality · No direct assertions · ×15
  • No direct assertions: ✅ Meta<typeof Component> extracts component props code/renderers/preact/src/public-types.test.tsx:24 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: ✅ Meta<Props> still works when passing props directly code/renderers/preact/src/public-types.test.tsx:33 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: ✅ Meta can be used without generic code/renderers/preact/src/public-types.test.tsx:42 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: ✅ All required args may be provided in meta code/renderers/preact/src/public-types.test.tsx:48 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: ✅ Required args may be provided partial in meta and the story code/renderers/preact/src/public-types.test.tsx:62 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: ❌ The combined shape of meta args and story args must match the required args. code/renderers/preact/src/public-types.test.tsx:75 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: Component can be used as generic parameter for StoryObj code/renderers/preact/src/public-types.test.tsx:109 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: StoryObj<typeof meta> is allowed when meta is upcasted to Meta<Props> code/renderers/preact/src/public-types.test.tsx:115 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: StoryObj<typeof meta> is allowed when meta is upcasted to Meta<typeof Cmp> code/renderers/preact/src/public-types.test.tsx:121 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: StoryObj<typeof meta> is allowed when all arguments are optional code/renderers/preact/src/public-types.test.tsx:127 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: Props can be defined as interfaces, issue #21768 code/renderers/preact/src/public-types.test.tsx:133 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: Components without Props can be used, issue #21768 code/renderers/preact/src/public-types.test.tsx:156 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: Correct args are inferred when type is widened for render function code/renderers/preact/src/public-types.test.tsx:172 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: Correct args are inferred when type is widened for decorators code/renderers/preact/src/public-types.test.tsx:192 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
  • No direct assertions: Infer mock function given to args in meta. code/renderers/preact/src/public-types.test.tsx:208 — No conventional assertion call was detected, and 15 of 15 tests in `code/renderers/preact` read the same way — so this is treated as that project's convention rather than a broken test, and it does not drag the score. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a project of runnable samples compiled as tests, where a run that does not throw is the only check. If it is the latter, these methods genuinely verify nothing.
D12 · Dependency Hygiene · Outdated (npm) · ×11
  • Outdated (npm): @google-cloud/bigquery scripts/package.json:52 — @google-cloud/bigquery is pinned at 6.2.1; registry.npmjs.org publishes 9.5.0 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @octokit/graphql scripts/package.json:53 — @octokit/graphql is pinned at 5.0.6; registry.npmjs.org publishes 9.0.5 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @types/node REDACTED:42 — @types/node is pinned at 22.19.15; registry.npmjs.org publishes 26.6.5 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): ejs REDACTED:358 — ejs is pinned at 3.1.10; registry.npmjs.org publishes 7.0.2 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): entities code/lib/angular-compodoc/package.json:49 — entities is pinned at 4.5.0; registry.npmjs.org publishes 8.1.0 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): glob code/builders/builder-vite/package.json:56 — glob is pinned at 10.5.0; registry.npmjs.org publishes 13.0.6 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): happy-dom code/package.json:106 — happy-dom is pinned at 17.6.3; registry.npmjs.org publishes 21.0.4 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): ora scripts/package.json:116 — ora is pinned at 5.4.1; registry.npmjs.org publishes 9.4.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): trash scripts/package.json:147 — trash is pinned at 7.2.0; registry.npmjs.org publishes 10.1.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): uuid code/package.json:123 — uuid is pinned at 11.1.0; registry.npmjs.org publishes 14.0.3 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): vercel REDACTED:37 — vercel is pinned at 54.21.1; registry.npmjs.org publishes 65.2.0 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
D29 · Static Analysis (SAST) · REDACTED · ×11
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
D16 · Bus Factor · Off-boarding risk · ×9
  • Off-boarding risk: anonymized user #1 — If anonymized user #1 becomes unavailable, 60 significant file(s) lose their only recent owner: code/lib/angular-cm/src/extract-arg-types.ts, code/lib/angular-compodoc/src/extract-arg-types.ts, code/lib/angular-cm/src/analyzer/type-index.ts, code/frameworks/angular-vite/src/template-grammar.ts, code/frameworks/angular-vite/src/docgen/story-docs-template-analysis.ts, code/lib/docgen-harness/src/perf/docgen-perf/engines/compodoc.ts, code/frameworks/angular-vite/src/client/renderer/AbstractRenderer.ts, code/core/src/oxc-parser/parse.ts (+52 more). Pair on, review, or document these before any departure.
  • Off-boarding risk: anonymized user #2 — If anonymized user #2 becomes unavailable, 29 significant file(s) lose their only recent owner: scripts/eval/collect-pr-data.ts, agent-eval/lib/test-utils.ts, agent-eval/lib/templates.ts, agent-eval/lib/mcp/codex-browser-client-mock.mjs, scripts/eval/lib/result-docs.ts, agent-eval/lib/mcp/node-repl-mock.mjs, scripts/eval/eval.ts, code/core/src/shared/open-service/toolsets/review/definition.ts (+21 more). Pair on, review, or document these before any departure.
  • Off-boarding risk: anonymized user #3 — If anonymized user #3 becomes unavailable, 25 significant file(s) lose their only recent owner: code/renderers/svelte/src/svelte-csf/utils/error/parser/analyse/story.ts, code/core/src/shared/open-service/patch-recorder.ts, REDACTED, code/renderers/svelte/src/svelte-csf/indexer/parser.ts, code/core/src/shared/open-service/sync-simulation/replicas.ts, code/renderers/svelte/src/portable-stories.ts, code/core/src/shared/open-service/sync-test/addon/panels/OpenServiceDemoPanel.tsx, code/renderers/svelte/src/svelte-csf/utils/error.ts (+17 more). Pair on, review, or document these before any departure.
  • Off-boarding risk: anonymized user #4 — If anonymized user #4 becomes unavailable, 23 significant file(s) lose their only recent owner: REDACTED, code/core/src/manager/components/preview/Viewport.tsx, code/core/src/preview-api/modules/preview-web/setupStoryFreezer.ts, REDACTED, REDACTED, code/addons/a11y/src/components/Report/Details.tsx, code/core/src/manager/components/error-boundary/ManagerErrorBoundary.stories.tsx, code/core/src/manager-api/modules/versions.ts (+15 more). Pair on, review, or document these before any departure.
  • Off-boarding risk: anonymized user #5 — If anonymized user #5 becomes unavailable, 15 significant file(s) lose their only recent owner: code/core/src/manager/components/layout/Drag.stories.tsx, code/addons/vitest/src/components/GlobalErrorModal.tsx, code/addons/vitest/src/components/GlobalErrorModal.stories.tsx, code/core/src/components/components/Bar/Bar.tsx, code/core/src/manager/components/sidebar/SearchResults.stories.tsx, scripts/utils/package-json.ts, code/core/src/manager/settings/Checklist/AiSetupBlock.tsx, code/core/src/components/components/tooltip/WithTooltip.stories.tsx (+7 more). Pair on, review, or document these before any departure.
  • Off-boarding risk: anonymized user #6 — If anonymized user #6 becomes unavailable, 11 significant file(s) lose their only recent owner: code/renderers/vue3/src/docgen/story-docs/source-decorator/sourceDecorator.ts, code/renderers/vue3/src/docgen/component-docgen/component-meta/vue-project-manager.ts, code/frameworks/sveltekit/static/app-state-mock.svelte.js, code/renderers/vue3/src/docgen/component-docgen/api-description/api-description.ts, code/renderers/web-components/src/docgen/component-docgen/build-docgen.ts, code/core/src/shared/open-service/services/docgen/worker/docgen-worker.ts, code/core/src/csf-tools/jsdoc.ts, code/core/src/component-meta/jsdoc-info.ts (+3 more). Pair on, review, or document these before any departure.
  • Off-boarding risk: anonymized user #7 — If anonymized user #7 becomes unavailable, 6 significant file(s) lose their only recent owner: code/core/src/component-testing/components/MethodCall.tsx, code/core/src/telemetry/get-known-packages.ts, code/addons/vitest/template/stories/basics.stories.ts, code/core/src/core-server/utils/ghost-stories/run-story-tests.ts, code/core/src/shared/utils/to-story-test-result.ts, code/core/src/manager/components/review/components/Markdown.tsx. Pair on, review, or document these before any departure.
  • Off-boarding risk: anonymized user #8 — If anonymized user #8 becomes unavailable, 4 significant file(s) lose their only recent owner: code/renderers/vue3/src/docgen/component-docgen/arg-types/named-type-detail.ts, code/frameworks/nextjs/src/babel/plugins/react-loadable-plugin.ts, code/lib/angular-cm/src/type-detail.ts, code/frameworks/nextjs/src/babel/plugins/optimize-hook-destructuring.ts. Pair on, review, or document these before any departure.
  • Off-boarding risk: anonymized user #9 — If anonymized user #9 becomes unavailable, 3 significant file(s) lose their only recent owner: code/frameworks/nextjs-vite/src/find-postcss-config.ts, code/core/src/components/components/Popover/Popover.stories.tsx, code/core/src/channels/channel-slot.ts. Pair on, review, or document these before any departure.
X23 · Unguarded diagnostic materialisation · Diagnostic log message is built whether or not it is wanted · ×9
  • Diagnostic log message is built whether or not it is wanted code/core/src/shared/open-service/services/module-graph/engine/dependency-graph/resolver-factory.ts:62 — `debug` at line 62 is called with an argument built by `skippedRegex.join(', ')` (line 63), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
  • Diagnostic log message is built whether or not it is wanted code/core/src/core-server/presets/common-preset.ts:130 — `debug` at line 130 is called with an argument built by `faviconPaths.join(', ')` (line 133), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
  • Diagnostic log message is built whether or not it is wanted code/core/src/common/utils/command.ts:79 — `debug` at line 79 is called with an argument built by `args.join(' ')` (line 79), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
  • Diagnostic log message is built whether or not it is wanted code/core/src/common/js-package-manager/NPMProxy.ts:193 — `debug` at line 193 is called with an argument built by `pattern.join(', ')` (line 193), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
  • Diagnostic log message is built whether or not it is wanted code/core/src/common/js-package-manager/PNPMProxy.ts:211 — `debug` at line 211 is called with an argument built by `pattern.join(', ')` (line 211), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
  • Diagnostic log message is built whether or not it is wanted code/core/src/common/js-package-manager/Yarn1Proxy.ts:147 — `debug` at line 147 is called with an argument built by `pattern.join(', ')` (line 147), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
  • Diagnostic log message is built whether or not it is wanted code/core/src/common/js-package-manager/Yarn2Proxy.ts:173 — `debug` at line 173 is called with an argument built by `pattern.join(', ')` (line 173), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
  • Diagnostic log message is built whether or not it is wanted code/core/src/common/js-package-manager/Yarn2Proxy.ts:177 — `debug` at line 177 is called with an argument built by `pattern.join(', ')` (line 177), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
  • Diagnostic log message is built whether or not it is wanted code/addons/mcp/src/utils/get-story-index.ts:31 — `debug` at line 31 is called with an argument built by `Object.keys(index.entries)` (line 31), whose cost grows with the collection it walks. JavaScript evaluates a call's arguments BEFORE entering the method, so that join/projection runs in full every time this line is reached — and then the level check inside the logger discards the string it produced, because debug is a level a shipped configuration normally leaves off. Nothing here decides beforehand whether the message is wanted: no `isLevelEnabled`/`isDebugEnabled` test, no debug flag, no `NODE_ENV` build switch.
IC1 · Incompleteness & stubs · Disabled test · ×8
  • Disabled test code/core/src/common/presets.test.ts:610 — A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something.
  • Disabled test code/core/src/core-server/build-index.test.ts:6 — A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something.
  • Disabled test code/core/src/csf-tools/CsfFile.test.ts:1681 — A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something.
  • Disabled test code/core/src/csf-tools/CsfFile.test.ts:1689 — A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something.
  • Disabled test code/core/src/csf-tools/vitest-plugin/transformer.test.ts:1111 — A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something.
  • Disabled test code/core/src/instrumenter/instrumenter.test.ts:738 — A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something.
  • Disabled test code/core/src/manager/components/sidebar/__tests__/Sidebar.test.tsx:84 — A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something.
  • Disabled test code/e2e-internal/docgen-hot-update.spec.ts:50 — A test is skipped/ignored — coverage that looks present but never runs. Re-enable it or delete it so the green run means something.
D30 · Dependency Vulnerabilities · Low CVE · ×6
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
  • REDACTED
AX6 · Interface segregation · Fat interface · ×3
  • Fat interface: SubAPI (16 required operations) code/core/src/manager-api/modules/layout.ts:50 — `SubAPI` declares 16 required operations: `toggleFullscreen`, `togglePanel`, `togglePanelPosition`, `toggleNav`, `setMobileNavigation`, `toggleToolbar`, `setOptions`, `setSizes`, `getIsFullscreen`, `getIsPanelShown`, `getIsNavShown`, `getNavAvailability`, `getShowToolbarWithCustomisations`, `getShowPanelWithCustomisations`, `getNavSizeWithCustomisations`, `focusOnUIElement`. Counted over its REQUIRED operations — a method signature or a function-typed property with no `?`, once per signature; optional members and data properties are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
  • Fat interface: SubAPI (32 required operations) code/core/src/manager-api/modules/stories.ts:137 — `SubAPI` declares 32 required operations: `resolveStory`, `selectFirstStory`, `selectStory`, `getCurrentStoryData`, `getIndex`, `setIndex`, `jumpToSubtree`, `jumpToStory`, `getData`, `isPrepared`, `getParameters`, `getCurrentParameter`, `updateStoryArgs`, `resetStoryArgs`, `findLeafEntry`, `findLeafStoryId`, `findAllLeafStoryIds`, `findSiblingStoryId`, `fetchIndex`, `updateStory`, `updateDocs`, `setPreviewInitialized`, `setFilter`, `setFilters`, `resetTagFilters`, `setAllTagFilters`, `addTagFilters`, `removeTagFilters`, `resetStatusFilters`, `setAllStatusFilters`, `addStatusFilters`, `removeStatusFilters`. Counted over its REQUIRED operations — a method signature or a function-typed property with no `?`, once per signature; optional members and data properties are not counted, because no implementer is forced to write them. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
  • Fat interface: Presets (20 required operations) code/core/src/types/modules/core-common.ts:98 — `Presets` declares 20 required operations under just 1 distinct name(s): `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`, `apply`. Counted over its REQUIRED operations — a method signature or a function-typed property with no `?`, once per signature; optional members and data properties are not counted, because no implementer is forced to write them. That is an OVERLOAD SET, not 20 separate responsibilities: a caller binds to 1 operation(s) and uses the overload it selected, so the Interface-Segregation harm does NOT apply on the caller's side and splitting this into role-interfaces would scatter one operation without relieving anything. The burden that does remain is the IMPLEMENTER's — all 20 signatures must be written and kept in step. Reduce it by collapsing overloads (optional or default parameters, or an options object) rather than by segregating the interface.
S1 · Web-Security Posture · No app-layer HTTPS enforcement detected · ×3
  • No app-layer HTTPS enforcement detected scripts/event-log-collector.ts:118 — `server.listen(…)` serves plain HTTP on a network address, and nothing in its package enforces HTTPS: no TLS served (`https.createServer`, Fastify `https`, Nest `httpsOptions`), no redirect of plain requests to `https://`, no `Strict-Transport-Security` (helmet sends it by default), and no TLS-terminating proxy configuration committed beside it — so a browser may talk to it in clear text. (−2.0 on this card.)
  • No app-layer HTTPS enforcement detected scripts/run-registry.ts:93 — `proxy.listen(…)` serves plain HTTP on a network address, and nothing in its package enforces HTTPS: no TLS served (`https.createServer`, Fastify `https`, Nest `httpsOptions`), no redirect of plain requests to `https://`, no `Strict-Transport-Security` (helmet sends it by default), and no TLS-terminating proxy configuration committed beside it — so a browser may talk to it in clear text. (−2.0 on this card.)
  • No app-layer HTTPS enforcement detected scripts/run-registry.ts:109 — `app.listen(…)` serves plain HTTP on a network address, and nothing in its package enforces HTTPS: no TLS served (`https.createServer`, Fastify `https`, Nest `httpsOptions`), no redirect of plain requests to `https://`, no `Strict-Transport-Security` (helmet sends it by default), and no TLS-terminating proxy configuration committed beside it — so a browser may talk to it in clear text. (−2.0 on this card.)
AC7 · A11y enforcement · Accessibility enforcement below the top rung · ×1
  • Accessibility enforcement below the top rung — Accessibility checks run in tests (Verified) but aren't gated in CI — run the suite that holds those checks in your pipeline so an accessibility regression blocks the merge (Prevented). What was searched, so you can tell an absence from a miss: the 697 markup file(s) this pass actually assessed, the linter configuration checked in beside them, and this repository's test and CI files — matched by name against the accessibility checkers this dimension carries. An audit run outside the repository, a hosted scanner, or a check whose name is not one of those, is not seen here.
C2 · Access Controls · No named authorization policies · ×1
  • No named authorization policies — Authorization IS enforced here (by route guards, auth middleware or checks that refuse a caller) — this is NOT a claim that endpoints are unprotected. What's missing is a NAMED rule set: who may do what is encoded inline where it is checked, so the rules can't be listed, reviewed or tested apart from the code that applies them. Recommendation, not a defect.
D10 · Test Quality · Test project verifies nothing · ×1
  • Test project verifies nothing: code/renderers/preact code/renderers/preact/src/public-types.test.tsx:24 — No conventional assertion call was detected in 15 of 15 tests in `code/renderers/preact` — the project as a whole, not one method. Two things look like this: verification that happens indirectly (an approval/verifier harness or BDD step methods), or a suite that genuinely checks nothing. If it is the latter, this project passes unconditionally and cannot fail.
D16 · Bus Factor · Further sole-owners (lower concentration) · ×1
  • Further sole-owners (lower concentration) — 5 other contributor(s) are each the sole owner of a small amount of code below the off-boarding threshold — folded into the bus-factor score and metrics (199 single-owned of 1237 analysed files in total, counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated, example/demo and scaffolding-template trees and test files identified by path convention, largest first; 1237 of the 4164 production source files in this repository met that bar). They are anonymized user #10 (2 file(s)), anonymized user #11 (1 file(s)), anonymized user #12 (1 file(s)), anonymized user #13 (1 file(s)), anonymized user #14 (1 file(s)) — spread or document their files in the same way, at lower priority than the named off-boarding risks above. The files folded here: code/presets/react-webpack/src/loaders/docgen-resolver.ts, code/frameworks/react-vite/src/plugins/docgen-resolver.ts, code/frameworks/tanstack-react/template/stories/PathlessLayout.stories.tsx, code/core/src/cli/tools/sdk/node-channel.ts, code/renderers/preact/src/public-types.ts, code/core/src/components/components/Badge/Badge.tsx.
D20 · ADR Quality · No ADRs found · ×1
  • No ADRs found — No ADRs found. No recognised ADR directory (`docs/adr/`, `docs/decisions/`, `adr/`, `docs/rfcs/`, an `ADR0001/` folder, or their siblings) exists anywhere in this tree. What was searched, so you can tell an empty log from a search that missed one: every directory under the tree (build output, dependencies and VCS metadata excepted), for a document that is either any non-index page inside a recognised ADR directory, whatever its name and however deeply nested (`docs/adr/use-postgres.md`, `docs/adr/2024/0001-x.md`); or a file anywhere whose name is ADR-shaped (`0001-use-postgres.md`, `adr-012-caching.md`); or, when neither turned anything up, a document carrying the decision-record signature (an "Architecture Decision Record" heading, or Status / Context / Decision / Consequences as section headings). A decision log that clears none of these — unnumbered files outside any recognised directory, without those headings — is not seen by this check and this row is then wrong. If that is your case, say so rather than renaming anything; otherwise, consider recording architectural decisions in `docs/adr/`.
D26 · Project Cohesion · Projects may be oversized for their cohesion · ×1
  • Projects may be oversized for their cohesion — 10 of 86 project(s) overshoot their size bounds, lowering Project Cohesion to 7.8/10. The most over is `code/core` (151388 LoC, 1797 module-visible types across 197 directories). Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
D28 · Secrets (history) · Rotate the exposed credentials · ×1
  • REDACTED
D34 · Knowledge Freshness · Orphaned files with no living knowledge · ×1
  • Orphaned files with no living knowledge — 22 of 1247 analysed file(s) have no living knowledge left — their last meaningful change has decayed away, so if one breaks, no one currently understands it (counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated, example/demo and scaffolding-template trees and test files identified by path convention, largest first; 1247 of the 4164 production source files in this repository met that bar). None is large enough to earn a read-through of its own, so this row stands in for the per-file rows rather than raising one each — most significant first: code/frameworks/angular-vite/src/client/renderer/StorybookWrapperComponent.ts, REDACTED, code/core/src/common/utils/file-cache.ts, code/core/src/viewport/defaults.ts, code/frameworks/nextjs-vite/src/export-mocks/router/index.ts, code/frameworks/nextjs/src/export-mocks/router/index.ts, code/frameworks/angular-vite/src/client/argsToTemplate.ts, code/frameworks/angular-vite/src/client/decorators.ts (and 14 more). Attach the read to the next change that touches one of them: have a second person review that change, and leave behind a short comment or test recording what the file is for, so the knowledge comes back at the cost of a change you were making anyway.
D36 · Supply-chain Provenance & Signing · REDACTED · ×1
  • REDACTED
IC1 · Incompleteness & stubs · Empty method body · ×1
  • Empty method body code/core/src/core-server/change-detection/GitDiffProvider.ts:34 — `gitStateCallback` has an empty body — confirm it's an intentional no-op and not an unfinished method.
M2 · Architecture documentation · No ADRs · ×1
  • No ADRs — No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
M4 · Documentation accuracy · README/code drift · ×1
  • README/code drift CONTRIBUTING.md:63 — CONTRIBUTING.md names TypeScript 7, but the manifest declares `typescript` ^6.0.3. Checked without a model against the repository: its files and folders, the scripts and dependencies of every REDACTED, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong.
P2 · Observability · Logging is not universal · ×1
  • Logging is not universal — Only 23/28 runnable modules use logging (modules with no entry point or server are excluded — they are libraries a runnable module hosts). Silent: `agent-eval`, `code/frameworks/nextjs-vite`, `code/frameworks/sveltekit`, `code/lib/cli-sb`, `code/lib/vite-plugin-storybook-nextjs`.
R8 · Dependency Hygiene · Type-only dependency 'type-fest' in production deps · ×1
  • Type-only dependency 'type-fest' in production deps code/renderers/svelte/src/preview.ts:26 — Every import is type-only — move it to devDependencies.
X2 · Cancellation propagation · Not all async functions that make a request accept an AbortSignal · ×1
  • Not all async functions that make a request accept an AbortSignal — Only 12/30 async functions that make a cancellable request (fetch, axios, ky, ofetch) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, an unmounted component, a timed-out job. Take a `signal` (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
X5 · Nullable reference types · Strict null checking is not enabled everywhere the repository type-checks · ×1
  • Strict null checking is not enabled everywhere the repository type-checks — 84/127 of this repository's type-checking configuration(s) turn on strict null checking (`"strict": true`, or `"strictNullChecks": true`). A configuration that states neither is counted as OFF, because off is tsc's own default; a solution-style one whose `"files"` is empty and whose `"references"` point at other projects is in neither number, because it checks no source itself. Where it is off, `string` admits `null` and `undefined`: passing a value that is null compiles silently and throws on the first property access.
X5 · Nullable reference types · Null assertions (`!`) reduce the strict null checking score · ×1
  • Null assertions (`!`) reduce the strict null checking score — ~1.2 `!` null assertions per 1k TypeScript source lines — 413 assertion(s) across the 335151 source line(s) of the 2829 TypeScript file(s) read, which is the only code the operator asserts anything in (a `!` in a `.js` file is not this operator and was not counted, and one in a file whose null checking is off silences nothing). Densest: code/core/src/csf-tools/estree/editor.ts (23), agent-eval/lib/agentic-reference/comparison/html-report.ts (16), code/addons/vitest/src/node/vitest-manager.ts (13). Each one tells the compiler to trust the author about null, suppressing the very diagnostic `strictNullChecks` exists to produce.
Minor — 159 finding(s)
D12 · Dependency Hygiene · Outdated (npm) · ×125
  • Outdated (npm): @actions/core — @actions/core is pinned at 1.11.1; registry.npmjs.org publishes 3.0.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @anthropic-ai/claude-agent-sdk — @anthropic-ai/claude-agent-sdk is pinned at 0.2.85; registry.npmjs.org publishes 0.3.310 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/core — @babel/core is pinned at 7.29.7; registry.npmjs.org publishes 8.0.9 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/plugin-transform-class-properties — @babel/plugin-transform-class-properties is pinned at 7.29.7; registry.npmjs.org publishes 8.0.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/plugin-transform-export-namespace-from — @babel/plugin-transform-export-namespace-from is pinned at 7.27.1; registry.npmjs.org publishes 8.0.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/plugin-transform-numeric-separator — @babel/plugin-transform-numeric-separator is pinned at 7.29.7; registry.npmjs.org publishes 8.0.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/plugin-transform-object-rest-spread — @babel/plugin-transform-object-rest-spread is pinned at 7.29.7; registry.npmjs.org publishes 8.0.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/plugin-transform-runtime — @babel/plugin-transform-runtime is pinned at 7.29.0; registry.npmjs.org publishes 8.0.6 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/preset-env — @babel/preset-env is pinned at 7.29.2; registry.npmjs.org publishes 8.0.7 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/preset-react — @babel/preset-react is pinned at 7.28.5; registry.npmjs.org publishes 8.0.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @babel/preset-typescript — @babel/preset-typescript is pinned at 7.29.7; registry.npmjs.org publishes 8.0.7 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @chromatic-com/storybook — @chromatic-com/storybook is pinned at 5.1.2; registry.npmjs.org publishes 5.6.0 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @joshwooding/vite-plugin-react-docgen-typescript — @joshwooding/vite-plugin-react-docgen-typescript is pinned at 0.7.0; registry.npmjs.org publishes 0.9.0 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @next/env — @next/env is pinned at 16.2.12; registry.npmjs.org publishes 16.4.3 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @octokit/request — @octokit/request is pinned at 8.4.1; registry.npmjs.org publishes 10.0.16 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @openai/codex-sdk — @openai/codex-sdk is pinned at 0.117.0; registry.npmjs.org publishes 0.164.0 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @playwright/test — @playwright/test is pinned at 1.58.2; registry.npmjs.org publishes 1.64.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @pmmmwh/react-refresh-webpack-plugin — @pmmmwh/react-refresh-webpack-plugin is pinned at 0.5.17; registry.npmjs.org publishes 0.6.3 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @rollup/pluginutils — @rollup/pluginutils is pinned at 5.4.0; registry.npmjs.org publishes 5.5.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @storybook/addon-designs — @storybook/addon-designs is pinned at 11.0.3; registry.npmjs.org publishes 12.0.0 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @storybook/icons — @storybook/icons is pinned at 2.1.0; registry.npmjs.org publishes 2.2.0 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @testing-library/dom — @testing-library/dom is pinned at 10.4.1; registry.npmjs.org publishes 10.4.2 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @testing-library/jest-dom — @testing-library/jest-dom is pinned at 6.9.1; registry.npmjs.org publishes 7.0.1 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @testing-library/react — @testing-library/react is pinned at 16.3.0; registry.npmjs.org publishes 16.3.3 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • Outdated (npm): @testing-library/user-event — @testing-library/user-event is pinned at 14.6.7; registry.npmjs.org publishes 14.6.8 as the latest release. Upgrading is a judgement call — read that package's changelog for what changed between the two — but a direct production dependency several releases behind is where security and compatibility debt accumulates silently.
  • + 100 more in this group — see findings.md.
D10 · Test Quality · Skipped (documented) · ×34
  • Skipped (documented): (unnamed test) code/renderers/vue3/src/docgen/dist-contract.test.ts:11 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/renderers/vue3/src/docgen/dist-contract.test.ts:15 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/renderers/react/src/dist-contract.test.ts:33 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/renderers/react/src/dist-contract.test.ts:37 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/renderers/react/src/dist-contract.test.ts:48 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/lib/mcp/src/dist-contract.test.ts:90 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/lib/mcp/src/dist-contract.test.ts:107 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/lib/mcp/src/dist-contract.test.ts:111 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/lib/mcp/src/dist-contract.test.ts:121 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/lib/mcp/src/dist-contract.test.ts:155 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): should support non-conventional formats code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.test.ts:407 — Skipped with a documented reason — a deferral, not lazy debt: declared with it.todo — a placeholder that registers a name and runs nothing
  • Skipped (documented): should support non-conventional formats code/lib/cli-storybook/src/codemod/helpers/story-to-csf-factory.test.ts:1519 — Skipped with a documented reason — a deferral, not lazy debt: declared with it.todo — a placeholder that registers a name and runs nothing
  • Skipped (documented): (unnamed test) code/lib/claude-plugin/plugin.test.ts:166 — Skipped with a documented reason — a deferral, not lazy debt: switched off by it.skipIf
  • Skipped (documented): (unnamed test) code/core/src/theming/dist-contract.test.ts:75 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/theming/dist-contract.test.ts:80 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/theming/dist-contract.test.ts:95 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/theming/dist-contract.test.ts:106 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/theming/dist-contract.test.ts:116 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/theming/dist-contract.test.ts:127 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/test/dist-contract.test.ts:31 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/test/dist-contract.test.ts:35 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/test/dist-contract.test.ts:45 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): (unnamed test) code/core/src/test/dist-contract.test.ts:55 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • Skipped (documented): heals a writer that went quiet across a burst and an eviction code/core/src/shared/open-service/sync-simulation.test.ts:604 — Skipped with a documented reason — a deferral, not lazy debt: declared it.fails — the body is expected to fail, so its failure is not reported
  • Skipped (documented): (unnamed test) code/core/src/shared/open-service/toolsets/docs/portable-dist.test.ts:69 — Skipped with a documented reason — a deferral, not lazy debt: declared with no body — a pending test the runner lists but never runs
  • + 9 more in this group — see findings.md.

Appendix B — Reproduction & audit trail

Every external tool invocation behind a deep-scan dimension — the tool, its captured version, the exact command, how many findings it yielded, and a link to the retained raw output. To reproduce any finding: check out the same commit and run the command shown (repo-relative — never an absolute scratch path). The complete raw scanner output is retained verbatim under artifacts/raw/ (indexed in artifacts/raw/index.json); per-invocation exit codes and wall-clock durations are in sidecar.json — kept out of this table so the rendered report stays byte-identical across runs of the same commit.

DimensionToolVersionCommandFindingsRaw output
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-ae34fe29fb9a4e23a2f29a0b8d8eb6ff/history.json --exit-code 0 --source .114artifacts/raw/gitleaks-history.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-git --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-ae34fe29fb9a4e23a2f29a0b8d8eb6ff/tree.json --exit-code 0 --source .3artifacts/raw/gitleaks-tree.json
D29 · Static Analysis (SAST)semgrep—semgrep --config /opt/semgrep-rules/security-audit.yml --config /opt/semgrep-rules/owasp-top-ten.yml --config /opt/semgrep-rules/watchdog-sast.yml --json --quiet --timeout 10 --timeout-threshold 3 --metrics off --exclude *.arrow --exclude *.avro --exclude *.csv --exclude *.dat --exclude *.db --exclude *.feather --exclude *.geojson --exclude *.h5 --exclude *.hdf5 --exclude *.jsonl --exclude *.log --exclude *.ndjson --exclude *.npy --exclude *.npz --exclude *.orc --exclude *.parquet --exclude *.pickle --exclude *.pkl --exclude *.psv --exclude *.sqlite --exclude *.sqlite3 --exclude *.tfrecord --exclude *.tsv --exclude *.txt --exclude .yarn --exclude agent-eval/templates/reshaped-storybook/public --exclude scripts/build .99artifacts/raw/semgrep.json
D30 · Dependency Vulnerabilitiestrivy—trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** . --skip-db-update134artifacts/raw/trivy-fs.json
D31 · IaC & Container Securitytrivy—trivy: not applicable — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.0—
D32 · Data Compliance (PII/GDPR)semgrep—semgrep: not applicable — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that. semgrep could not parse 307 file(s) — `agent-eval/evals/803-edit-component/stories/ReviewCard.stories.tsx`, `agent-eval/evals/804-write-story-for-existing-component/stories/ReviewCard.stories.tsx`, `agent-eval/evals/805-non-visual-refactor/stories/ReviewCard.stories.tsx`, `agent-eval/evals/806-browse-request/stories/ReviewCard.stories.tsx`, `agent-eval/evals/807-docs-request/stories/ReviewCard.stories.tsx`, … (+302 more) — so the PII/GDPR sweep did not cover the unparsed regions of them; rows reported elsewhere in those files are real.0—
D40 · Network Egress Confinementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.0—
D41 · Kernel & Syscall Confinementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.0—
D42 · Runtime Threat Enforcementruntime-hardening—runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.0—
D43 · Malicious Dependenciestrivy—trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** . --skip-db-update0artifacts/raw/trivy-fs.json

Run 01a17828-1045-7687-8f56-5f3cc7987208 · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.

Downloadable artifacts

Machine-readable and reproducible from this commit + frozen rubric — drop them straight into a contract appendix, a CRA dossier, or a downstream SCA / VEX tool.

⬇ Findings, MITRE CWE-tagged .sarif⬇ Health changelog .md