Public report of eghrhegpe/ysm-model-manager, published 17 November 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 reportMeasured under the Code Assurance Index, an open standard for code quality, using its published scoring rules (rubric version 2026.11.4). 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, 17 November 2026, 09:36 UTC · Survey ID cd_27a8c25ac13141439aeb29a7de5f2fa9
eghrhegpe/ysm-model-manager
Measured 17 November 2026, 09:33 UTC, at code version d74f850
First survey, so nothing to compare with yet
CAI scoreAdequate
CriticalWeakAdequateStrongExemplary
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: 246,924 lines of product code in 4 projects, tests not counted · Estimated rebuild effort: about 3.8 person-years · Weakest lens: Accessibility, 49.6
Findings by how serious they are
110 critical942 serious163 minor
15 dimensions are left out of the score. For each one, we either couldn't measure it in this code, or found no evidence of the safeguard we look 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
Canine Code Analyzer
Producer
Canine Development
Analyzer
Canine Code Analyzer engine 1.0.0
Measured
17 November 2026, 09:33 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 the Canine Code Analyzer. It is open to any tool that
implements it, and today the Canine Code Analyzer is the only one that does.
The score is deterministic, which means the same code always gets the same score. We work 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 ▸
79of 79 dimensions measured by tools.
1201of 1215 findings point to an exact file and line, so you can open each one in the code. The other 14 concern the repository as a whole, such as missing documentation.
79dimensions across 7 lenses, read from 246,924 lines of product code in 4 projects.
eghrhegpe/ysm-model-manager falls short of our standard for production because it has controls that only work with a mouse. It scores 57.7 out of 100 and is rated Adequate, and 69 of its 110 critical findings are security problems.
Accessibility, at 49.6, is the weakest lens and counts most in the score. The best first step is making the controls keyboard-usable, worth about 4.0 points. Adding text alternatives comes next, worth about 3.0 points. Raising Accessibility to 70 would lift the score to about 64.1.
Fifty-four pipeline tools are referenced by a changeable name, so the build pipeline can be tampered with. Ten known security holes in the packages the code depends on can be used by attackers, and fourteen form fields can't be read by a screen reader. Pinning each tool to an exact version, updating the vulnerable packages and labelling the form fields would close these risks. Setting a waiting period for automatic updates would fix the automatic dependency update that takes a new release at once, and passing outside input through environment variables would deal with the pipeline step that puts outside input straight into a shell command. The 13 sets of files in separate parts that keep changing together need that dependency made explicit.
The product code is 246,924 lines, about €550,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 forThe 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.
If Accessibility rose from 49.6 to 70, the lowest score rated Strong, the score would rise from 57.7 to about 64.1.
Code composition: what the lines of code are
Product code 51%Tests 49%
Rebuild cost: about €550,000 · Estimate
Cost to rebuild
€180,000 to €920,000, for 3,058 to 9,702 hours of work, about 3.8 person-years for 2 to 8 engineers
Difficulty of the problem
Standard, 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.8 at a score of 58. 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.
Size
Large: 246,924 lines of product code
What it is not
Not 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: We price 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
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.
Raises the score by about 4.0 points · Medium effort · Keyboard semantics
2
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.
Raises the score by about 3.0 points · Medium effort · Text alternatives
3
Resolve the 1 End-of-life runtime finding(s) in Platform End-of-Life — start with package.json.
Each conclusion below combines several dimensions into one point that no single dimension shows, and lists the measurements it rests on.
Where the investment is most exposed · Value at risk
This code would cost about €550,000 to build again, about 3.8 person-years of work. Its weakest lens is Accessibility, at 49.6 (Weak). Accessibility is about whether the interface is built so that everyone can use it, including people who can't see the screen or can't use a mouse. Because the weakest lens counts most in the score, work on Accessibility also moves the score most.
Based on: the rebuild estimate · the Accessibility grade · how much each lens counts
What to do: Start with the Accessibility actions in Top priorities.
If you do one thing first · First action
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href. Of all the actions in this report, it raises the score most for the work it takes: about 4.0 points for medium effort. The next survey will show the change in the score.
Based on: the ranked actions in Top priorities, by score gain and effort
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.
570 modules, with 626 dependencies between them. 2 loops run through 16 of the modules, marked above the diagonal.
The table shows the 40 modules with the most connections; 530 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.
frontend.src.backend uses frontend.bindings.ysm-model-manager.go.types.models, so a change to frontend.bindings.ysm-model-manager.go.types.models can break frontend.src.backend, while a change to frontend.src.backend can't break frontend.bindings.ysm-model-manager.go.types.models.
Position
Below the diagonal: frontend.src.backend uses a module listed above it, which is the healthy direction.
frontend.src.backend uses frontend.src.parsers.bedrock-geometry, so a change to frontend.src.parsers.bedrock-geometry can break frontend.src.backend, while a change to frontend.src.backend can't break frontend.src.parsers.bedrock-geometry.
Position
Below the diagonal: frontend.src.backend uses a module listed above it, which is the healthy direction.
frontend.src.features.community uses frontend.bindings.ysm-model-manager.go.types.models, so a change to frontend.bindings.ysm-model-manager.go.types.models can break frontend.src.features.community, while a change to frontend.src.features.community can't break frontend.bindings.ysm-model-manager.go.types.models.
Position
Below the diagonal: frontend.src.features.community uses a module listed above it, which is the healthy direction.
frontend.src.parsers uses frontend.src.parsers.bedrock-geometry, so a change to frontend.src.parsers.bedrock-geometry can break frontend.src.parsers, while a change to frontend.src.parsers can't break frontend.src.parsers.bedrock-geometry.
Position
Below the diagonal: frontend.src.parsers uses a module listed above it, which is the healthy direction.
1 pair of types, where a type in frontend.src.preview-3d.adapters.shared.perception uses a type in frontend.src.preview-3d.adapters.shared.perception.core.
frontend.src.preview-3d.adapters.shared.perception uses frontend.src.preview-3d.adapters.shared.perception.core, so a change to frontend.src.preview-3d.adapters.shared.perception.core can break frontend.src.preview-3d.adapters.shared.perception, while a change to frontend.src.preview-3d.adapters.shared.perception can't break frontend.src.preview-3d.adapters.shared.perception.core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.shared.perception uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.infra uses frontend.bindings.ysm-model-manager.go.dedup.models, so a change to frontend.bindings.ysm-model-manager.go.dedup.models can break frontend.src.preview-3d.infra, while a change to frontend.src.preview-3d.infra can't break frontend.bindings.ysm-model-manager.go.dedup.models.
Position
Below the diagonal: frontend.src.preview-3d.infra uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.infra uses frontend.bindings.ysm-model-manager.go.types.models, so a change to frontend.bindings.ysm-model-manager.go.types.models can break frontend.src.preview-3d.infra, while a change to frontend.src.preview-3d.infra can't break frontend.bindings.ysm-model-manager.go.types.models.
Position
Below the diagonal: frontend.src.preview-3d.infra uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.menu.engine.core uses frontend.src.preview-3d.menu.schema.menu-node-types, so a change to frontend.src.preview-3d.menu.schema.menu-node-types can break frontend.src.preview-3d.menu.engine.core, while a change to frontend.src.preview-3d.menu.engine.core can't break frontend.src.preview-3d.menu.schema.menu-node-types.
Position
Below the diagonal: frontend.src.preview-3d.menu.engine.core uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.menu.engine.core uses frontend.src.preview-3d.menu.shell.slide-menu, so a change to frontend.src.preview-3d.menu.shell.slide-menu can break frontend.src.preview-3d.menu.engine.core, while a change to frontend.src.preview-3d.menu.engine.core can't break frontend.src.preview-3d.menu.shell.slide-menu.
Position
Below the diagonal: frontend.src.preview-3d.menu.engine.core uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.menu.panels uses frontend.bindings.ysm-model-manager.go.types.models, so a change to frontend.bindings.ysm-model-manager.go.types.models can break frontend.src.preview-3d.menu.panels, while a change to frontend.src.preview-3d.menu.panels can't break frontend.bindings.ysm-model-manager.go.types.models.
Position
Below the diagonal: frontend.src.preview-3d.menu.panels uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.menu.panels uses frontend.src.preview-3d.caps.scene-capability, so a change to frontend.src.preview-3d.caps.scene-capability can break frontend.src.preview-3d.menu.panels, while a change to frontend.src.preview-3d.menu.panels can't break frontend.src.preview-3d.caps.scene-capability.
Position
Below the diagonal: frontend.src.preview-3d.menu.panels uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.menu.panels uses frontend.src.preview-3d.menu.schema.menu-node-types, so a change to frontend.src.preview-3d.menu.schema.menu-node-types can break frontend.src.preview-3d.menu.panels, while a change to frontend.src.preview-3d.menu.panels can't break frontend.src.preview-3d.menu.schema.menu-node-types.
Position
Below the diagonal: frontend.src.preview-3d.menu.panels uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.menu.panels uses frontend.src.preview-3d.menu.shell.slide-menu, so a change to frontend.src.preview-3d.menu.shell.slide-menu can break frontend.src.preview-3d.menu.panels, while a change to frontend.src.preview-3d.menu.panels can't break frontend.src.preview-3d.menu.shell.slide-menu.
Position
Below the diagonal: frontend.src.preview-3d.menu.panels uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.mesh.model3d uses frontend.bindings.ysm-model-manager.go.dedup.models, so a change to frontend.bindings.ysm-model-manager.go.dedup.models can break frontend.src.preview-3d.mesh.model3d, while a change to frontend.src.preview-3d.mesh.model3d can't break frontend.bindings.ysm-model-manager.go.dedup.models.
Position
Below the diagonal: frontend.src.preview-3d.mesh.model3d uses a module listed above it, which is the healthy direction.
frontend.src.views.app-content.diagnostics uses frontend.bindings.ysm-model-manager.go.types.models, so a change to frontend.bindings.ysm-model-manager.go.types.models can break frontend.src.views.app-content.diagnostics, while a change to frontend.src.views.app-content.diagnostics can't break frontend.bindings.ysm-model-manager.go.types.models.
Position
Below the diagonal: frontend.src.views.app-content.diagnostics uses a module listed above it, which is the healthy direction.
frontend.src.views.app-content.site uses frontend.bindings.ysm-model-manager.go.types.models, so a change to frontend.bindings.ysm-model-manager.go.types.models can break frontend.src.views.app-content.site, while a change to frontend.src.views.app-content.site can't break frontend.bindings.ysm-model-manager.go.types.models.
Position
Below the diagonal: frontend.src.views.app-content.site uses a module listed above it, which is the healthy direction.
ysm-model-manager/go/cli uses ysm-model-manager/go/types, so a change to ysm-model-manager/go/types can break ysm-model-manager/go/cli, while a change to ysm-model-manager/go/cli can't break ysm-model-manager/go/types.
Position
Below the diagonal: ysm-model-manager/go/cli uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.mount-preview-core uses frontend.src.preview-3d.menu.engine.core, so a change to frontend.src.preview-3d.menu.engine.core can break frontend.src.preview-3d.adapters.mount-preview-core, while a change to frontend.src.preview-3d.adapters.mount-preview-core can't break frontend.src.preview-3d.menu.engine.core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.mount-preview-core uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.mount-preview-core uses frontend.src.preview-3d.mesh.model3d, so a change to frontend.src.preview-3d.mesh.model3d can break frontend.src.preview-3d.adapters.mount-preview-core, while a change to frontend.src.preview-3d.adapters.mount-preview-core can't break frontend.src.preview-3d.mesh.model3d.
Position
Below the diagonal: frontend.src.preview-3d.adapters.mount-preview-core uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.bone uses frontend.bindings.ysm-model-manager.go.dedup.models, so a change to frontend.bindings.ysm-model-manager.go.dedup.models can break frontend.src.preview-3d.bone, while a change to frontend.src.preview-3d.bone can't break frontend.bindings.ysm-model-manager.go.dedup.models.
Position
Below the diagonal: frontend.src.preview-3d.bone uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.bone uses frontend.src.preview-3d.mesh.model3d, so a change to frontend.src.preview-3d.mesh.model3d can break frontend.src.preview-3d.bone, while a change to frontend.src.preview-3d.bone can't break frontend.src.preview-3d.mesh.model3d.
Position
Below the diagonal: frontend.src.preview-3d.bone uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.infra.content-bridges uses frontend.src.preview-3d.mesh.model3d, so a change to frontend.src.preview-3d.mesh.model3d can break frontend.src.preview-3d.infra.content-bridges, while a change to frontend.src.preview-3d.infra.content-bridges can't break frontend.src.preview-3d.mesh.model3d.
Position
Below the diagonal: frontend.src.preview-3d.infra.content-bridges uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.model uses frontend.bindings.ysm-model-manager.go.types.models, so a change to frontend.bindings.ysm-model-manager.go.types.models can break frontend.src.preview-3d.model, while a change to frontend.src.preview-3d.model can't break frontend.bindings.ysm-model-manager.go.types.models.
Position
Below the diagonal: frontend.src.preview-3d.model uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.model uses frontend.src.utils.animation.animation, so a change to frontend.src.utils.animation.animation can break frontend.src.preview-3d.model, while a change to frontend.src.preview-3d.model can't break frontend.src.utils.animation.animation.
Position
Below the diagonal: frontend.src.preview-3d.model uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.model uses frontend.src.preview-3d.mesh.model3d, so a change to frontend.src.preview-3d.mesh.model3d can break frontend.src.preview-3d.model, while a change to frontend.src.preview-3d.model can't break frontend.src.preview-3d.mesh.model3d.
Position
Below the diagonal: frontend.src.preview-3d.model uses a module listed above it, which is the healthy direction.
44 pairs of types, where a type in ysm-model-manager/internal/app uses a type in ysm-model-manager/go/types. Showing 25 of them; the rest are in namespace-graph.json in this report's bundle.
ysm-model-manager/internal/app uses ysm-model-manager/go/types, so a change to ysm-model-manager/go/types can break ysm-model-manager/internal/app, while a change to ysm-model-manager/internal/app can't break ysm-model-manager/go/types.
Position
Below the diagonal: ysm-model-manager/internal/app uses a module listed above it, which is the healthy direction.
ysm-model-manager/internal/app uses ysm-model-manager/go/cli, so a change to ysm-model-manager/go/cli can break ysm-model-manager/internal/app, while a change to ysm-model-manager/internal/app can't break ysm-model-manager/go/cli.
Position
Below the diagonal: ysm-model-manager/internal/app uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.mmd.mmd-types uses frontend.src.preview-3d.adapters.mount-preview-core, so a change to frontend.src.preview-3d.adapters.mount-preview-core can break frontend.src.preview-3d.adapters.mmd.mmd-types, while a change to frontend.src.preview-3d.adapters.mmd.mmd-types can't break frontend.src.preview-3d.adapters.mount-preview-core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.mmd.mmd-types uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.mmd.mmd-types uses frontend.src.preview-3d.infra.content-bridges, so a change to frontend.src.preview-3d.infra.content-bridges can break frontend.src.preview-3d.adapters.mmd.mmd-types, while a change to frontend.src.preview-3d.adapters.mmd.mmd-types can't break frontend.src.preview-3d.infra.content-bridges.
Position
Below the diagonal: frontend.src.preview-3d.adapters.mmd.mmd-types uses a module listed above it, which is the healthy direction.
1 pair of types, where a type in frontend.src.preview-3d.adapters.vrm.vrm-perception uses a type in frontend.src.preview-3d.adapters.shared.perception.core.
frontend.src.preview-3d.adapters.vrm.vrm-perception uses frontend.src.preview-3d.adapters.shared.perception.core, so a change to frontend.src.preview-3d.adapters.shared.perception.core can break frontend.src.preview-3d.adapters.vrm.vrm-perception, while a change to frontend.src.preview-3d.adapters.vrm.vrm-perception can't break frontend.src.preview-3d.adapters.shared.perception.core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.vrm.vrm-perception uses a module listed above it, which is the healthy direction.
2 pairs of types, where a type in frontend.src.preview-3d.adapters.vrm.vrm-perception uses a type in frontend.src.preview-3d.adapters.mount-preview-core.
frontend.src.preview-3d.adapters.vrm.vrm-perception uses frontend.src.preview-3d.adapters.mount-preview-core, so a change to frontend.src.preview-3d.adapters.mount-preview-core can break frontend.src.preview-3d.adapters.vrm.vrm-perception, while a change to frontend.src.preview-3d.adapters.vrm.vrm-perception can't break frontend.src.preview-3d.adapters.mount-preview-core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.vrm.vrm-perception uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.ysm-adapter uses frontend.src.parsers.bedrock-geometry, so a change to frontend.src.parsers.bedrock-geometry can break frontend.src.preview-3d.adapters.ysm-adapter, while a change to frontend.src.preview-3d.adapters.ysm-adapter can't break frontend.src.parsers.bedrock-geometry.
Position
Below the diagonal: frontend.src.preview-3d.adapters.ysm-adapter uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.ysm-adapter uses frontend.src.preview-3d.adapters.shared.perception.core, so a change to frontend.src.preview-3d.adapters.shared.perception.core can break frontend.src.preview-3d.adapters.ysm-adapter, while a change to frontend.src.preview-3d.adapters.ysm-adapter can't break frontend.src.preview-3d.adapters.shared.perception.core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.ysm-adapter uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.ysm-adapter uses frontend.src.preview-3d.mesh.model3d, so a change to frontend.src.preview-3d.mesh.model3d can break frontend.src.preview-3d.adapters.ysm-adapter, while a change to frontend.src.preview-3d.adapters.ysm-adapter can't break frontend.src.preview-3d.mesh.model3d.
Position
Below the diagonal: frontend.src.preview-3d.adapters.ysm-adapter uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.ysm-adapter uses frontend.src.preview-3d.adapters.mount-preview-core, so a change to frontend.src.preview-3d.adapters.mount-preview-core can break frontend.src.preview-3d.adapters.ysm-adapter, while a change to frontend.src.preview-3d.adapters.ysm-adapter can't break frontend.src.preview-3d.adapters.mount-preview-core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.ysm-adapter uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.ysm-adapter uses frontend.src.preview-3d.infra.content-bridges, so a change to frontend.src.preview-3d.infra.content-bridges can break frontend.src.preview-3d.adapters.ysm-adapter, while a change to frontend.src.preview-3d.adapters.ysm-adapter can't break frontend.src.preview-3d.infra.content-bridges.
Position
Below the diagonal: frontend.src.preview-3d.adapters.ysm-adapter uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters uses frontend.src.parsers.bedrock-geometry, so a change to frontend.src.parsers.bedrock-geometry can break frontend.src.preview-3d.adapters, while a change to frontend.src.preview-3d.adapters can't break frontend.src.parsers.bedrock-geometry.
Position
Below the diagonal: frontend.src.preview-3d.adapters uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters uses frontend.src.preview-3d.adapters.shared.perception.core, so a change to frontend.src.preview-3d.adapters.shared.perception.core can break frontend.src.preview-3d.adapters, while a change to frontend.src.preview-3d.adapters can't break frontend.src.preview-3d.adapters.shared.perception.core.
Position
Below the diagonal: frontend.src.preview-3d.adapters uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters uses frontend.src.preview-3d.menu.engine.core, so a change to frontend.src.preview-3d.menu.engine.core can break frontend.src.preview-3d.adapters, while a change to frontend.src.preview-3d.adapters can't break frontend.src.preview-3d.menu.engine.core.
Position
Below the diagonal: frontend.src.preview-3d.adapters uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters uses frontend.src.preview-3d.adapters.mount-preview-core, so a change to frontend.src.preview-3d.adapters.mount-preview-core can break frontend.src.preview-3d.adapters, while a change to frontend.src.preview-3d.adapters can't break frontend.src.preview-3d.adapters.mount-preview-core.
Position
Below the diagonal: frontend.src.preview-3d.adapters uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters uses frontend.src.preview-3d.adapters.ysm-adapter, so a change to frontend.src.preview-3d.adapters.ysm-adapter can break frontend.src.preview-3d.adapters, while a change to frontend.src.preview-3d.adapters can't break frontend.src.preview-3d.adapters.ysm-adapter.
Position
Below the diagonal: frontend.src.preview-3d.adapters uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.mmd uses frontend.src.preview-3d.adapters.mount-preview-core, so a change to frontend.src.preview-3d.adapters.mount-preview-core can break frontend.src.preview-3d.adapters.mmd, while a change to frontend.src.preview-3d.adapters.mmd can't break frontend.src.preview-3d.adapters.mount-preview-core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.mmd uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.mmd uses frontend.src.preview-3d.infra.content-bridges, so a change to frontend.src.preview-3d.infra.content-bridges can break frontend.src.preview-3d.adapters.mmd, while a change to frontend.src.preview-3d.adapters.mmd can't break frontend.src.preview-3d.infra.content-bridges.
Position
Below the diagonal: frontend.src.preview-3d.adapters.mmd uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.mmd uses frontend.src.preview-3d.adapters.mmd.mmd-types, so a change to frontend.src.preview-3d.adapters.mmd.mmd-types can break frontend.src.preview-3d.adapters.mmd, while a change to frontend.src.preview-3d.adapters.mmd can't break frontend.src.preview-3d.adapters.mmd.mmd-types.
Position
Below the diagonal: frontend.src.preview-3d.adapters.mmd uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.vrm uses frontend.src.utils.animation.animation, so a change to frontend.src.utils.animation.animation can break frontend.src.preview-3d.adapters.vrm, while a change to frontend.src.preview-3d.adapters.vrm can't break frontend.src.utils.animation.animation.
Position
Below the diagonal: frontend.src.preview-3d.adapters.vrm uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.vrm uses frontend.src.preview-3d.adapters.mount-preview-core, so a change to frontend.src.preview-3d.adapters.mount-preview-core can break frontend.src.preview-3d.adapters.vrm, while a change to frontend.src.preview-3d.adapters.vrm can't break frontend.src.preview-3d.adapters.mount-preview-core.
Position
Below the diagonal: frontend.src.preview-3d.adapters.vrm uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.vrm uses frontend.src.preview-3d.infra.content-bridges, so a change to frontend.src.preview-3d.infra.content-bridges can break frontend.src.preview-3d.adapters.vrm, while a change to frontend.src.preview-3d.adapters.vrm can't break frontend.src.preview-3d.infra.content-bridges.
Position
Below the diagonal: frontend.src.preview-3d.adapters.vrm uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.adapters.vrm uses frontend.src.preview-3d.adapters.vrm.vrm-perception, so a change to frontend.src.preview-3d.adapters.vrm.vrm-perception can break frontend.src.preview-3d.adapters.vrm, while a change to frontend.src.preview-3d.adapters.vrm can't break frontend.src.preview-3d.adapters.vrm.vrm-perception.
Position
Below the diagonal: frontend.src.preview-3d.adapters.vrm uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.decoder uses frontend.src.parsers.bedrock-geometry, so a change to frontend.src.parsers.bedrock-geometry can break frontend.src.preview-3d.decoder, while a change to frontend.src.preview-3d.decoder can't break frontend.src.parsers.bedrock-geometry.
Position
Below the diagonal: frontend.src.preview-3d.decoder uses a module listed above it, which is the healthy direction.
frontend.src.preview-3d.decoder uses frontend.src.preview-3d.adapters.mmd.mmd-types, so a change to frontend.src.preview-3d.adapters.mmd.mmd-types can break frontend.src.preview-3d.decoder, while a change to frontend.src.preview-3d.decoder can't break frontend.src.preview-3d.adapters.mmd.mmd-types.
Position
Below the diagonal: frontend.src.preview-3d.decoder uses a module listed above it, which is the healthy direction.
frontend.src.views.app-preview uses frontend.bindings.ysm-model-manager.go.types.models, so a change to frontend.bindings.ysm-model-manager.go.types.models can break frontend.src.views.app-preview, while a change to frontend.src.views.app-preview can't break frontend.bindings.ysm-model-manager.go.types.models.
Position
Below the diagonal: frontend.src.views.app-preview uses a module listed above it, which is the healthy direction.
frontend.src.views.app-preview uses frontend.src.parsers.bedrock-geometry, so a change to frontend.src.parsers.bedrock-geometry can break frontend.src.views.app-preview, while a change to frontend.src.views.app-preview can't break frontend.src.parsers.bedrock-geometry.
Position
Below the diagonal: frontend.src.views.app-preview uses a module listed above it, which is the healthy direction.
frontend.src.views.app-preview uses frontend.src.preview-3d.mesh.model3d, so a change to frontend.src.preview-3d.mesh.model3d can break frontend.src.views.app-preview, while a change to frontend.src.views.app-preview can't break frontend.src.preview-3d.mesh.model3d.
Position
Below the diagonal: frontend.src.views.app-preview uses a module listed above it, which is the healthy direction.
frontend.src.views.app-preview uses frontend.src.preview-3d.adapters.mount-preview-core, so a change to frontend.src.preview-3d.adapters.mount-preview-core can break frontend.src.views.app-preview, while a change to frontend.src.views.app-preview can't break frontend.src.preview-3d.adapters.mount-preview-core.
Position
Below the diagonal: frontend.src.views.app-preview uses a module listed above it, which is the healthy direction.
frontend.src.views.app-preview uses frontend.src.preview-3d.infra.content-bridges, so a change to frontend.src.preview-3d.infra.content-bridges can break frontend.src.views.app-preview, while a change to frontend.src.views.app-preview can't break frontend.src.preview-3d.infra.content-bridges.
Position
Below the diagonal: frontend.src.views.app-preview uses a module listed above it, which is the healthy direction.
frontend.src.views.app-preview uses frontend.src.preview-3d.adapters.mmd.mmd-types, so a change to frontend.src.preview-3d.adapters.mmd.mmd-types can break frontend.src.views.app-preview, while a change to frontend.src.views.app-preview can't break frontend.src.preview-3d.adapters.mmd.mmd-types.
Position
Below the diagonal: frontend.src.views.app-preview uses a module listed above it, which is the healthy direction.
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 category
Findings
Severity
A05:2025 — Injection
81
High / Critical
A03:2025 — Software Supply Chain Failures
24
High / Critical
Roadmap
Top priorities: Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href; 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; Declare <html lang>, a document <title> and a <main> landmark, keep headings in order, leave zoom enabled, title iframes and drop meta-refresh.
Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.
Do this
Helps
Effort
Dimension
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.
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.
Resolve the 9 REDACTED finding(s) charged to Static Analysis (SAST) — the other 45 are reported here at file:line but scored by D36 (supply-chain provenance), which charges them once.
Test Quality: No assertions (empty test): 可见面板三连切(A→B→C):pending 只留最新,补扫按 C
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 — 110
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 — 942
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 — 163
Recorded, with no effect on how the codebase functions.
Present so the survey is complete, not because it needs doing.
Could not be resolved — 15
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
This survey 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. All 79 evaluated dimensions are computed by tools and static analysis; no language model sets or judges any of them. Overall confidence is 1.0, the weighted average across measured dimensions.
Every figure here is one of two 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. 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.
What we checked — 79 dimensions across the health lenses
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
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, 1201 of 1215 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.)
Is there a tool behind the number? Every score below names the method that produced it: Roslyn, git or a scanner, not a narrative.
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.
Method
Backs
Version
Evaluator
Roslyn static analysis
Complexity, cohesion, coupling, dead code, API surface, layering
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.
D8 Code Coverage — not measured this run — We 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. Coverage NOT MEASURED: this repository's production source spans .ts, .go, and our analyzer cannot run the .go test suite(s) — so no coverage was collected for the repository as a whole. The JavaScript/TypeScript half did build and run, and its own line coverage came back at 95.5% — but that is a figure for one half of the product, and we do not publish a partial one as if it were complete. This is OUR limitation, not a defect in the repo — coverage is excluded from the score rather than counted as a near-zero.
D10 Test Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we 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. The 8,549 test(s) behind this row are the ones the JavaScript/TypeScript census could read, and this repository also carries at least 427 test source file(s) (.go) that it cannot: it reads JavaScript/TypeScript test declarations off disk, so a JUnit/pytest-style suite is invisible to it. Skipped tests, zero-assertion tests and the other quality signals on this row are UNMEASURED in that suite — their absence from the counts above is a gap in this analyzer's language coverage, not a finding that those tests are sound.
D14 License Compliance — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 repository declares a Go module (REDACTED/go.sum), but the licence verdict published here was taken over its npm package dependencies. Nothing was read about its Go dependencies' licensing in either direction, and a clean score on this card must not be read as covering them.
D14 License Compliance — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 repository declares a Cargo manifest, but the licence verdict published here was taken over its npm package dependencies. Nothing was read about its Cargo dependencies' licensing in either direction, and a clean score on this card must not be read as covering them.
D16 Bus Factor — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. Single-maintainer repository — bus factor is not applicable (2 contributor(s) across 5987 commit(s) sampled, automation and bot accounts excluded). One of them holds 99% of the history; the other 1 hold 1% each on average, below the 5% at which there is somebody to hand the work to. That is a single maintainer with drive-by contributors, not a team whose knowledge has concentrated — so the bus factor is not applicable and there is nothing here for the owner to act on.
D19 Documentation Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we 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.
D19 Documentation Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we 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.
D20 ADR Quality — not measured this run — We 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. The ADR lexicon (adr-lexicon-1) covers de, en, it, nl. A record identified as another language, or whose language could not be identified (fewer than 25 words of prose, or no clear winner), is never read with English rules: its missing-section, status, consequence-cost and same-question rules abstain, and only the structural rules (title, single option, dangling link, enforcement field) run.
D21 Naming Consistency — measured, with a gap in what it reached — We measured this, but not all of it. What we 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. PREREGISTRATION version 20's fallback (adjudication D21-sample3-v3): this rule kind was adjudicated below the 95 % precision gate, so its candidates are counted here and not published, and the score covers only the acronym-spelling and awaitable-suffix rules. The kind returns as rows only after it shows a measured precision; this says nothing about whether these names are consistent.
D24 Comment Value — measured, with a gap in what it reached — We measured this, but not all of it. What we 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. D24 compares a comment's words with the identifiers, literals and constructs of the code it annotates, using English function-word and rationale lexicons. Comments in another script or language were left unread rather than counted as clean.
D24 Comment Value — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 source language's comment syntax, and the code a comment annotates in it, needs its own proof before D24 judges it. Until then those comments are left unread, not counted as clean.
D27 Navigability — not measured this run — We 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.
D32 Data Compliance (PII/GDPR) — not measured this run — We 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. `frontend/src/backend/browser-adapter.ts`, `frontend/src/backend/web-common.ts`, `frontend/src/backend/web-community.ts`, `frontend/src/backend/web-fs.ts`, `frontend/src/backend/web-stats.ts`, … (+39 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.
AX1 Captive dependencies — not measured this run — We 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 Microsoft.Extensions.DependencyInjection registrations in C# and Spring beans in Java/Kotlin only, and this repository defines its own container in frontend/src/preview-3d/infra/scene-registry.ts, whose lifetimes are not modelled yet, 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.
AXB2 Runtime readiness — not measured this run — We 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. A program the dev server needs is not installed in our sandbox image. This is a limit of our sandbox, not of your repository. (rule: missing-tool). The renderer reported: the dev server (`npm run dev` in docs/) exited before it served a page. Likely cause (our sandbox): a program the dev server needs is not installed in our sandbox image. This is a limit of our sandbox, not of your repository. Last output: "> ysm-model-manager-docs@0.0.0 dev / > vitepress dev / sh: 1: vitepress: not found / npm error Lifecycle script `dev` failed with error: / npm error code 127 / npm error path <repo>/docs / npm error workspace ysm-model-manager-docs@0.0.0 / npm error location <repo>/docs / npm error command failed / npm error command sh -c vitepress dev" No runtime evidence was gathered.
AXR1 Runtime accessibility — not measured this run — We 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 (dev). the dev server (`npm run dev` in docs/) exited before it served a page. Likely cause (our sandbox): a program the dev server needs is not installed in our sandbox image. This is a limit of our sandbox, not of your repository. Last output: "> ysm-model-manager-docs@0.0.0 dev / > vitepress dev / sh: 1: vitepress: not found / npm error Lifecycle script `dev` failed with error: / npm error code 127 / npm error path <repo>/docs / npm error workspace ysm-model-manager-docs@0.0.0 / npm error location <repo>/docs / npm error command failed / npm error command sh -c vitepress dev" No runtime evidence was gathered.
C1 Data Protection — not measured this run — We 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. These personal data controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks personal data controls.
C2 Access Controls — not measured this run — We 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. These authorization controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks authorization controls.
C3 Audit Trail — not measured this run — We 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. These audit controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks audit controls.
C4 Data Retention — not measured this run — We 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. These retention controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks retention controls.
C5 Data-Subject Rights — not measured this run — We 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. These data-subject rights controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks data-subject rights controls.
M4 Documentation accuracy — measured, with a gap in what it reached — We measured this, but not all of it. What we 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), and artefact counts an order of magnitude off. 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.
P5 DR & Backup — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. No backup/snapshot/replication config, RTO/RPO or restore-procedure documentation was found — and no production persistence was detected either (no data-access packages, no data-store services, no database resources), so there is nothing in this repository whose loss a DR control would recover. If this system's data lives in a platform or ops repo we can't see, that's where the DR evidence belongs.
R10 Code Duplication — measured, with a gap in what it reached — We measured this, but not all of it. What we 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. 323 further occurrence(s) are not listed individually; the score already reflects all 363.
R2 Cyclomatic Complexity — measured, with a gap in what it reached — We measured this, but not all of it. What we 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. 375 further occurrence(s) are not listed individually; the score already reflects all 415.
R3 Large Files — measured, with a gap in what it reached — We measured this, but not all of it. What we 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. 45 further occurrence(s) are not listed individually; the score already reflects all 85.
S1 Web-Security Posture — not measured this run — We 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. These web-security controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks web-security controls.
X1 Async correctness — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X10 Duplicated predicate — not measured this run — We 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. 19 further occurrence(s) are not listed individually; the score already reflects all 59.
X12 Unreachable branch — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X13 Undrained process stream — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X16 Unfloored truncation loop — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X18 Disposal-pattern correctness — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X21 Side-effecting pattern guard — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X24 Document value interpolated into markup unescaped — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X24 Document value interpolated into markup unescaped — measured, with a gap in what it reached — We measured this, but not all of it. What we 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. 178 further occurrence(s) are not listed individually; the score already reflects all 218.
X25 Inert configuration knob — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X26 Unsynchronised callback handoff — not measured this run — We 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 most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X27 Collection changed while being enumerated — not measured this run — We 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 most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X29 Per-element action decided by a fixed element — measured, with a gap in what it reached — We measured this, but not all of it. What we 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 check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
X3 Exception handling — measured, with a gap in what it reached — We measured this, but not all of it. What we 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. 192 further occurrence(s) are not listed individually; the score already reflects all 232.
X7 Silent fallback defaults — not measured this run — We 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. 18 further occurrence(s) are not listed individually; the score already reflects all 58.
Repo exclusion declarations (.gitattributes linguist-generated/vendored, .editorconfig generated_code): none declared — every source file was scored.
Limitations & what we did not check
We assess the repository exactly as committed, and only the repository. By design we do 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.
D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
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.
D7 Architectural Integrity: Layering is checked against detected/declared rules — an architecture whose boundaries live in convention or in code review, not in a rule a scanner can read, is not enforced here.
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 — we run 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 Secret Scanning: Secret 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.
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.
D21 Naming Consistency: Naming consistency compares each name with the convention its structural peers follow in this repository: it cannot tell whether a consistently used name is a good one, and languages other than C# and TypeScript are not measured.
D22 Internal API Consistency: API consistency compares the call shapes of members that play the same role on the exposed C# surface: whether the API suits its callers is not measured, and surfaces in other languages are not measured.
D24 Comment Value: Comment value is measured as redundancy only: a comment that repeats its code's words is found, but a paraphrase in other words, a vague comment, or one the code contradicts is not, and whether a comment is valuable is not claimed. Comments in other scripts or languages, and outside C#, are not judged.
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 (REDACTED, 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.
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: Documentation accuracy checks links, versions and artefact counts against the tree: other claims (paths, commands, settings, routes) are read but not checked, and it cannot run the onboarding or measure how long a real new joiner takes.
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.
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.
89 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was molang.Molang::iterateExp at 125. A further 3 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 SkyCapability.constructor at 20 — they are counted neither in the figure above nor in this dimension's score. 3 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: frontend/src/preview-3d/caps/sky-capability.ts (SkyCapability.constructor at 20), frontend/src/views/context-menu/index.ts (ContextMenu.show at 18), frontend/src/preview-3d/caps/shadow-capability.ts (ShadowCapability.constructor at 17). 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.
+ 81 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Bring the 3 bodies over 30 down to 30 or less in Cyclomatic Complexity — start with molang.Molang::iterateExp (cyclomatic 125), molang.Molang::iterateString (cyclomatic 110), repoaudit.AuditCtx (cyclomatic 36). — 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 3 together lifts Cyclomatic Complexity from 5.8 to about 7.3/10, projected with the scoring formula itself and assuming each lands exactly at 30; a cleaner split scores higher.
Detailed fixes: d1_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
+ 211 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Bring the 1 body over 60 down to 60 or less in Cognitive Complexity — start with molang.Molang::iterateExp (cognitive 82). — Refactoring it lifts Cognitive Complexity from 5.4 to about 5.9/10.
Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D3 · God Classes9.5 / 10Stronggated by 26 serious findings✓ 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.
Resolve the 9 TooManyMethods finding(s) in God Classes — start with app.go, ground-capability.ts, water-capability.ts. — One of this dimension's main actionable groups (9 warning-level).
Resolve the 8 FunctionTooLong finding(s) in God Classes — start with molang.js, dedup.ts, water-menu.ts. — One of this dimension's main actionable groups (8 warning-level).
Resolve the 6 FileTooLong finding(s) in God Classes — start with env-state-schema.ts, wasm-decode.ts, ysm-header.ts. — One of this dimension's main actionable groups (6 warning-level).
Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: How much of the production code is copy-pasted: the share of production lines inside a reported copy (every copy of a duplicated block or of an edited member, each line once), 10 at none and 0 at a quarter of the lines.
Method: Code duplication via token-stream sliding windows with type-aware normalization (locals masked, type names preserved), scored on the share of production lines inside a reported copy (each line once; 10 at none, 0 at a quarter). Deterministic.
33 duplicated block group(s) detected. 1.0 % of the production lines (2,481 of 246,924) are in a reported copy. A further 57 rows report members as variants of one another; the share counts each copied line once, however many rows cite it. 2 of the 90 are in trees this repository does not ship — vendored, example/demo, project-template, fixture and benchmark code — and are ranked below the shipped groups rather than excluded from them: the duplication there is real and is still counted in this dimension's score. The dimensions that publish a production-file census leave those trees out of theirs, so this count is deliberately drawn over the wider population. Measured on part of this repository only: .ts (76% of production source) was not exposed to THIS dimension's token comparison and is not in this count; duplication there is measured by R10 Code Duplication, the frontend lens's card running the same clone algorithm over the JS/TS token stream.
Edited copy of a member (14 corresponding lines) · ×5internal/app/app_files.go:66
Edited copy of a member (21 corresponding lines) · ×4go/installer/installer_file.go:122
Edited copy of a member (9 corresponding lines) · ×4go/geometry/archive_components.go:232
Edited copy of a member (7 corresponding lines) · ×4go/wasispike/main.go:166
+ 43 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 5 Edited copy of a member (14 corresponding lines) finding(s) in Code Duplication — start with app_files.go, scanindex.go, hashindex.go. — One of this dimension's main actionable groups (5 warning-level).
Resolve the 4 Edited copy of a member (21 corresponding lines) finding(s) in Code Duplication — start with installer_file.go, recycle.go, fileops.go. — One of this dimension's main actionable groups (4 warning-level).
Resolve the 4 Edited copy of a member (9 corresponding lines) finding(s) in Code Duplication — start with archive_components.go, extracted.go, config_cmd.go. — One of this dimension's main actionable groups (4 warning-level).
Detailed fixes: d4_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D5 · Coupling10.0 / 10Exemplary✓ 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.
4 production modules (Gradle+npm+Go), 0 dependency cycle(s), 0 unstable depended-on module(s). Read from the build's own module declarations; edges a convention plugin adds from buildSrc or build-logic are not visible there; 0 module(s) off the main sequence, with abstractness counted on 3 of the 4 (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).
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.
What it measures: Whether the code respects its intended layering / architecture rules.
Method: Enforcement rung (Prevented/Verified/Documented) per checkable ADR via Roslyn, plus dependency cycles via the engine shared with D5/AX3. Deterministic, exact.
No mechanizable ADR was identified, so enforcement is not measured. Dependency cycles not checked (no project-reference graph; where this repository's language has an import-cycle lens, cycles are reported there).
Detailed fixes: d7_recommendation.md.
Do you agree with this assessment?
D10 · Test Quality9.9 / 10Adequategated by 4 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.
0 skipped, 40 zero-assertion, 7 synchronised by a fixed sleep, no mocking-framework packages referenced (hand-written doubles or no mocking) across 8549 tests. Measured on the JavaScript/TypeScript suite only — at least 427 test source file(s) (.go) went unread, so its test quality is unmeasured and is not in these counts.
No assertions (empty test): busy 拒收必须可见(批D:原实现静默 return,点另一个按钮零反馈) · ×4frontend/src/views/app-sidebar/app-sidebar.sync.test.ts:643
No assertions: 10. bus tree:set-search 驱动搜索框 · ×36frontend/src/views/app-tree/app-tree.state.test.ts:168
Resolve the 4 No assertions (empty test) finding(s) in Test Quality — start with dedup.test.ts (2), app-sidebar.sync.test.ts, trap-focus-across-shadow.test.ts. — One of this dimension's main actionable groups (4 issue-level).
Resolve the 36 No assertions finding(s) in Test Quality — start with init.test.ts (16), index.test.ts (5), init-github.test.ts (3). — One of this dimension's main actionable groups (36 warning-level).
Resolve the 7 Fixed-sleep synchronisation finding(s) in Test Quality — start with executor.test.ts (4), tag-editor.test.ts (2), bus-handlers.test.ts. — One of this dimension's main actionable groups (7 warning-level).
Detailed fixes: d10_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D11 · Test Reliability4.0 / 10Weak✓ 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.
What it measures: Whether dependencies are current, not deprecated, and not bloated. Known vulnerabilities are D30's.
Method: Manifest scan via dotnet list package across all projects; worst-signal-per-package deduction (capped-linear for deprecation, prerelease and outdated) per KLoC. Known-vulnerable packages are D30's and are not charged here (rubric-2026.11.2). Exhaustive.
5 outdated, 0 author-deprecated direct Go module(s), 0 pinning or checksum defect(s). Whether any of these modules is UNMAINTAINED is not graded — proxy.golang.org 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, not a registry one. Known CVEs in this module graph are D30's question, read from REDACTED and go.sum there.
Outdated: github.com/wailsapp/wails/v3 · ×5
✓ On the Gold path — maintain.
Detailed fixes: d12_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
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.
0 of 28 shipped npm package(s) use a banned license. Licences were resolved from registry.npmjs.org over the 28 package(s) this repository's committed lockfile installs for a consumer — its 8 production, optional and peer dependency(ies), across 2 product package.json manifest(s), and everything those install in turn. Its 20 `devDependencies` declaration(s), and every package only they reach, are excluded: a consumer installs none of them. ★ 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. Third-party code that ships WITHOUT a manifest entry was read too: 2 component(s) whose licence travels in the tree (vendored or copied-in directories, licence comments preserved in committed bundles, compiled wasm modules) and 0 bundled package(s) named only by a bundle's module path, graded on the registry; 0 use a banned licence. 4 vendored, copied-in or compiled component(s) state no licence this pass can read — missing data, not charged. ★ COVERAGE OF THIS VERDICT: it grades this repository's npm package dependencies and nothing else. The repository also declares a Go module (REDACTED/go.sum) and a Cargo manifest, and the licences of those dependency graphs were NOT read by this pass — a gap in this engine's coverage, not a statement about them. So this result says the graded closure carries no banned licence; it does NOT say this repository's licensing is clear.
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.
Top hotspots: scripts/pre-push-gate.ts (106×52=5512); scripts/check-redlines.ts (56×60=3360); scripts/check-go-diff-coverage.ts (30×94=2820) Repeated repair below the complexity floor: internal/app/app_install_recycle.go (12 of 19 changes were fixes); frontend/src/utils/cache/with-cached.ts (12 of 19 changes were fixes); go/sync/conflict.go (11 of 21 changes were fixes)
Resolve the 117 Hotspot finding(s) in Churn × Complexity Hotspots — start with index.ts (2), pre-push-gate.ts, check-redlines.ts. — One of this dimension's main actionable groups (117 warning-level).
Resolve the 25 Repeated repair finding(s) in Churn × Complexity Hotspots — start with app_install_recycle.go, with-cached.ts, conflict.go. — One of this dimension's main actionable groups (25 warning-level).
Detailed fixes: d15_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
7 deducted task-comment markers across 241820 LoC (0.0/KLoC) → score 10.0. 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.
Resolve the 6 TodoComment finding(s) in Explicit Debt — start with test_adr_lingering_progress.ts, test_new_knowledge_card.ts, check-redlines.ts. — One of this dimension's main actionable groups (6 warning-level).
Resolve the 1 XxxComment finding(s) in Explicit Debt — start with comment-checker.ts. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d17_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
What it measures: Whether names — types, methods, variables — are clear and consistent.
Method: Seven vocabulary-free rules (N1-N7) mine each naming convention from the repository and flag a name that breaks a convention its structural peers in the same unit follow; production C# and TypeScript, each its own population. Deterministic, no model, no sample. Advisory.
1 naming inconsistencies among 16 declarations measured against a convention their peers follow.
`matchZipEntryTS` spells `TS` where 15 names in the project spell it `Ts`frontend/src/utils/resource/types.ts:505
What to do
Resolve the 1 `matchZipEntryTS` spells `TS` where 15 names in the project spell it… finding(s) in Naming Consistency — start with types.ts. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d21_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D22 · Internal API Consistency8.6 / 10Strong✓ Tool-verified
What it measures: Whether the internal API surface is consistent and coherent.
Method: Call-shape rules (A1-A9) over the structured code model of the intentionally exposed C# surface: members of one type, overloads of one name and the same slot across sibling types are compared, and a member that makes a caller use a different convention for the same kind of operation is flagged. Deterministic, no model. Advisory.
4 API inconsistencies among 293 exposed members measured against a convention their peers follow.
`AppService.CachedCreatorAvatar` signals absence with `(T, error)` (an error when absent) where its 3 sibling single-key reads use a bare `T` (the zero value when absent)go/cli/appservice.go:76
`importer.DetectContainerTypeFromBase64Tail` signals absence with comma-ok `(T, bool)` where its 3 sibling single-key reads use a nil `*T`go/importer/detect_tail.go:36
`registry.SubDirAll` returns a map (`map[K]V`) where its 9 siblings return a slice (`[]T`)go/types/registry/extensions.go:460
`registry.RegistryType` signals absence with a nil `*T` where its 13 sibling single-key reads use a bare `T` (the zero value when absent)go/types/registry/resource_lookup.go:32
What to do
Resolve the 1 `AppService.CachedCreatorAvatar` signals absence with `(T, error)` (an… finding(s) in Internal API Consistency — start with appservice.go. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 `importer.DetectContainerTypeFromBase64Tail` signals absence with… finding(s) in Internal API Consistency — start with detect_tail.go. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 `registry.SubDirAll` returns a map (`map[K]V`) where its 9 siblings… finding(s) in Internal API Consistency — start with extensions.go. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d22_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether comments are worth it — explaining WHY (valuable) rather than WHAT (redundant).
Method: Every inline C# comment compared word by word with the identifiers, literals and constructs of the code it annotates (taken from the syntax); a comment whose words that code already contains is redundant, as are closing-brace labels and generator template text. Comments giving a reason or a reference are kept; other scripts and languages are not judged. Deterministic, exhaustive, advisory.
doc comments repeat the namesfrontend/src/views/app-preview/model2d/model2d.ts:27
What to do
Resolve the 5 redundant comment finding(s) in Comment Value — start with context-menus-async.test.ts, extract.test.ts, mmd-pmx-parser.worker.test.ts. — One of this dimension's main actionable groups (5 recommendation-level).
Detailed fixes: d24_recommendation.md · top locations in Appendix A, every location in findings.md.
2 of 4 build units (Gradle, npm) flagged as possibly oversized/incoherent.
Projects may be oversized for their cohesion · ×2frontend/package.json:1
What to do
Resolve the 2 Projects may be oversized for their cohesion finding(s) in Project Cohesion — start with package.json (2). — One of this dimension's main actionable groups (2 recommendation-level).
Detailed fixes: d26_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether any secrets were ever committed — scanned across the full git history, not just now.
Method: Secret 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.
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).
82 finding(s): 0 critical, 59 high, 21 medium, 2 low. 45 unpinned-GitHub-Actions row(s) are reported here but scored by D36 (supply-chain provenance), which measures that posture as `pinned_actions` — one pinning decision is charged once, not once per lens. semgrep hit a parse error in 76 file(s) — `.dsh/rules.yaml`, `frontend/e2e/context-menu.spec.ts` (line 16), `frontend/e2e/sidebar-menu.spec.ts` (line 11, line 48, line 70, …), `frontend/e2e/tree-multiselect.spec.ts` (line 9, line 28), `frontend/e2e/tree-search.spec.ts` (line 9, line 38), … (+71 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 3 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
+ 10 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 9 REDACTED finding(s) charged to Static Analysis (SAST) — the other 45 are reported here at file:line but scored by D36 (supply-chain provenance), which charges them once. — One of this dimension's main actionable groups (54 issue-level, 9 of them charged here).
Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
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.
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. Advisory since rubric-2026.11.2 (CAI decision 0006): every row is a match against a vulnerability database that changes daily, so the reading is shown and never moves a scored dimension, lens or the headline.
Resolve the 10 High CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (6), REDACTED (4). — One of this dimension's main actionable groups (10 issue-level).
Resolve the 6 Medium CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (4), REDACTED, REDACTED. — One of this dimension's main actionable groups (6 warning-level).
Resolve the 3 Medium vulnerability finding(s) in Dependency Vulnerabilities — start with REDACTED (2), REDACTED. — One of this dimension's main actionable groups (3 warning-level).
Detailed fixes: d30_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
Every significant source file has living knowledge — recently and meaningfully worked. Counted over 819 of the 1019 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.
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.
Resolve the 13 Boundary-crossing change coupling finding(s) in Change Coupling — start with sync.ts (4), ja.ts (2), zh-CN.ts (2). — One of this dimension's main actionable groups (13 issue-level).
Resolve the 13 Change coupling finding(s) in Change Coupling — start with core.ts (2), light-capability.ts (2), init-workshop.ts. — One of this dimension's main actionable groups (13 warning-level).
Detailed fixes: d35_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d36_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
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. Reported 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. Advisory since rubric-2026.11.2 (CAI decision 0006): the malicious-package feed is a database that changes daily, so the reading is shown and never moves a scored dimension, lens or the headline.
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.
1 end-of-life runtime(s) and 0 end-of-life framework(s), read from 3 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.
Resolve the 1 End-of-life runtime finding(s) in Platform End-of-Life — start with package.json. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d44_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
Frontend & cross-cutting dimensions
R = React/JS · M = Maturity · P = Readiness.
AC1 · Text alternatives4.5 / 10Weak✓ 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.
A <canvas> with no aria-label/title and no inner fallback content can't be described by assistive tech. Add a name or fallback content. (×3) — frontend/src/preview-3d/menu/render/cap-controls.ts:456, frontend/src/preview-3d/menu/render/cap-controls.ts:549, REDACTED:28
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.
Do you agree with this assessment?
AC2 · Forms & labels5.3 / 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 control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it. (×9) — frontend/src/features/community/render.ts:151, frontend/src/preview-3d/adapters/vrm/vrm-bone-ui.ts:101, frontend/src/preview-3d/menu/render/cap-controls.ts:328, …
This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label. (×5) — frontend/src/utils/dom/modal-prompt.ts:37, frontend/src/views/app-content/site/render.ts:335, frontend/src/views/app-content/site/render.ts:405, …
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). — frontend/src/views/app-content/settings/keymap.ts:123
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.
Do you agree with this assessment?
AC3 · Page structure4.8 / 10Weak✓ 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.
No <main> (or role="main") means no "skip to content" target and a weaker landmark map. This document's body is only the mount point <div id="host">, so there is no content here to wrap — render the <main> from the component mounted into it. — frontend/harness/index.html:5
No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>. — frontend/index.html:2
An iframe with no title (or an empty one) is announced only as "frame". Add a non-empty title describing its content, or an aria-label. — frontend/src/views/app-content/tpl.ts:292
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.
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. (×4) — frontend/src/preview-3d/adapters/vrm/vrm-bone-ui.ts:90, frontend/src/preview-3d/menu/engine/core.ts:155, frontend/src/preview-3d/menu/panels/roles-views.ts:259, …
This <div role="dialog"> is a modal dialog, but focus is moved into it, but nothing keeps it there: Tab walks out to the page behind, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native <dialog> opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close. — frontend/src/preview-3d/infra/preview-shell.ts:72
This <div role="dialog"> is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native <dialog> opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close. — frontend/src/utils/dom/modal-core.ts:164
What to do
Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href.
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.
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.
<div> moves — its inline style sets `animation: preview` — and nothing reads prefers-reduced-motion for it, so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Gate it on @media (prefers-reduced-motion: no-preference) or motion-safe:. — frontend/src/preview-3d/infra/preview-loading.ts:29
`.dlg-box` moves (`animation: dlgBoxIn .2s cubic-bezier(.34,1.56,.64,1)`) 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. — frontend/css/components.css:57
`.dlg-overlay.dlg-closing .dlg-box` moves (`animation: dlgBoxOut .12s ease forwards`) 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. — frontend/css/components.css:59
`.br-row` moves (`animation: fadeSlideUp .15s ease both`) 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. — frontend/css/components.css:464
`.dlg-prog-fill` moves (`transition: width 0.06s linear`) 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. — frontend/css/dialogs.css:62
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.
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.
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.
Other · Architecture — Whether the codebase has a recognisable, scale-appropriate structure (a named architectural style, or modular enough for its size) rather than being an ad-hoc ball of mud.
Method: Roslyn plus csproj analysis: architecture style detection (DDD, clean, vertical-slice, CQRS) and structure fitness for repo size. Deterministic.
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.
`AppService` declares 49 methods: `ScanModelEntries`, `ScanModelEntriesForBrowse`, `SearchModels`, `ListModelAuthors`, `ScanLocalAuthors`, `AnalyzeYSMModel`, `AnalyzeBedrockModel`, `ExportModelStructureJSON`, `ReadFileBytes`, `ReadFileBytesBatch`, `LoadAppConfig`, `GetConfigPath`, `GetMinecraftPaths`, `SetDownloadMirror`, `SetSessionFilesRoot`, `RenameDir`, `RenameFile`, `MoveModelFile`, `CopyModelFile`, `ToggleModelEnable`, `InstallModelFile`, `InstallModelTo`, `SetLinkMode`, `GetLinkMode`, `ListVersionInstances`, `SyncResources`, `PushResourceToInstance`, `PullResourceFromInstance`, `ListRecycleBin`, `RestoreFromRecycle`, `EmptyRecycleBin`, `EnqueueDownloads`, `CancelQueue`, `QueueStatus`, `DownloadFromGitHub`, `AllTags`, `GetModelTags`, `SetModelTags`, `ListByTag`, `CachedCreatorAvatar`, and 9 more. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. 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. — go/cli/appservice.go:16
What to do
Split fat interfaces into focused role-interfaces so clients depend only on what they use.
Other · Architecture — Whether feature slices stay independent (no direct cross-slice references) — the discipline that makes vertical-slice architecture pay off.
Method: Roslyn scan (vertical-slice gated): feature slices resolved from namespaces (.Features.*, .Slices.*) or project names; cross-slice type references detected. Deterministic, traceable.
`cmDqEnqueue` (slice 'community') depends on `currentRepoType` from slice 'repo'. — frontend/src/features/community/download-queue.ts:323
`FileDialogDeps` (slice 'context-menu') depends on `RenameTpl` from slice 'dialogs'. — frontend/src/features/context-menu/context-menu-file-handlers.ts:21
`FileDialogDeps` (slice 'context-menu') depends on `TagEditorTpl` from slice 'dialogs'. — frontend/src/features/context-menu/context-menu-file-handlers.ts:22
`FILE_HANDLERS` (slice 'context-menu') depends on `showRenameDialog` from slice 'dialogs'. — frontend/src/features/context-menu/context-menu-file-handlers.ts:56
`FILE_HANDLERS` (slice 'context-menu') depends on `modalTagEditor` from slice 'dialogs'. — frontend/src/features/context-menu/context-menu-file-handlers.ts:124
`importViaWebPlatform` (slice 'dnd') depends on `importWebFilesWithToast` from slice 'import'. — frontend/src/features/dnd/import-dnd.ts:99
`buildResultParts` (slice 'dnd') depends on `ImportBatchResult` from slice 'import'. — frontend/src/features/dnd/import-dnd.ts:105
`handleTreeDrop` (slice 'dnd') depends on `CollectedEntry` from slice 'import'. — frontend/src/features/dnd/import-dnd.ts:171
`handleTreeDrop` (slice 'dnd') depends on `collectDropFiles` from slice 'import'. — frontend/src/features/dnd/import-dnd.ts:171
`handleTreeDrop` (slice 'dnd') depends on `dropOversized` from slice 'import'. — frontend/src/features/dnd/import-dnd.ts:179
`handleTreeDrop` (slice 'dnd') depends on `executeCollected` from slice 'import'. — frontend/src/features/dnd/import-dnd.ts:187
`Grouped` (slice 'dnd') depends on `groupCollected` from slice 'import'. — frontend/src/features/dnd/pack-dnd.ts:33
`pushFolderGroups` (slice 'dnd') depends on `buildFolderItems` from slice 'import'. — frontend/src/features/dnd/pack-dnd.ts:76
`pushSingleFiles` (slice 'dnd') depends on `fileToBase64` from slice 'import'. — frontend/src/features/dnd/pack-dnd.ts:106
`handleInstanceDrop` (slice 'dnd') depends on `CollectedEntry` from slice 'import'. — frontend/src/features/dnd/pack-dnd.ts:188
`handleInstanceDrop` (slice 'dnd') depends on `collectDropFiles` from slice 'import'. — frontend/src/features/dnd/pack-dnd.ts:188
`handleInstanceDrop` (slice 'dnd') depends on `dropOversized` from slice 'import'. — frontend/src/features/dnd/pack-dnd.ts:197
`importWebBatch` (slice 'import') depends on `currentRepoType` from slice 'repo'. — frontend/src/features/import/executor.ts:265
`loadOldestModel` (slice 'maintenance') depends on `useCurrentResourceType` from slice 'repo'. — frontend/src/features/maintenance/oldest-models.ts:219
`initRecycleBin` (slice 'maintenance') depends on `useCurrentResourceType` from slice 'repo'. — frontend/src/features/maintenance/recycle-bin.ts:342
What to do
Keep slices independent: share cross-slice needs via an explicit contract/shared-kernel, not direct references between slices.
Do you agree with this assessment?
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.
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.
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.
`main` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/scripts/check-binding-usage.ts:83
`Emit` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/src/backend/runtime.ts:30
`SaveScreenshotFile` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/src/backend/web-fs.ts:421
`Stage2LoadingManager` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/src/preview-3d/adapters/mmd/mmd-build-load.ts:398
`Stage3Ktx2Schedule` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/src/preview-3d/adapters/mmd/mmd-build-scene.ts:234
`disposeMmdMesh` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/src/preview-3d/adapters/mmd/mmd-shared.ts:24
The guard above `return bytes;` also returns `bytes`, so no input can make it matter. Implement the distinction that was intended, or delete the guard. — frontend/src/preview-3d/decoder/utils.ts:122
`populatePerfTargetOptions` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/src/views/app-content/diagnostics/perf-matrix-render.ts:347
`showSimplePreview` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/src/views/app-preview/detail.ts:294
`openFullPreview` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — frontend/src/views/app-preview/zoom.ts:24
`appendDebug` has an empty body — confirm it's an intentional no-op and not an unfinished method. — frontend/src/preview-3d/adapters/ysm-preview-pipeline.ts:49
`emscripten_notify_memory_growth` has an empty body — confirm it's an intentional no-op and not an unfinished method. — go/wasispike/probe.mjs:69
What to do
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.
Maturity · Maturity — Whether the repository and its projects have a README, and whether it is substantive.
Method: Filesystem scan: README presence, word count, and headings for depth; git history for staleness. Exhaustive across root and project dirs, deterministic.
Maturity · Maturity — Whether the repository is organised deliberately: production code and tests are set apart in a way its ecosystem or the repository itself declares.
Method: Filesystem scan: src/test folder separation and namespace-prefix consistency (majority RootNamespace agreement). Exhaustive across projects, deterministic.
Maturity · Maturity — Whether the project's current-state documentation describes the code that exists.
Method: Every current-state document's checkable claims looked up in the tree (links, versions, and artefact counts an order of magnitude off), plus two README checks: an advertised infrastructure product with no footprint, and a module the CHANGELOG records as removed. Deterministic, no model. Advisory.
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.
`REDACTED` schedules updates, but no `package-ecosystem` entry covers `cargo`, `gradle`, which this tree depends on — so those dependencies get no update pull requests and no advisory pressure, however complete the dep-scan credit looks. Add the missing entries to the `updates:` list. — REDACTED:5
What to do
Dependabot is configured but does not watch `cargo`, `gradle` — add those `package-ecosystem` entries to REDACTED 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.
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 we 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.
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.
Readiness · Performance — Whether the code protects its performance with benchmarks — a benchmark suite, allocation/memory measurement, and (ideally) a CI gate. Presence is credited as a bonus, never a deduction.
Method: Repo + source scan: BenchmarkDotNet referenced (csproj/source), [Benchmark]/[MemoryDiagnoser] attribute counts, and a benchmark step in CI; off .NET, the same ladder over Go testing.B, Rust criterion/#[bench]/divan, JMH/kotlinx-benchmark, pytest-benchmark/asv/pyperf, tinybench/mitata/vitest bench/benchmark.js and Swift package-benchmark — scored as a bonus ladder (absence is neutral, never a deduction). Deterministic, presence detection.
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 each language's code 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.
`readFileSync` in `serve` 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) — artifacts/audit-env-s13/probe.mjs:48, artifacts/audit-env-s13/probe2.mjs:58
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.
Do you agree with this assessment?
R1 · Type Safety9.9 / 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.
React / JS · Code Health — The share of the scored frontend lines inside a near-exact copy-pasted block of substantial extent (the D4 clone algorithm over JS/TS tokens, D-386; each line once, 10 at none and 0 at a quarter of the lines, as D4): 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. Scored on the share of the scored frontend lines inside a reported copy, on the same curve as D4. Deterministic.
16 duplicated blocks under frontend/src/ have copies in at least two of the sibling directories backend, features, parsers, preview-3d, utils, views — 9 of them are reported below, and 7 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. — frontend/src/features/import/collector.ts:17
12 duplicated blocks under frontend/src/preview-3d/ have copies in at least two of the sibling directories adapters, bone, caps, infra, menu, mesh (+2 more sibling(s) not listed) — 6 of them are reported below, and 6 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 12 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 12 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 12 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. — frontend/src/preview-3d/bone/bone-raycast.ts:155
6 duplicated blocks under frontend/src/views/ have copies in at least two of the sibling directories app-content, app-nav, app-preview, app-sidebar, app-sync-manager, app-toast (+1 more sibling(s) not listed) — 5 of them are reported below, and 1 is 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. — frontend/src/views/app-sync-manager/renderer.ts:326
5 duplicated blocks under the repository root have copies in at least two of the sibling directories frontend, scripts — 4 of them are reported below, and 1 is 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. — frontend/src/preview-3d/mesh/quaternion.ts:41
scripts/check-complexity.ts:90 · scripts/check-params.ts:72 — the two spans are one implementation copied and then locally edited — 1291 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/check-complexity.ts:90
scripts/check-singleton-hygiene.ts:168 · scripts/check-worker-lifecycle.ts:130 — the two spans are one implementation copied and then locally edited — 939 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/check-singleton-hygiene.ts:168
frontend/src/preview-3d/caps/ground-capability.ts:571 · frontend/src/preview-3d/caps/water-capability.ts:308 — the two spans are one implementation copied and then locally edited — 583 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. — frontend/src/preview-3d/caps/ground-capability.ts:571
scripts/i18n-frozen-t-check.ts:59 · scripts/i18n-ui-check.ts:85 — the two spans are one implementation copied and then locally edited — 720 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/i18n-frozen-t-check.ts:59
scripts/check-menu-test-layout.ts:245 · scripts/check-singleton-hygiene.ts:180 — 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. — scripts/check-menu-test-layout.ts:245
scripts/check-singleton-hygiene.ts:195 · scripts/check-vitest-assert-quality.ts:312 — 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. — scripts/check-singleton-hygiene.ts:195
scripts/check-vitest-assert-quality.ts:377 · scripts/check-worker-lifecycle.ts:256 — the two spans are one implementation copied and then locally edited — 430 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/check-vitest-assert-quality.ts:377
scripts/_lib/css-layer-utils.ts:143 · scripts/css-token-check.ts:57 — 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. — scripts/_lib/css-layer-utils.ts:143
scripts/_attic/check-naming-blacktalk.ts:54 · scripts/check-boolean-naming.ts:151 — the two spans are one implementation copied and then locally edited — 329 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/_attic/check-naming-blacktalk.ts:54
scripts/check-dynamic-import.ts:79 · scripts/check-tpl-refs.ts:93 — the two spans are one implementation copied and then locally edited — 338 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/check-dynamic-import.ts:79
scripts/gen-routes-quick.ts:291 · scripts/gen-routes.ts:194 — the two spans are one implementation copied and then locally edited — 400 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/gen-routes-quick.ts:291
scripts/check-cap-enabled-duality.ts:31 · scripts/check-env-schema-consumers.ts:34 — the two spans are one implementation copied and then locally edited — 354 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/check-cap-enabled-duality.ts:31
frontend/src/wasm/ysm-parser.ts:113 · frontend/src/wasm/ysm-worker-loader.ts:201 — the two spans are one implementation copied and then locally edited — 289 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. — frontend/src/wasm/ysm-parser.ts:113
scripts/check-diff-coverage.ts:186 · scripts/check-go-diff-coverage.ts:627 — the two spans are one implementation copied and then locally edited — 293 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/check-diff-coverage.ts:186
frontend/src/views/app-sidebar/sidebar-pull.ts:74 · frontend/src/views/app-sidebar/sidebar-push.ts:178 — the two spans are one implementation copied and then locally edited — 221 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. — frontend/src/views/app-sidebar/sidebar-pull.ts:74
scripts/check-orphan-exports.ts:423 · scripts/check-unread-fields.ts:364 — the two spans are one implementation copied and then locally edited — 156 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/check-orphan-exports.ts:423
scripts/check-singleton-hygiene.ts:52 · scripts/check-worker-lifecycle.ts:59 — the two spans are one implementation copied and then locally edited — 297 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/check-singleton-hygiene.ts:52
scripts/gen-knowledge-adr.ts:113 · scripts/gen-knowledge-tests.ts:129 — the two spans are one implementation copied and then locally edited — 296 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/gen-knowledge-adr.ts:113
frontend/src/preview-3d/caps/fog-capability.ts:222 · frontend/src/preview-3d/caps/shadow-capability.ts:488 — 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. — frontend/src/preview-3d/caps/fog-capability.ts:222
frontend/src/preview-3d/mesh/quaternion.ts:41 · scripts/port-align.ts:239 — 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. — frontend/src/preview-3d/mesh/quaternion.ts:41
artifacts/ground-design-probe/mock-3d.mjs:13 · artifacts/ground-design-probe/render-tiles.mjs:32 — 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. — artifacts/ground-design-probe/mock-3d.mjs:13
scripts/check-design-tokens.ts:437 · scripts/check-design-tokens.ts:740 — all 2 copies are in the same file, 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. — scripts/check-design-tokens.ts:437
scripts/check-design-tokens.ts:632 · scripts/check-i18n-unused.ts:180 — 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. — scripts/check-design-tokens.ts:632
frontend/src/preview-3d/materials/alpha-index.ts:28 · scripts/_attic/translucency-probe.ts:144 — the two spans are one implementation copied and then locally edited — 288 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. — frontend/src/preview-3d/materials/alpha-index.ts:28
scripts/_attic/perf-gate.ts:58 · scripts/gui-flow-gate.ts:41 — the two spans are one implementation copied and then locally edited — 163 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/_attic/perf-gate.ts:58
frontend/src/views/app-tree/bus-handlers.ts:362 · frontend/src/views/app-tree/events.ts:474 — the two spans are one implementation copied and then locally edited — 199 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. — frontend/src/views/app-tree/bus-handlers.ts:362
frontend/src/views/app-tree/row-tpl-list.ts:28 · frontend/src/views/app-tree/row-tpl.ts:46 — 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. — frontend/src/views/app-tree/row-tpl-list.ts:28
scripts/check-menu-test-layout.ts:345 · scripts/check-singleton-hygiene.ts:277 · scripts/check-worker-lifecycle.ts:287 — the 3 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. There is one copy in each of 3 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. — scripts/check-menu-test-layout.ts:345
frontend/src/preview-3d/menu/render/cap-controls.ts:358 · frontend/src/preview-3d/menu/render/cap-controls.ts:403 — the two spans are one implementation copied and then locally edited — 177 tokens are still identical, in the same order in both spans, 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. — frontend/src/preview-3d/menu/render/cap-controls.ts:358
scripts/check-menu-health.ts:133 · scripts/check-menu-health.ts:234 — all 2 copies are in the same file, 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. — scripts/check-menu-health.ts:133
scripts/line-counter.ts:136 · scripts/line-counter.ts:220 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. — scripts/line-counter.ts:136
artifacts/audit-env-s13/probe.mjs:36 · artifacts/audit-env-s13/probe2.mjs:48 — 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. — artifacts/audit-env-s13/probe.mjs:36
frontend/src/wasm/ysm-parser.ts:193 · frontend/src/wasm/ysm-worker-loader.ts:263 — 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. — frontend/src/wasm/ysm-parser.ts:193
scripts/build-novel-index.ts:169 · scripts/build-novel-index.ts:194 — all 2 copies are in the same file, 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. — scripts/build-novel-index.ts:169
scripts/line-counter.ts:162 · scripts/line-counter.ts:246 — all 2 copies are in the same file, 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. — scripts/line-counter.ts:162
scripts/check-design-tokens.ts:603 · scripts/check-i18n-unused.ts:157 — 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. — scripts/check-design-tokens.ts:603
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.
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.
artifacts/ground-design-probe/render-tiles.mjs:19 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/plain.ts) — import the package by name instead. — artifacts/ground-design-probe/render-tiles.mjs:19
artifacts/ground-design-probe/render-tiles.mjs:20 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/marble.ts) — import the package by name instead. — artifacts/ground-design-probe/render-tiles.mjs:20
artifacts/ground-design-probe/render-tiles.mjs:21 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/sand.ts) — import the package by name instead. — artifacts/ground-design-probe/render-tiles.mjs:21
artifacts/ground-design-probe/render-tiles.mjs:22 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/grass.ts) — import the package by name instead. — artifacts/ground-design-probe/render-tiles.mjs:22
artifacts/ground-design-probe/render-tiles.mjs:23 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/noise.ts) — import the package by name instead. — artifacts/ground-design-probe/render-tiles.mjs:23
frontend/harness/mock-install.ts:5 imports frontend/e2e/mock-data.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. — frontend/harness/mock-install.ts:5
frontend/harness/shot.mjs:22 imports frontend/e2e-web/png-color-count.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. — frontend/harness/shot.mjs:22
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 (5 rows); move the shared test helper into a source directory production code may depend on (2 rows).
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.
iterateExp has cyclomatic complexity 125 and cognitive complexity 82; 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. — frontend/src/utils/animation/molang-lib/molang.js:400
validate has cyclomatic complexity 120 and cognitive complexity 221; 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. — tests/test_resource_schema.ts:43
iterateString has cyclomatic complexity 110 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 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. — frontend/src/utils/animation/molang-lib/molang.js:109
main has cyclomatic complexity 93 and cognitive complexity 157; 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. — scripts/check-go-diff-coverage.ts:623
main has cyclomatic complexity 81 and cognitive complexity 156; 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. — scripts/check-layering.ts:384
findFunctionEnd has cyclomatic complexity 74 and cognitive complexity 198; 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. — scripts/line-counter.ts:122
main has cyclomatic complexity 64 and cognitive complexity 122; 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:58
main has cyclomatic complexity 51 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. — scripts/pre-push-gate.ts:123
tokenize has cyclomatic complexity 50 and cognitive complexity 138; 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. — scripts/auto-import-lexer.ts:288
buildModelTexMap has cyclomatic complexity 47 and cognitive complexity 86; 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. — tests/port-verification/scan-cube-texslot.ts:49
parseYsmAuthority has cyclomatic complexity 47 and cognitive complexity 86; 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. (×3) — tests/port-verification/scan-non-main-uv.ts:57, tests/port-verification/scan-texslot-binding.ts:39, tests/port-verification/scan-texslot-overflow.ts:52
main has cyclomatic complexity 46 and cognitive complexity 121; 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. — scripts/gen-knowledge-autogen.ts:371
human has cyclomatic complexity 44 and cognitive complexity 83; 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. — scripts/audit-split.ts:222
extractImports has cyclomatic complexity 44 and cognitive complexity 76; 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. — scripts/check-orphan-exports.ts:103
findSites has cyclomatic complexity 44 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. — scripts/codemod-bare-assert-noerror.ts:172
htmlLiteralHits has cyclomatic complexity 43 and cognitive complexity 87; 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. — scripts/check-layering.ts:229
runFrontendDomain has cyclomatic complexity 43 and cognitive complexity 51; 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. — scripts/_lib/gate-blocks/frontend-domain.ts:16
main has cyclomatic complexity 42 and cognitive complexity 73; 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. — scripts/check-orphan-exports.ts:327
renderMarkdown has cyclomatic complexity 42 and cognitive complexity 72; 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:522
deriveAuthoritative has cyclomatic complexity 42 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. — tests/port-verification/scan-texture-gap.ts:43
findStrayCommentClose has cyclomatic complexity 41 and cognitive complexity 78; 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. — scripts/_lib/css-layer-utils.ts:143
main has cyclomatic complexity 41 and cognitive complexity 75; 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. — scripts/jscpd-go.ts:113
checkFile has cyclomatic complexity 41 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. — scripts/auto-import-detect.ts:43
main has cyclomatic complexity 41 and cognitive complexity 47; 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. — scripts/new-adr.ts:308
main has cyclomatic complexity 40 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. — scripts/check-diff-coverage.ts:182
simulateArchiveGo has cyclomatic complexity 39 and cognitive complexity 62; 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. — tests/port-verification/scan-texture-gap.ts:119
runGoDomain has cyclomatic complexity 38 and cognitive complexity 56; 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. — scripts/_lib/gate-blocks/go-domain.ts:36
codeAsserts has cyclomatic complexity 38 and cognitive complexity 38; 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. — scripts/check-adr-drift.ts:86
fnHeaderName 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. — REDACTED:295
human has cyclomatic complexity 36 and cognitive complexity 82; 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. — scripts/api-break.ts:210
checkKnowledgeMeta has cyclomatic complexity 36 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. — scripts/check-knowledge-drift.ts:153
stripA11yNoise has cyclomatic complexity 35 and cognitive complexity 67; 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. — scripts/check-a11y.ts:93
decodePng has cyclomatic complexity 35 and cognitive complexity 55; 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. — scripts/_attic/translucency-probe.ts:31
main has cyclomatic complexity 35 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. — scripts/check-complexity.ts:285
analyze has cyclomatic complexity 34 and cognitive complexity 44; 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. — scripts/_attic/trace-analyze.ts:90
extractFunctions has cyclomatic complexity 33 and cognitive complexity 81; 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. — scripts/line-counter.ts:312
scanTextFull has cyclomatic complexity 33 and cognitive complexity 54; 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. — scripts/check-vitest-assert-quality.ts:209
scanModel has cyclomatic complexity 33 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. — tests/port-verification/scan-non-main-uv.ts:197
Do you agree with this assessment?
R3 · Large Files5.9 / 10Adequate✓ 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.
scripts/check-knowledge-drift.ts has 1211 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/check-knowledge-drift.ts:1
scripts/check-redlines.ts has 1116 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/check-redlines.ts:1
frontend/src/preview-3d/state/env-state-schema.ts has 1030 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/state/env-state-schema.ts:1
frontend/src/settings-keys.ts has 1012 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/settings-keys.ts:1
scripts/check-go-diff-coverage.ts has 981 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/check-go-diff-coverage.ts:1
frontend/src/views/app-tree/index.ts has 908 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/views/app-tree/index.ts:1
scripts/port-align.ts has 907 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/port-align.ts:1
frontend/src/preview-3d/decoder/wasm-decode.ts has 904 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/decoder/wasm-decode.ts:1
REDACTED has 864 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
frontend/src/preview-3d/caps/sky-capability.ts has 860 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/caps/sky-capability.ts:1
frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts has 834 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts:1
frontend/src/preview-3d/adapters/ysm-adapter.ts has 826 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/adapters/ysm-adapter.ts:1
frontend/src/parsers/ysm-header.ts has 807 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/parsers/ysm-header.ts:1
frontend/src/views/app-tree/render.ts has 805 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/views/app-tree/render.ts:1
scripts/check-design-tokens.ts has 796 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/check-design-tokens.ts:1
frontend/src/preview-3d/menu/engine/core.ts has 789 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/menu/engine/core.ts:1
frontend/src/preview-3d/caps/ground-capability.ts has 785 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/caps/ground-capability.ts:1
frontend/src/preview-3d/adapters/mount-preview-core.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. — frontend/src/preview-3d/adapters/mount-preview-core.ts:1
frontend/src/preview-3d/adapters/vrm/vrm-adapter.ts has 731 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/adapters/vrm/vrm-adapter.ts:1
scripts/token-shift-audit.ts has 702 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/token-shift-audit.ts:1
scripts/css-layer-check.ts has 693 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/css-layer-check.ts:1
scripts/line-counter.ts has 693 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/line-counter.ts:1
scripts/check-layering.ts has 677 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/check-layering.ts:1
frontend/src/preview-3d/menu/render/cap-controls.ts has 675 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/menu/render/cap-controls.ts:1
scripts/probe-water-wave.ts has 648 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/probe-water-wave.ts:1
frontend/src/preview-3d/caps/ground-surface-spec.ts has 624 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/caps/ground-surface-spec.ts:1
frontend/src/preview-3d/caps/light-capability.ts has 608 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/caps/light-capability.ts:1
frontend/src/preview-3d/caps/water-capability.ts has 591 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/caps/water-capability.ts:1
frontend/src/utils/animation/molang-lib/molang.js has 588 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/utils/animation/molang-lib/molang.js:1
scripts/gen-knowledge-autogen.ts has 575 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/gen-knowledge-autogen.ts:1
frontend/src/views/app-tree/events.ts has 573 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/views/app-tree/events.ts:1
frontend/src/preview-3d/adapters/litematic-adapter.ts has 566 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/adapters/litematic-adapter.ts:1
frontend/src/backend/web-community.ts has 562 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/backend/web-community.ts:1
scripts/check-menu-health.ts has 556 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/check-menu-health.ts:1
scripts/codemod.ts has 543 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/codemod.ts:1
frontend/src/preview-3d/caps/shadow-capability.ts has 539 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/caps/shadow-capability.ts:1
frontend/src/preview-3d/menu/render/render.ts has 538 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/menu/render/render.ts:1
frontend/src/preview-3d/caps/environment-capability.ts has 537 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/caps/environment-capability.ts:1
frontend/src/preview-3d/caps/postprocessing-composer.ts has 531 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — frontend/src/preview-3d/caps/postprocessing-composer.ts:1
REDACTED has 527 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
What to do
Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.
Do you agree with this assessment?
R4 · Test Coverage9.7 / 10Exemplary✓ 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.
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. (×14) — frontend/harness/main.ts:1, frontend/harness/shot.mjs:1, artifacts/ground-design-probe/render-tiles.mjs:1, …
What to do
Add tests that import the unreached modules (directly or through their public entry).
React / JS · Readiness — How outdated the npm dependencies are (a maturity signal). JS/npm CVEs are scored separately in D30 (JS/npm Dependency Vulnerabilities).
Method: npm dependency staleness from manifest/registry metadata (a maturity signal; JS/npm CVEs are scored separately in D30, which answers dependency vulnerabilities for every ecosystem). Deterministic.
Do you agree with this assessment?
R6 · Tooling10.0 / 10Exemplary✓ Tool-verified
React / JS · Readiness — Whether the project wires up test, lint and typecheck — detected from each package.json 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: package.json scanned for test/lint/typecheck script wiring. Deterministic presence check.
The root package declares the lint script `lint:scripts` (`biome check scripts/`), but no step of this repository's CI runs it, by name, through another script, a Makefile target or a workspace runner, and no CI step runs the linter over the package itself. The rules it sets are enforced nowhere a pull request can fail. Run it in CI: a step that runs `npm run lint:scripts` in `.` (or the workspace's task runner). — package.json:19
Do you agree with this assessment?
R7 · Dead Code9.2 / 10Exemplary✓ 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.
Unreachable from the 801 application, 351 tooling and 849 test entry point(s) detected in this repo. Gate removals on `npm run typecheck:scripts` — an undetected custom entry would make these reachable.
no import path from any entry point (801 application, 351 tooling, 849 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 (×5) — frontend/harness/main.ts, scripts/_attic/ai-mistake-tracker.ts, artifacts/cleanup-creators-mojibake.cjs, …
no import path from any entry point (801 application, 351 tooling, 849 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (frontend/harness/main.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 — frontend/harness/mock-install.ts
Nothing imports this binding — it is safe to review for removal. (×5) — frontend/src/features/import/executor.ts:34, frontend/src/preview-3d/decoder/wasm-geometry.ts:65, frontend/src/preview-3d/infra/semantic-morphs.ts:24, …
This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it. (×10) — artifacts/ground-design-probe/render-tiles.mjs:123, go/wasispike/probe.mjs:41, scripts/_attic/perf-gate.ts:38, …
What to do
Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value.
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 package.json — installs work only by hoisting accident. — artifacts/audit-env-s13/probe.mjs:44
What to do
Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.
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.
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.
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.
Do you agree with this assessment?
X13 · Undrained process stream10.0 / 10Exemplary○ Nothing flagged
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.
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.
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.
Other · Code Health — Whether functions that make a cancellable request accept or pass on a context.Context or 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 5/9 functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http; net/http, net.Dial) accept a context.Context or an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, a cancelled request, a shutdown, an expired deadline. Take a `signal` (Go: `ctx context.Context`) 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.
`fetchReleaseList` calls `http.NewRequest(…)` but takes no context.Context and reaches none its caller controls, so its caller cannot cancel the request once it has started. Take `ctx context.Context` as the first parameter and build the request with it: `http.NewRequestWithContext(ctx, …)`, `(&net.Dialer{}).DialContext(ctx, …)`. — go/updater/updater.go:182
`fetchExpectedHash` calls `http.NewRequest(…)` but takes no context.Context and reaches none its caller controls, so its caller cannot cancel the request once it has started. Take `ctx context.Context` as the first parameter and build the request with it: `http.NewRequestWithContext(ctx, …)`, `(&net.Dialer{}).DialContext(ctx, …)`. — go/updater/updater_semver.go:79
`loadBundle` 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 })`. — frontend/src/utils/dom/locale-host.ts:12
`loadBasisModule` 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 })`. — REDACTED:50
What to do
Thread a context.Context or an AbortSignal through functions that make requests, so the work stops when its caller gives up.
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.
Do you agree with this assessment?
X24 · Document value interpolated into markup unescaped4.9 / 10Weak✓ 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.
`UI_ICONS.refresh` 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) — frontend/src/features/community/data.ts:29, frontend/src/features/community/download-queue-progress.ts:145, frontend/src/features/community/download-queue.ts:147, …
``${UI_ICONS.refresh}${".".repeat(ctx._dots)}`` 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. — frontend/src/features/community/download-queue-progress.ts:155
``${UI_ICONS.error} ${t("downloadQueue.failedCount",{n:s.errorList.length})}`` 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. — frontend/src/features/community/download-queue-progress.ts:276
`UI_ICONS.error` 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. — frontend/src/features/community/download-queue-progress.ts:298
`UI_ICONS.download` 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. (×3) — frontend/src/features/community/download-queue.ts:95, frontend/src/features/community/download-queue.ts:141, frontend/src/features/community/repo-events-bindings.ts:178
`UI_ICONS.close` 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. — frontend/src/features/community/download-queue.ts:158
``${UI_ICONS.error} ${t("downloadQueue.failedListTitle",{n:s.errorList.length})}`` 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. — frontend/src/features/community/download-queue.ts:212
``${UI_ICONS.error} ${renderDisplayName(e.name)}: ${ctx.esc(e.err)}`` 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. — frontend/src/features/community/download-queue.ts:219
``${UI_ICONS.close} ${t("downloadQueue.cancelled")}`` 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. — frontend/src/features/community/download-queue.ts:233
`iconHTML` 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. — frontend/src/features/community/render.ts:103
``${UI_ICONS.success} ${t("workshop.exists")}`` 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. — frontend/src/features/community/render.ts:183
``${UI_ICONS.folder} ${esc(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. — frontend/src/features/community/repo-events-bindings.ts:42
``${UI_ICONS.download} ${t("workshop.downloadSelected",{n:checked})}`` 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. — frontend/src/features/community/repo-events-shared.ts:130
`opts.tpl.formHTML(v)` 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. — frontend/src/features/dialogs/adv-filter.ts:187
`tpl.previewHTML(rows)` 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. — frontend/src/features/dialogs/batch-rename-form.ts:84
``${UI_ICONS.clipboard} ${show?t("dialog.collapse"):t("dialog.presets")}`` 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. — frontend/src/features/dialogs/batch-rename-form.ts:177
``${UI_ICONS.refresh} ${t("dialog.executing")}`` 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. — frontend/src/features/dialogs/batch-rename-form.ts:276
``${UI_ICONS.edit} ${t("dialog.doRename")}`` 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. — frontend/src/features/dialogs/batch-rename-form.ts:289
`tpl.formHTML(dir,items.length,changed)` 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. — frontend/src/features/dialogs/batch-rename.ts:133
``${UI_ICONS.book} ${t("dialog.readHeader")}`` 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) — frontend/src/features/dialogs/rename.ts:38, frontend/src/features/dialogs/rename.ts:86
``${UI_ICONS.warning} ${t("dialog.notImported")}`` 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. — frontend/src/features/dialogs/rename.ts:52
``${UI_ICONS.refresh} ${t("dialog.reading")}`` 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. — frontend/src/features/dialogs/rename.ts:58
``${UI_ICONS.note} ${esc(header.tips)}`` 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. — frontend/src/features/dialogs/rename.ts:70
``${UI_ICONS.warning} ${t("dialog.readFailed")}`` 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. — frontend/src/features/dialogs/rename.ts:80
`opts.tpl.boxHTML(parsed,currentName)` 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. — frontend/src/features/dialogs/rename.ts:189
`shell.tpl.tagsHTML(shell.tags)` 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. — frontend/src/features/dialogs/tag-editor.ts:45
`shell.tpl.suggestionsHTML(allTags,shell.tags)` 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. — frontend/src/features/dialogs/tag-editor.ts:56
`tpl.boxHTML(modelPath)` 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. — frontend/src/features/dialogs/tag-editor.ts:103
`renderPage(entries,stats,statsError)` 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. — frontend/src/features/maintenance/oldest-models.ts:199
`deps.renderListHtml(entries)` 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. — frontend/src/features/maintenance/recycle-bin.ts:290
``${UI_ICONS.refresh} ${t("update.status.checking")}`` 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. — frontend/src/features/maintenance/version-updater.ts:224
`idleHTML` 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. — frontend/src/features/maintenance/version-updater.ts:256
`UI_ICONS.warning` 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. — frontend/src/preview-3d/adapters/litematic-adapter.ts:121
`t("preview.hint.clickBone")` 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. — frontend/src/preview-3d/adapters/vrm/vrm-bone-ui.ts:138
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.
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.
Do you agree with this assessment?
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.
Do you agree with this assessment?
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.
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.
`ysmRoot, _ := a.GetRepoRoot("ysm")` writes the call's error to `_` and then uses `ysmRoot` as if the call succeeded. When `a.GetRepoRoot` fails, `ysmRoot` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `ysmRoot` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. — internal/app/app.go:247
`exe, _ := os.Executable()` writes the call's error to `_` and then uses `exe` as if the call succeeded. When `os.Executable` fails, `exe` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `exe` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. (×2) — internal/app/app_config.go:86, internal/app/app_workshop.go:49
`if err != nil` 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. (×15) — internal/app/app_config.go:462, internal/app/app_config.go:657, internal/app/app_config.go:693, …
`if _, err := os.Stat(base); err != nil` 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. — internal/app/app_config_windows.go:63
`root, _ := a.GetRepoRoot(rtype)` writes the call's error to `_` and then uses `root` as if the call succeeded. When `a.GetRepoRoot` fails, `root` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `root` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. (×3) — internal/app/app_files.go:266, internal/app/app_install_import.go:85, internal/app/app_install_import.go:277
`if err := paths.IsInside(rootClean, srcClean); err != nil` 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. — internal/app/app_install_import.go:59
`dir, _ := a.GetRepoRoot(rtype)` writes the call's error to `_` and then uses `dir` as if the call succeeded. When `a.GetRepoRoot` fails, `dir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `dir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. — internal/app/app_install_import.go:150
`root, _ := a.GetRepoRoot("ysm")` writes the call's error to `_` and then uses `root` as if the call succeeded. When `a.GetRepoRoot` fails, `root` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `root` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. — internal/app/app_install_import.go:162
`globalDir, _ := a.filesRootForSync(rtype)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.filesRootForSync` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. (×7) — internal/app/app_install_import.go:306, internal/app/app_install_instance.go:379, internal/app/app_install_instance.go:416, …
`filesRoot, _ := a.GetRepoRoot(d.RType)` writes the call's error to `_` and then uses `filesRoot` as if the call succeeded. When `a.GetRepoRoot` fails, `filesRoot` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `filesRoot` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. (×2) — internal/app/app_install_instance.go:60, internal/app/app_install_instance.go:111
`globalDir, _ := a.GetRepoRoot(d.RType)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.GetRepoRoot` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. (×2) — internal/app/app_install_instance.go:291, internal/app/app_install_instance.go:348
`ysm, _ := a.GetRepoRoot("ysm")` writes the call's error to `_` and then uses `ysm` as if the call succeeded. When `a.GetRepoRoot` fails, `ysm` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `ysm` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line. — internal/app/app_scan.go:626
`if err := loadBundledJSON(" ", &list); err != nil` 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. (×2) — internal/app/app_workshop.go:162, internal/app/app_workshop.go:258
`if err := os.MkdirAll(dir, fsutil.DirPerms); err != nil` 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. — internal/app/pathmgr_android.go:85
What to do
Discarded error (assigned to `_`, then its result used)
Do you agree with this assessment?
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.
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.
~0.5 `!` null assertions per 1k TypeScript source lines — 77 assertion(s) across the 143113 source line(s) of the 637 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: frontend/src/wasm/ysm-worker-loader.ts (6), frontend/src/preview-3d/caps/postprocessing-composer.ts (5), frontend/src/preview-3d/adapters/mmd/mmd-build-menu.ts (4). Each one tells the compiler to trust the author about null, suppressing the very diagnostic `strictNullChecks` exists to produce. Many are correct: each is a claim the checker could not verify, and it is wrong only where the value can in fact be missing, so review the densest places first.
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 `?`).
Do you agree with this assessment?
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).
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.
Unscored — 5 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.
P12 CI test-gate honesty — 1 observation(s) recorded · Reported, not scored — this card publishes what the CI gate does with the test inventory rather than grading it. The findings above are its output.
SC1 Supply-chain hygiene — 1 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
X10 Duplicated predicate — 40 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
X7 Silent fallback defaults — 40 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
X9 Subsumed condition operand — 3 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 4 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.
C3 Audit Trail — Not assessed: these audit controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) 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. Absence of an idiom this check recognises is NOT evidence that this repository lacks audit controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
C4 Data Retention — Not assessed: these retention controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) 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. Absence of an idiom this check recognises is NOT evidence that this repository lacks retention controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
C5 Data-Subject Rights — Not assessed: these data-subject rights controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) 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. Absence of an idiom this check recognises is NOT evidence that this repository lacks data-subject rights controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
P5 DR & Backup — not evidenced — repo shows no backup/RTO/RPO controls; absence of evidence is not evidence of a working control
Not included — 40 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 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
AX2 Stateful singletons — No container singleton was found, so there is no shared instance for concurrent requests to race on. No Go request handler (a net/http, Gin, Echo, Fiber or fasthttp handler, or a gRPC service method) is declared as a method or function, and no handler function literal writes a value captured from outside it, so no state is shared between request goroutines. Rust's compiler refuses unsynchronised shared mutation — a value shared across threads must be Sync — so the race this check looks for cannot be written. 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).
AX4 Dependency direction — not applicable to a vertical-slice architecture (the inward-dependency rule is for layered/clean styles)
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 (`npm run dev` in docs/) exited before it served a page. Likely cause (our sandbox): a program the dev server needs is not installed in our sandbox image. This is a limit of our sandbox, not of your repository. Last output: "> ysm-model-manager-docs@0.0.0 dev / > vitepress dev / sh: 1: vitepress: not found / npm error Lifecycle script `dev` failed with error: / npm error code 127 / npm error path <repo>/docs / npm error workspace ysm-model-manager-docs@0.0.0 / npm error location <repo>/docs / npm error command failed / npm error command sh -c vitepress dev" No runtime evidence was gathered. 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 — Not assessed: these personal data controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) 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. Absence of an idiom this check recognises is NOT evidence that this repository lacks personal data controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
C2 Access Controls — Not assessed: these authorization controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) 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. Absence of an idiom this check recognises is NOT evidence that this repository lacks authorization controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
D16 Bus Factor — single-maintainer repository — bus factor is not applicable
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.
D20 ADR Quality — 380 ADR(s) are written in a language our ADR lexicon does not cover, or are too short to tell (undetermined); their sections and statuses were not judged.
D23 Boundary Type-Coupling — No bounded-context organisation was detected either — neither a context-shaped layout, nor 2+ sibling source directories each declaring an aggregate root, nor 2+ sibling projects each declaring an entity of their own or taking another project's integration events. Declaring this codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
D25 ADR Conformance — None of 0 binding record(s) states a rule in checkable form (a backticked element with a prohibition, or an `adr-rules` block), so conformance cannot be read from the code. Write the rule as an `adr-rules` block (`forbid:` a symbol, a package or a dependency) to make it checkable.
D27 Navigability — D27 reads resolved call sites in the languages it reads only — this repository's production source is .java, .rs, .ts, which was left unread. 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) — 44 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
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.
D8 Code Coverage — Coverage not measured — polyglot repository, one half has no runner
DM1 Domain Modelling — applicable but not scored (2 signals for this style, 2 needed — the count is met but a required primary signal is absent): 2 value object(s); a Domain/Aggregates/ValueObjects layer
ED2 Event/command shape — not scored — deciding whether a command has more than one competing handler requires resolving the call graph, and a call made through an inferred or generic receiver has no resolvable owner in the source. Reported as guidance rather than measured
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
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 607 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.
PF2 Allocation hygiene — Not scored: this check counted allocation-aware idioms (Span, pools, stackalloc) per line, which describes what kind of code a repository is rather than whether it has an allocation problem, so it was withdrawn. Nothing here is a finding about your code.
S1 Web-Security Posture — Not assessed: these web-security controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) 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. Absence of an idiom this check recognises is NOT evidence that this repository lacks web-security controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
X14 Bypassable address classification — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X15 Unvalidated length from an untrusted reader — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X17 Uncapped recursion over a caller-supplied document — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X19 Unrestored process-global state — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X20 Mistyped argument guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X22 Contradicted release guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X23 Unguarded diagnostic materialisation — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X26 Unsynchronised callback handoff — X26 reached only 21% of this repository's production lines — typescript (190,776 lines), javascript (5,054 lines), rust (55 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X27 Collection changed while being enumerated — X27 reached only 21% of this repository's production lines — typescript (190,776 lines), javascript (5,054 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
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 — This check asks whether log calls keep a message's values apart from its text, which needs a logger that can carry them as fields. This repository's Go was read, and it logs through none: the standard library's `log` takes one finished line, or it makes no log call outside its tests at all, so an assembled message there loses nothing the API could have kept (as with log4net in C#). Calls through log/slog, zap, logrus, zerolog, hclog, go-kit's log or logr would be judged.
X6 Hand-rolled structured-format parsing — 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.
Boundary-crossing change coupling: ui-icons.ts ↔ icon-map.ts frontend/src/utils/icon/ui-icons.ts:1— `frontend/src/utils/icon/ui-icons.ts` (context utils) and `scripts/_lib/icon-map.ts` (context scripts) sit in DIFFERENT parts of the tree yet change together 91% of the time (10 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 10 shared commits counted here, the most recent 3 are `c3d93e81` fix(a11y-icons): ADR-238 扫尾M1——view-mode/genindex 图标双轨打架结案 + grid/ver…; `002df953` refactor(diagnostics): 日志状态 emoji 全迁 UI_ICONS SVG(ADR-238 收债); `5040458d` fix(preview-3d): row-radio/badge 恢复可见(样式单源 MENU_BTN_CSS + 图标化 radio/b… — run `git show` on any of them.
Boundary-crossing change coupling: ja.ts ↔ perf.ts frontend/src/locales/ja.ts:1— `frontend/src/locales/ja.ts` (context locales) and `frontend/src/views/app-content/diagnostics/perf.ts` (context views) sit in DIFFERENT parts of the tree yet change together 67% of the time (20 of the 30 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 20 shared commits counted here, the most recent 3 are `010c4279` feat(diagnostics): 阶段→加载剖析下钻——CLI 基准跳同一模型前端实测; `d5c20ede` feat(diagnostics): 基准三件套默认收起——参数密度开关(简版/进阶)+ 收起即失效; `966d6fa8` refactor(diagnostics): 版面词典收口——三 tab 统一布局词汇,修 pill 对齐与常驻栏滚走 — run `git show` on any of them.
Boundary-crossing change coupling: zh-CN.ts ↔ perf.ts frontend/src/locales/zh-CN.ts:1— `frontend/src/locales/zh-CN.ts` (context locales) and `frontend/src/views/app-content/diagnostics/perf.ts` (context views) sit in DIFFERENT parts of the tree yet change together 67% of the time (20 of the 30 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 20 shared commits counted here, the most recent 3 are `010c4279` feat(diagnostics): 阶段→加载剖析下钻——CLI 基准跳同一模型前端实测; `d5c20ede` feat(diagnostics): 基准三件套默认收起——参数密度开关(简版/进阶)+ 收起即失效; `966d6fa8` refactor(diagnostics): 版面词典收口——三 tab 统一布局词汇,修 pill 对齐与常驻栏滚走 — run `git show` on any of them.
Boundary-crossing change coupling: en.ts ↔ perf.ts frontend/src/locales/en.ts:1— `frontend/src/locales/en.ts` (context locales) and `frontend/src/views/app-content/diagnostics/perf.ts` (context views) sit in DIFFERENT parts of the tree yet change together 67% of the time (20 of the 30 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 20 shared commits counted here, the most recent 3 are `010c4279` feat(diagnostics): 阶段→加载剖析下钻——CLI 基准跳同一模型前端实测; `d5c20ede` feat(diagnostics): 基准三件套默认收起——参数密度开关(简版/进阶)+ 收起即失效; `966d6fa8` refactor(diagnostics): 版面词典收口——三 tab 统一布局词汇,修 pill 对齐与常驻栏滚走 — run `git show` on any of them.
Boundary-crossing change coupling: ysm-adapter.ts ↔ ysm-controls.ts frontend/src/preview-3d/adapters/ysm-adapter.ts:1— `frontend/src/preview-3d/adapters/ysm-adapter.ts` (context preview-3d) and `frontend/src/views/app-preview/ysm-controls.ts` (context views) sit in DIFFERENT parts of the tree yet change together 67% of the time (14 of the 21 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 14 shared commits counted here, the most recent 3 are `bf1459a4` refactor(preview-3d): G3 fill* 命令式旧轨删除 — fillMmdModelPanel/fillMmdSho…; `edceb408` refactor(preview-3d): S4 桥契约下沉 content-bridges.ts — mmd/ysm 6 纯类型自 vi…; `6b080b33` fix(3d): YSM/maid per-scene schema key + activeComponent 会话态隔离(多模型同框防覆盖) (at that commit the file was still `frontend/src/utils/3d/adapters/ysm-adapter.ts`) — run `git show` on any of them.
Boundary-crossing change coupling: sync.ts ↔ sync-flow.ts frontend/src/features/sync/sync.ts:1— `frontend/src/features/sync/sync.ts` (context features) and `frontend/src/views/app-sidebar/sync-flow.ts` (context views) sit in DIFFERENT parts of the tree yet 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 — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 7 shared commits counted here, the most recent 3 are `c30f659b` feat(sync): 推送侧逐文件点名(PackOutcome.files,零 Go 改动)+ 浮层逐包缩进文件行; `c5b51125` feat(sync): 批量推送覆盖实例侧手改须如实计数与点名(ADR-340-d2); `c716fcb5` feat(sync): 推送结果补包级归因,失败点名到整合包(锐评 P1-3) — run `git show` on any of them.
Boundary-crossing change coupling: ysm-adapter.ts ↔ ysm-3d.ts frontend/src/preview-3d/adapters/ysm-adapter.ts:1— `frontend/src/preview-3d/adapters/ysm-adapter.ts` (context preview-3d) and `frontend/src/views/app-preview/ysm-3d.ts` (context views) sit in DIFFERENT parts of the tree yet change together 58% of the time (18 of the 31 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 18 shared commits counted here, the most recent 3 are `bf1459a4` refactor(preview-3d): G3 fill* 命令式旧轨删除 — fillMmdModelPanel/fillMmdSho…; `f769f467` frontend(ysm-adapter): 清理 makeYsmAdapter 死 path 参数与假注释; `9a65f796` refactor(preview): P5-收尾 morph/play 交互面板声明式化——morphNodes + playNodes,… (at that commit the file was still `frontend/src/utils/3d/adapters/ysm-adapter.ts`) — run `git show` on any of them.
Boundary-crossing change coupling: sync.ts ↔ zh-CN.ts frontend/src/features/sync/sync.ts:1— `frontend/src/features/sync/sync.ts` (context features) and `frontend/src/locales/zh-CN.ts` (context locales) sit in DIFFERENT parts of the tree yet 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 — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 6 shared commits counted here, the most recent 3 are `c5b51125` feat(sync): 批量推送覆盖实例侧手改须如实计数与点名(ADR-340-d2); `c716fcb5` feat(sync): 推送结果补包级归因,失败点名到整合包(锐评 P1-3); `eb8212fc` fix(sync): 失败明细点名——原 catch{totalFail++} 吞错误对象、InvalidateScanCache 失败只… — run `git show` on any of them.
Boundary-crossing change coupling: sync.ts ↔ ja.ts frontend/src/features/sync/sync.ts:1— `frontend/src/features/sync/sync.ts` (context features) and `frontend/src/locales/ja.ts` (context locales) sit in DIFFERENT parts of the tree yet 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 — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 6 shared commits counted here, the most recent 3 are `c5b51125` feat(sync): 批量推送覆盖实例侧手改须如实计数与点名(ADR-340-d2); `c716fcb5` feat(sync): 推送结果补包级归因,失败点名到整合包(锐评 P1-3); `eb8212fc` fix(sync): 失败明细点名——原 catch{totalFail++} 吞错误对象、InvalidateScanCache 失败只… — run `git show` on any of them.
Boundary-crossing change coupling: sync.ts ↔ en.ts frontend/src/features/sync/sync.ts:1— `frontend/src/features/sync/sync.ts` (context features) and `frontend/src/locales/en.ts` (context locales) sit in DIFFERENT parts of the tree yet 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 — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 6 shared commits counted here, the most recent 3 are `c5b51125` feat(sync): 批量推送覆盖实例侧手改须如实计数与点名(ADR-340-d2); `c716fcb5` feat(sync): 推送结果补包级归因,失败点名到整合包(锐评 P1-3); `eb8212fc` fix(sync): 失败明细点名——原 catch{totalFail++} 吞错误对象、InvalidateScanCache 失败只… — run `git show` on any of them.
Boundary-crossing change coupling: zh-CN.ts ↔ perf-matrix-render.ts frontend/src/locales/zh-CN.ts:1— `frontend/src/locales/zh-CN.ts` (context locales) and `frontend/src/views/app-content/diagnostics/perf-matrix-render.ts` (context views) sit in DIFFERENT parts of the tree yet change together 54% of the time (7 of the 13 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 7 shared commits counted here, the most recent 3 are `ffeb948c` fix(diagnostics): 类型标签走 i18n 出口(P0 键族失配 10/15 类型回落中文)+ 表头术语解释单点; `0c57b422` refactor(diagnostics): 目标集下拉分组去黑话,解开与模式下拉的撞名耦合; `4ca3d2b6` fix(cli): 信封耗时改用纳秒精度 + 三个性能区段展示命令耗时(附字段级零读取审计脚本) — run `git show` on any of them.
Boundary-crossing change coupling: ja.ts ↔ perf-matrix-render.ts frontend/src/locales/ja.ts:1— `frontend/src/locales/ja.ts` (context locales) and `frontend/src/views/app-content/diagnostics/perf-matrix-render.ts` (context views) sit in DIFFERENT parts of the tree yet change together 54% of the time (7 of the 13 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 7 shared commits counted here, the most recent 3 are `ffeb948c` fix(diagnostics): 类型标签走 i18n 出口(P0 键族失配 10/15 类型回落中文)+ 表头术语解释单点; `0c57b422` refactor(diagnostics): 目标集下拉分组去黑话,解开与模式下拉的撞名耦合; `4ca3d2b6` fix(cli): 信封耗时改用纳秒精度 + 三个性能区段展示命令耗时(附字段级零读取审计脚本) — run `git show` on any of them.
Boundary-crossing change coupling: en.ts ↔ perf-matrix-render.ts frontend/src/locales/en.ts:1— `frontend/src/locales/en.ts` (context locales) and `frontend/src/views/app-content/diagnostics/perf-matrix-render.ts` (context views) sit in DIFFERENT parts of the tree yet change together 54% of the time (7 of the 13 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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) — the bounded-context boundary may be in the wrong place, or one context is leaking into the other. This is the behavioural boundary violation a static scan can't see. You can check this without leaving the row: of the 7 shared commits counted here, the most recent 3 are `ffeb948c` fix(diagnostics): 类型标签走 i18n 出口(P0 键族失配 10/15 类型回落中文)+ 表头术语解释单点; `0c57b422` refactor(diagnostics): 目标集下拉分组去黑话,解开与模式下拉的撞名耦合; `4ca3d2b6` fix(cli): 信封耗时改用纳秒精度 + 三个性能区段展示命令耗时(附字段级零读取审计脚本) — run `git show` on any of them.
AC2 · Forms & labels· <input> without a programmatic label · ×11
<input> without a programmatic label frontend/src/features/community/render.ts:151— 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 frontend/src/preview-3d/adapters/vrm/vrm-bone-ui.ts:101— 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 frontend/src/preview-3d/menu/render/cap-controls.ts:328— 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 frontend/src/preview-3d/menu/render/cap-controls.ts:419— 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 frontend/src/preview-3d/menu/render/rows.ts:386— 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 frontend/src/utils/dom/modal-prompt.ts:37— This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label.
<input> without a programmatic label frontend/src/views/app-content/site/render.ts:335— This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label.
<input> without a programmatic label frontend/src/views/app-content/site/render.ts:405— This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label.
<input> without a programmatic label frontend/src/views/app-content/site/render.ts:433— This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label.
<input> without a programmatic label frontend/src/views/app-content/site/render.ts:440— This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label for>, a wrapping <label>, or aria-label.
<input> without a programmatic label frontend/src/views/app-tree/events.ts:62— This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
AC4 · Keyboard semantics· Click handler on a non-interactive <div> · ×4
Click handler on a non-interactive <div> frontend/src/preview-3d/adapters/vrm/vrm-bone-ui.ts:90— 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 <div> frontend/src/preview-3d/menu/engine/core.ts:155— 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 <div> frontend/src/preview-3d/menu/panels/roles-views.ts:259— 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 <div> frontend/src/preview-3d/menu/render/cap-controls.ts:189— A click handler on a plain element isn't keyboard-operable. Use a <button>, or add role + tabindex="0" + a key handler.
D10 · Test Quality· No assertions (empty test) · ×4
No assertions (empty test): busy 拒收必须可见(批D:原实现静默 return,点另一个按钮零反馈) frontend/src/views/app-sidebar/app-sidebar.sync.test.ts:643— Test method has an empty body — it asserts nothing and exercises no code.
No assertions (empty test): 可见面板三连切(A→B→C):pending 只留最新,补扫按 C frontend/src/views/app-content/diagnostics/dedup.test.ts:295— Test method has an empty body — it asserts nothing and exercises no code.
No assertions (empty test): 取消按钮 → CancelError → 「已取消」落定,busy 复位可复扫 frontend/src/views/app-content/diagnostics/dedup.test.ts:554— Test method has an empty body — it asserts nothing and exercises no code.
No assertions (empty test): 单例模式:新调用清理旧的 frontend/src/utils/dom/trap-focus-across-shadow.test.ts:145— Test method has an empty body — it asserts nothing and exercises no code.
AC2 · Forms & labels· <select> without a programmatic label · ×3
<select> without a programmatic label frontend/src/preview-3d/menu/render/cap-controls.ts:369— This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
<select> without a programmatic label frontend/src/utils/dom/modal-select.ts:36— This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
<select> without a programmatic label frontend/src/views/app-content/site/render.ts:458— 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 · ×1
<button> with no accessible text frontend/src/views/app-content/settings/keymap.ts:123— 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).
AC3 · Page structure· <iframe> without a title · ×1
<iframe> without a title frontend/src/views/app-content/tpl.ts:292— An iframe with no title (or an empty one) is announced only as "frame". Add a non-empty title describing its content, or an aria-label.
Unlisted import 'esbuild' artifacts/audit-env-s13/probe.mjs:44— Imported but not declared in any reachable package.json — installs work only by hoisting accident.
Hotspot: scripts/pre-push-gate.ts scripts/pre-push-gate.ts:123— scripts/pre-push-gate.ts changed 106 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 52 in pre-push-gate.main at line 123. 25 of those changes were fix/bug commits, and the other 81 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/pre-push-gate.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/check-redlines.ts scripts/check-redlines.ts:170— scripts/check-redlines.ts changed 56 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 60 in check-redlines.runChecks at line 170. 7 of those changes were fix/bug commits, and the other 49 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/check-redlines.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/check-go-diff-coverage.ts scripts/check-go-diff-coverage.ts:623— scripts/check-go-diff-coverage.ts changed 30 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 94 in check-go-diff-coverage.main at line 623. 7 of those changes were fix/bug commits, and the other 23 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/check-go-diff-coverage.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/check-layering.ts scripts/check-layering.ts:384— scripts/check-layering.ts changed 24 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 88 in check-layering.main at line 384. 2 of those changes were fix/bug commits, and the other 22 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/check-layering.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: frontend/src/views/app-tree/index.ts frontend/src/views/app-tree/index.ts:756— frontend/src/views/app-tree/index.ts changed 106 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in AppTree._onKeyArrowNav at line 756. 26 of those changes were fix/bug commits, and the other 80 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-tree/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: scripts/check-knowledge-drift.ts scripts/check-knowledge-drift.ts:153— scripts/check-knowledge-drift.ts changed 44 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 36 in check-knowledge-drift.checkKnowledgeMeta at line 153. 9 of those changes were fix/bug commits, and the other 35 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/check-knowledge-drift.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: frontend/src/preview-3d/caps/light-capability.ts frontend/src/preview-3d/caps/light-capability.ts:323— frontend/src/preview-3d/caps/light-capability.ts changed 86 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in LightCapability.onEnvChanged at line 323. 16 of those changes were fix/bug commits, and the other 70 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/preview-3d/caps/light-capability.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: frontend/src/preview-3d/menu/render/render.ts frontend/src/preview-3d/menu/render/render.ts:179— frontend/src/preview-3d/menu/render/render.ts changed 77 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in render.rmAppendFolder at line 179. 5 of those changes were fix/bug commits, and the other 72 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/preview-3d/menu/render/render.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: go/repoaudit/repoaudit.go go/repoaudit/repoaudit.go:200— go/repoaudit/repoaudit.go changed 36 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 36 in repoaudit.AuditCtx at line 200. 16 of those changes were fix/bug commits, and the other 20 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/repoaudit/repoaudit.go`: 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: frontend/src/views/app-preview/detail-3d.ts frontend/src/views/app-preview/detail-3d.ts:52— frontend/src/views/app-preview/detail-3d.ts changed 61 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in detail-3d.showVrmMeta at line 52. 15 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-preview/detail-3d.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: REDACTED REDACTED:96— REDACTED changed 57 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in edit.eeApplyFilters at line 96. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08: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: frontend/src/views/app-tree/bus-handlers.ts frontend/src/views/app-tree/bus-handlers.ts:358— frontend/src/views/app-tree/bus-handlers.ts changed 62 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in bus-handlers.runBatchToggle at line 358. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-tree/bus-handlers.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: internal/app/app_scan.go internal/app/app_scan.go:80— internal/app/app_scan.go changed 65 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in App.SearchModels at line 80. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- internal/app/app_scan.go`: 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: frontend/src/views/app-content/settings/path-cards.ts frontend/src/views/app-content/settings/path-cards.ts:207— frontend/src/views/app-content/settings/path-cards.ts changed 54 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in path-cards.initAdvancedGrid.refreshAdvanced at line 207. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-content/settings/path-cards.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: frontend/src/views/app-tree/events.ts frontend/src/views/app-tree/events.ts:474— frontend/src/views/app-tree/events.ts changed 57 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in events.toggleFolderBatch at line 474. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-tree/events.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: frontend/src/views/app-preview/skeleton.ts frontend/src/views/app-preview/skeleton.ts:46— frontend/src/views/app-preview/skeleton.ts changed 62 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in skeleton.loadModel2D at line 46. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-preview/skeleton.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/check-adr-drift.ts scripts/check-adr-drift.ts:86— scripts/check-adr-drift.ts changed 24 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 41 in check-adr-drift.codeAsserts at line 86. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/check-adr-drift.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/line-counter.ts scripts/line-counter.ts:122— scripts/line-counter.ts changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 72 in line-counter.findFunctionEnd at line 122. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/line-counter.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: frontend/src/views/app-content/diagnostics/logs.ts frontend/src/views/app-content/diagnostics/logs.ts:221— frontend/src/views/app-content/diagnostics/logs.ts changed 39 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in logs.dgLsBuildDiagMsg at line 221. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-content/diagnostics/logs.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/gen-knowledge-autogen.ts scripts/gen-knowledge-autogen.ts:371— scripts/gen-knowledge-autogen.ts changed 17 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 45 in gen-knowledge-autogen.main at line 371. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/gen-knowledge-autogen.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/check-orphan-exports.ts scripts/check-orphan-exports.ts:103— scripts/check-orphan-exports.ts changed 17 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 44 in check-orphan-exports.extractImports at line 103. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/check-orphan-exports.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: frontend/src/views/app-sync-manager/renderer.ts frontend/src/views/app-sync-manager/renderer.ts:147— frontend/src/views/app-sync-manager/renderer.ts changed 44 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in renderer.renderStatusTabs at line 147. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-sync-manager/renderer.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: frontend/src/views/app-preview/tpl.ts frontend/src/views/app-preview/tpl.ts:199— frontend/src/views/app-preview/tpl.ts changed 27 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 25 in tpl.statsCardHTML at line 199. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-preview/tpl.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: go/sync/sync_dirlevel.go go/sync/sync_dirlevel.go:146— go/sync/sync_dirlevel.go changed 41 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in sync.patternFindMemo at line 146. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/sync/sync_dirlevel.go`: 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/check-deadcode-baseline.ts scripts/check-deadcode-baseline.ts:153— scripts/check-deadcode-baseline.ts changed 21 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 30 in check-deadcode-baseline.main at line 153. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/check-deadcode-baseline.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.
+ 92 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 frontend/src/features/community/data.ts:29— `UI_ICONS.refresh` 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 frontend/src/features/community/download-queue-progress.ts:145— `UI_ICONS.refresh` 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 frontend/src/features/community/download-queue-progress.ts:155— ``${UI_ICONS.refresh}${".".repeat(ctx._dots)}`` 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 frontend/src/features/community/download-queue-progress.ts:276— ``${UI_ICONS.error} ${t("downloadQueue.failedCount",{n:s.errorList.length})}`` 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 frontend/src/features/community/download-queue-progress.ts:298— `UI_ICONS.error` 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 frontend/src/features/community/download-queue.ts:95— `UI_ICONS.download` 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 frontend/src/features/community/download-queue.ts:141— `UI_ICONS.download` 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 frontend/src/features/community/download-queue.ts:147— `UI_ICONS.refresh` 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 frontend/src/features/community/download-queue.ts:158— `UI_ICONS.close` 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 frontend/src/features/community/download-queue.ts:212— ``${UI_ICONS.error} ${t("downloadQueue.failedListTitle",{n:s.errorList.length})}`` 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 frontend/src/features/community/download-queue.ts:219— ``${UI_ICONS.error} ${renderDisplayName(e.name)}: ${ctx.esc(e.err)}`` 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 frontend/src/features/community/download-queue.ts:233— ``${UI_ICONS.close} ${t("downloadQueue.cancelled")}`` 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 frontend/src/features/community/render.ts:103— `iconHTML` 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 frontend/src/features/community/render.ts:183— ``${UI_ICONS.success} ${t("workshop.exists")}`` 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 frontend/src/features/community/repo-events-bindings.ts:42— ``${UI_ICONS.folder} ${esc(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 frontend/src/features/community/repo-events-bindings.ts:174— `UI_ICONS.refresh` 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 frontend/src/features/community/repo-events-bindings.ts:178— `UI_ICONS.download` 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 frontend/src/features/community/repo-events-shared.ts:130— ``${UI_ICONS.download} ${t("workshop.downloadSelected",{n:checked})}`` 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 frontend/src/features/dialogs/adv-filter.ts:187— `opts.tpl.formHTML(v)` 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 frontend/src/features/dialogs/batch-rename-form.ts:84— `tpl.previewHTML(rows)` 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 frontend/src/features/dialogs/batch-rename-form.ts:177— ``${UI_ICONS.clipboard} ${show?t("dialog.collapse"):t("dialog.presets")}`` 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 frontend/src/features/dialogs/batch-rename-form.ts:276— ``${UI_ICONS.refresh} ${t("dialog.executing")}`` 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 frontend/src/features/dialogs/batch-rename-form.ts:289— ``${UI_ICONS.edit} ${t("dialog.doRename")}`` 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 frontend/src/features/dialogs/batch-rename.ts:133— `tpl.formHTML(dir,items.length,changed)` 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 frontend/src/features/dialogs/rename.ts:38— ``${UI_ICONS.book} ${t("dialog.readHeader")}`` 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.
No assertions: 10. bus tree:set-search 驱动搜索框 frontend/src/views/app-tree/app-tree.state.test.ts:168— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: P2 修复:click 回调抛错 → error toast 反馈且不静默 frontend/src/views/app-toast/index.test.ts:82— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: P2 修复:undo 回调抛错 → 显示❌撤销失败且原 toast 移除 frontend/src/views/app-toast/index.test.ts:136— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: removeAttribute('instance') 同款收口(newVal=null 路径) frontend/src/views/app-sync-manager/index.branches.test.ts:262— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 实例删除后再现 → 不被静默勾选(幽灵名已被修剪,prune 先于 restore) frontend/src/views/app-sidebar/app-sidebar.sync.test.ts:201— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 拉取无多余文件 → info toast frontend/src/views/app-sidebar/app-sidebar.sync.test.ts:523— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: repo:rtype-changed → 切到 resourcepack(无 subdir)重建树 frontend/src/views/app-content/app-content.methods.test.ts:339— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: localStorage 存非默认 rtype → 初始化恢复该 rtype 文件树 frontend/src/views/app-content/app-content.methods.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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: LoadGitHubRepos 失败 → loadFailed 降级文案 frontend/src/views/app-content/init-github.test.ts:146— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: onProgress 回调 → resultsBody 加载态文本更新 frontend/src/views/app-content/init-github.test.ts:255— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: ctx 接线:bindCtx.showRepoModels() → 重新 showRepo;bindCtx.backToSite() → 重新 loadRepos frontend/src/views/app-content/init-github.test.ts:487— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 无路径 → warn toast 未找到 frontend/src/views/app-content/settings/init.test.ts:263— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: relink 无 mcRoot → warn toast frontend/src/views/app-content/settings/init.test.ts:386— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: SetDownloadMirror 失败 → 错误 toast(有出口) frontend/src/views/app-content/settings/init.test.ts:808— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 链接模式切换失败 → 错误 toast(不静默) frontend/src/views/app-content/settings/init.test.ts:822— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 路径保存失败 → 错误 toast(有出口) frontend/src/views/app-content/settings/init.test.ts:839— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: relink 实例部分失败 → 成功 toast 报出真实失败数与首个原因(ADR-342 D7) frontend/src/views/app-content/settings/init.test.ts:851— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: relink 全失败 → 失败 toast 报出失败数 frontend/src/views/app-content/settings/init.test.ts:886— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: SaveThresholds 失败 → 错误 toast(有出口) frontend/src/views/app-content/settings/init.test.ts:1092— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: ListVersionInstances 拒绝 → 外层 catch → 错误 toast frontend/src/views/app-content/settings/init.test.ts:1206— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 初始加载:无日志 → 暂无日志占位 frontend/src/views/app-content/diagnostics/init.test.ts:156— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 搜索命中报错内容 / 目标路径(不再只匹配模型名) frontend/src/views/app-content/diagnostics/init.test.ts:296— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 运行时子 tab:搜索无命中 → 「无匹配日志」占位 frontend/src/views/app-content/diagnostics/init.test.ts:340— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: GetImportLogs 抛错 → 加载日志失败占位 frontend/src/views/app-content/diagnostics/init.test.ts:419— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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: 刷新按钮:runtime 子 tab 激活 → 加载运行时日志;否则重载导入日志 frontend/src/views/app-content/diagnostics/init.test.ts:431— 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*, in the test body and in the helpers it calls in the test and test-support code (a helper there that throws when its check fails counts as an assertion) — so verification routed through a callback object whose members hold the assertions, or through a harness in production code that fails by throwing, 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.
Repeated repair: internal/app/app_install_recycle.go internal/app/app_install_recycle.go:88— internal/app/app_install_recycle.go changed 19 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 11 (its worst body is App.findRecycleRoot at line 88), AT OR 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(recycle,fileops): 根枚举收敛单点 + subpath 补盘符判定 + Empty 判定合并”; “fix(recycle): 归属收敛为「最具体根」,与启禁链同规则、消除遍历序漂移”; “fix(recycle): 根级自卫改判「任一已知根」,堵外层 CustomRoot 绕过”; “fix(tags): 审计 G1/G2 根治——启动扁平→分组迁移标签键跟随(migrateAndRekey 唯一入口,迁移函数返回迁移对)+ 回收站永久删除标签键清理(recycleOriginal/recycleOriginals 反推原始路径 PruneKeys;移入回收站刻意不 prune=临时态 Restore 自愈,dedup 侧核清无缺口)。TDD:app_migrate_rekey_test 3 例 + app_recycle_tags_test 4 例;变异 M1/M2 精确转红后还原;internal/app 全量 + tags/recycle 包 + 契约 139/139 全绿;go-tags/go-recycle/tracker 卡同步收口态”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- internal/app/app_install_recycle.go`: 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: frontend/src/utils/cache/with-cached.ts frontend/src/utils/cache/with-cached.ts:72— frontend/src/utils/cache/with-cached.ts changed 19 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 11 (its worst body is with-cached.withCached at line 72), AT OR 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(utils): safeStr 补 Map 分支(防序列化成空表)+ 测试;css 冗余类型标注删除;with-cached STALE 注释澄清 LRU 触摸”; “fix: 兑现 withCached 在途失败重试契约,focus-restore 栈加上限,清理 animate 死分支”; “fix(utils): 第二轮清理 — 依赖治理 + 死代码 + 测试补全”; “fix(utils): 消除死代码 + 测试隔离钩子”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/utils/cache/with-cached.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: go/sync/conflict.go go/sync/conflict.go:134— go/sync/conflict.go changed 21 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 9 (its worst body is sync.ResolveConflict at line 134), AT OR 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(sync): conflict relErr 降级为条目级跳过,与 hashErr 错误通道口径对齐”; “fix(sync/avatar): 审核修复——未持锁冲突解决改走自锁入口 + .done 标记签名竞态 + 过时锁契约注释”; “fix(go/sync): 修复 P2/P3——compareHashMode 活跃优先、备份删除日志化、RelinkDir 扫描移出锁、dirlevel 头注释漂移”; “fix(go/sync): 冲突检测错误通道分离——单文件哈希失败降为条目级,HashFailed 人工审查分支可达”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/sync/conflict.go`: 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: go/threejs/spec.go go/threejs/spec.go:174— go/threejs/spec.go changed 13 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 12 (its worst body is threejs.buildCubeMeshData at line 174), AT OR 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: UV mirror 补 east/west 整面互换(修 01 女仆左臂青条),复活 port-align UV 对拍”; “fix: 修复 per-face UV 模型 up/down 贴图颠倒(foxcar)及连带透明度误判”; “fix: 修复 5 个严重问题 (threejs/fsutil/installer/ysm/repoaudit)”; “fix(3d): Model3DSpec typed 返回补 texArrOrder/componentTextures 字段——修复 perComponent 纹理注入被 Unmarshal 静默丢弃的回归(936169b1)”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/threejs/spec.go`: 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: frontend/src/views/app-content/site/workshop-data.ts frontend/src/views/app-content/site/workshop-data.ts:67— frontend/src/views/app-content/site/workshop-data.ts changed 12 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 12 (its worst body is workshop-data.getCreatorIdentity at line 67), AT OR 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(community): 修复创作者频道预设 q 丢失/键盘导航失效/收藏排序与筛选粘滞”; “fix(frontend): 创作者界面锐评批四——tier 色条强化 + hover 动效收敛 + 描述阈值降级”; “fix(frontend): 创作者界面锐评批三-a——type 分号收口 + 筛选零结果空态 + platform 控件改 badge 组”; “fix(community): 复核回炉——P0-2 治本源头 + desc 不丢尾 + tag 文案单源 + 假锁重铸”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-content/site/workshop-data.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: frontend/src/utils/dom/focus-restore.ts frontend/src/utils/dom/focus-restore.ts:41— frontend/src/utils/dom/focus-restore.ts changed 12 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 6 (its worst body is focus-restore.createFocusRestoreManager.returnFocus at line 41), AT OR 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,i18n,utils): code_review d0c543bb2/42566b09b——boot mock 补导出 + 热路径零分配 + base 二次分层断链收口”; “fix: 兑现 withCached 在途失败重试契约,focus-restore 栈加上限,清理 animate 死分支”; “fix(utils): 第三轮 — 架构隐患治理 + 根因修复”; “fix: 七轮修复5项——focus-restore栈上限+executeTimeline回绕+状态机校验+缓存优化”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/utils/dom/focus-restore.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: go/recycle/recycle_clean.go go/recycle/recycle_clean.go:179— go/recycle/recycle_clean.go 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 9 (its worst body is recycle.DeduplicateEntries at line 179), AT OR 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(go): R26 code_review 修复——installer fatal 错误分级 + recycle Windows 盘符根守卫”; “fix(go): R26 P3/P4 清理——installer 错误分级 + recycle 计数/守卫 + download 退避/缓存/URL”; “fix(recycle): R24 审核修复——App 层回收站绑定补 InstallLock(P3)+ RemoveRepoDuplicates 空根守卫前移(P4)”; “fix: 深审三处收口——sync Missing 字典序确定性(map 迭代序不泄漏)、共享锁瞬时争用等待重试一次、RemoveRepoDuplicates 失败逐条上报 failed 回调(口径对齐 DeduplicateEntries)”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/recycle/recycle_clean.go`: 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: internal/app/install/queue.go internal/app/install/queue.go:192— internal/app/install/queue.go changed 11 times in last 90 days and 6 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 13 (its worst body is DownloadQueue.consume at line 192), AT OR 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: 收口 pre-push 三项 hard 阻断——bench 退化判定补绝对增量下限(亚毫秒基准不再假退化)+ golangci-lint 4 条 + mount-preview-core 破线行数”; “fix(install): 下载队列 ADR-237 审核修复 —— Enqueue 关闭窗口守卫 + 空洞测试重建”; “fix(install): DownloadQueue spawn 携带代际守卫,消除取消后重入队的重复 done 竞态”; “fix(go): 锐评修复第二批——DownloadQueue生命周期挂appCtx(parentCtx派生+退出不重启不发假done+测试)、ensureRepoWorkflow扩展名清单从registry.AllExts()动态注入(消灭第三份平行实现,契约测试锁定)”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- internal/app/install/queue.go`: 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: go/container/container.go go/container/container.go:210— go/container/container.go changed 10 times in last 90 days and 6 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 container.openDir at line 210), AT OR 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(errcheck): 清理 go/cli/container/download/importer/litematic/recycle/scanner/sync/watcher 生产 errcheck 命中”; “fix: 容器条目名编码救援——GBK/Shift-JIS/Big5 三路解码打分择优(移植 MikuMikuAR decodeZipName,修 GBK zip 条目乱码)”; “fix: container 错误前缀统一 + Reader.Incomplete 目录枚举不完整语义 + dirEntry Size 绝对值修正 + ZipMatchesEntries 表驱动直测”; “fix(sync/container): code_review 修复——冲突检测 hash 比较化、JSON 契约、禁用后缀口径统一”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/container/container.go`: 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: go/cli/health.go go/cli/health.go:35— go/cli/health.go 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 12 (its worst body is cli.runHealthReport at line 35), AT OR 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): 纳秒精度收口补全三残口(health/perf/scan_bench 入码 Microseconds→durationMs)+ 文本闸升级全包扫描(a128f35bc 残口收口)”; “fix(cli): 登记 maid-model 为 CLI 可分析,并让按类型提升的候选先过几何验证(车万女仆假阴性)”; “fix(repoaudit): 全探测失败时显示层不再吞掉失败提示,补 CacheDir 不可用测试”; “fix(repoaudit): 删除语义错误的缓存命中率字段(HitRate/Hits/Misses),体检页不再显示失真的命中率百分比”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/cli/health.go`: 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: frontend/src/backend/web-fs-auth.ts frontend/src/backend/web-fs-auth.ts:138— frontend/src/backend/web-fs-auth.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 8 (its worst body is web-fs-auth._collectModelFiles at line 138), AT OR 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(frontend): 锐评三修——菊花interval脱文档自清守卫 / bench总计标签契约化常量 / 可导入判定+repo时刻读下沉utils,消backend→features依赖倒挂”; “fix: code_review backend 三连修复——hydrate 代际守卫 / 头像成功才去重 + 限流 / FSA 上限位置 + 本地化”; “fix(backend): pre-push vitest 12 失败全清——Proxy 方案回撤+FSA 过滤+测试适配单事务”; “fix(backend): P2a 安全+性能加固(FSA 递归深度/头像并行化)”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/backend/web-fs-auth.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: scripts/probe-water-wave.ts scripts/probe-water-wave.ts:410— scripts/probe-water-wave.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 13 (its worst body is probe-water-wave.main at line 410), AT OR 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(3d/water): 第二轮回归修复——film alpha 解耦(不再读 opacity)+ 倒影 alpha 门 + 迁移判据容未来版本 + hint 仅钳制时显示 + 探针补 Σσk 域宽扫描”; “fix(3d/water): 波陡基准反归一(P1-1)+ 旧档水位迁移版本戳(P1-4)+ 探针水平位移指标与同源守卫”; “fix(3d/water): 静水态 NaN 退化门 + 波场守卫数值化(锐评 P0-1/P1-3)+ 文档订正”; “fix(3d): ADR-319 D1 落地后复核——浪高钳制按形态分派(film 无上钳),旧 pool 存档兜底取中池位”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/probe-water-wave.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: frontend/src/utils/resource/importable.ts frontend/src/utils/resource/importable.ts:23— frontend/src/utils/resource/importable.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 importable.isImportableFile at line 23), AT OR 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(utils): 第二轮清理 — 依赖治理 + 死代码 + 测试补全”; “fix: 六轮修复5项——schema/molang工厂测试+getExt统一+JSDoc+dbg测试”; “fix: 四轮修复4项——with-cached LRU+molang移除全局scope+css-hmr WeakMap+importable补测试”; “fix: 二轮修复9项(molang单例+热路径分配+getExt收敛+tooltip幽灵+补测试+类型声明)”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/utils/resource/importable.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: frontend/src/backend/app.ts frontend/src/backend/app.ts:22— frontend/src/backend/app.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 8 (its worst body is app.getApp at line 22), AT OR 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(backend): pre-push vitest 12 失败全清——Proxy 方案回撤+FSA 过滤+测试适配单事务”; “fix(backend): P1 性能+安全加固(bedrock 索引/rekey 复用/单事务/LRU/Proxy 包装)”; “fix: code_review 53e59e02 + 8988145d 修复——idb 投影字段对齐 / partial-mock .every / 双注册去重与所有权注销”; “fix(backend): backend 锐评修复 P0-1/R1/R2/P1-x(共9项)”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/backend/app.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: frontend/scripts/check-binding-usage.ts frontend/scripts/check-binding-usage.ts:35— frontend/scripts/check-binding-usage.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 6 (its worst body is check-binding-usage.scanFile at line 35), AT OR 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: “frontend: biome safe-fix 清格式化债 + 排除 bindings 生成物”; “fix(锐评): 4 文件 6 项 P1/P2 修复”; “fix(check-binding-usage): Windows basename 跨平台 + 读错 fail-loud”; “fix(gate): 问题3-A binding-usage 接门禁 + 问题1-C gen-knowledge-autogen 接 gate autoFix”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/scripts/check-binding-usage.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: go/instance/status_counts.go go/instance/status_counts.go:46— go/instance/status_counts.go 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 5 (its worst body is instance.BuildInstanceStatusCounts at line 46), AT OR 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(instance): ADR-310 待推送单元双路——Missing 恒文件级(拒目录)+ MissingDirs 整夹通道,消除过度安装与静默空转”; “fix(instance): ADR-310 清单恒文件级——拒目录路径(修过度安装/必失败)+ 排序去重(修重复安装)”; “fix(instance): ADR-310 整夹缺失清单兜底——夹内无可推送文件时退回夹路径,杜绝计数有数而一键安装静默漏装”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/instance/status_counts.go`: 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: go/cli/scan_bench.go go/cli/scan_bench.go:114— go/cli/scan_bench.go 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 8 (its worst body is cli.measureScanEngine at line 114), AT OR 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): scan-bench 亚分辨率渲染成 0.00ms(违反诚实红线 2)+ 修既有 flake 的裸子串断言 + QF1002 tagged switch”; “fix(cli): 纳秒精度收口补全三残口(health/perf/scan_bench 入码 Microseconds→durationMs)+ 文本闸升级全包扫描(a128f35bc 残口收口)”; “fix(perf): scan-bench 引擎对照 Used=true 时不再被后续失败迭代覆写 Reason”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/cli/scan_bench.go`: 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: scripts/_lib/gate-ctx.ts scripts/_lib/gate-ctx.ts:179— scripts/_lib/gate-ctx.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 6 (its worst body is gate-ctx.createGateCtx.record at line 179), AT OR 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(gate): gofmtCheck 数组化 + sh 升格禁入不变式(锐评 P1 收尾)”; “fix(gate): shAsync 输出上限改滚动尾部保留,契约测试断言计数 10→9”; “fix(gates): code_review 276f17054——gate-ctx blocked 活值 getter + resolveChanges 双副本收敛”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- scripts/_lib/gate-ctx.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: frontend/src/utils/dom/trap-focus-across-shadow.ts frontend/src/utils/dom/trap-focus-across-shadow.ts:72— frontend/src/utils/dom/trap-focus-across-shadow.ts changed 4 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 15 (its worst body is trap-focus-across-shadow.trapFocusAcrossShadow at line 72), AT OR 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(a11y): 全屏放大预览补焦点陷阱——aria-modal 声明了模态却只做「焦点移入+归还」,Tab 逃到背后页面(同 site/events P0-3 的漏网第三处);同时给 trapFocusAcrossShadow 补空 tabbable 降级(空 tabbable 模态一律无陷阱),close 必释放单例槽位”; “fix(community): 修复创作者频道预设 q 丢失/键盘导航失效/收藏排序与筛选粘滞”; “fix(caps,dom,anim): code_review 中危组——tint 卸载回归 + tabbable 缓存过期 + 假 O(1) 更正”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/utils/dom/trap-focus-across-shadow.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: frontend/src/views/app-preview/card-shell.ts frontend/src/views/app-preview/card-shell.ts:37— frontend/src/views/app-preview/card-shell.ts changed 4 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 5 (its worst body is card-shell.showCard at line 37), AT OR 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(i18n): 切片 B-2 12 处 overlay safeErrorMessage → friendlyError + fbx 保留 Code(ADR-331 §2.3)”; “fix(security): R8 补 innerHTML 模板插值卫生闸,新增图标三态字符串出口 renderIconHtml,29 处破口归零”; “fix(ui): 图标位 emoji→SVG 收口 + 修闸的两处静默失明”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/views/app-preview/card-shell.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: go/cli/cli_scan_dir.go go/cli/cli_scan_dir.go:142— go/cli/cli_scan_dir.go changed 4 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 6 (its worst body is cli.printScanDirReport at line 142), AT OR 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(regression): 复核修正三项——CLI flag 注册回迁命令文件(恢复 docs/completions 选项表)、sky-patch 声明层改动计入 needsUpdate、ccheck --help 退出码 0”; “fix(tech-debt): 清偿三项存量债——cmd/ccheck 覆盖率 0%→83.9%、sky-patch 复杂度归零、Go 5 处 jscpd 重复对治理”; “fix: 收敛两条 ADR 红线债(H2 错误分类单源 + H3 WalkDir 失败可见)”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/cli/cli_scan_dir.go`: 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: go/launcher/detect.go go/launcher/detect.go:276— go/launcher/detect.go changed 4 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 13 (its worst body is launcher.legacyHMCLRunningDirectory at line 276), AT OR 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: 收敛两条 ADR 红线债(H2 错误分类单源 + H3 WalkDir 失败可见)”; “ fix(frontend): 修复 ADR-138 上提 preview-3d 后 e2e/单测相对 mock 路径错位”; “fix: close launcher JSON traversal block”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/launcher/detect.go`: 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: go/cli/recycle.go go/cli/recycle.go:15— go/cli/recycle.go changed 4 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 5 (its worst body is cli.runRecycle at line 15), AT OR 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(errcheck): 清理 go/cli/container/download/importer/litematic/recycle/scanner/sync/watcher 生产 errcheck 命中”; “fix(repo): 仓库页对接锐评收口①②③⑦——loader seam 补 HasTags 透传(tag-dot 标记复活,Go 白算/渲染白写断点接通)+ oldest tab 感知性绑定(隐藏面板类型切换只记脏账不触发全库 SHA256 体检,onShow 补渲染;RepoHealthAudit 失败统计条降级不杀主列表)+ EmptyRecycleBin 死参数退役(GUI/CLI 同步、绑定再生)+ RestoreFromRecycle 前端传真根(原恒空串让 Go 兜底沦为 CWD 相对死分支)+ friendlyError 三处漏网(oldest catch/dedup exec 失败缘由行/dirRecycle reason)”; “fix(cli): 修 review P2:空标签拦截 + ListByTag 吞错 + 中文截断”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- go/cli/recycle.go`: 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: frontend/src/utils/dom/css-hmr.ts frontend/src/utils/dom/css-hmr.ts:25— frontend/src/utils/dom/css-hmr.ts changed 4 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 4 (its worst body is css-hmr.refreshAdoptedStyleSheets at line 25), AT OR 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: 五轮修复2项——molang弱断言补强+css-hmr注释修正”; “fix: 四轮修复4项——with-cached LRU+molang移除全局scope+css-hmr WeakMap+importable补测试”; “fix: 修复 utils 层 12 项锐评问题(P0/P1/P2)”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- frontend/src/utils/dom/css-hmr.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: internal/app/app_tags.go internal/app/app_tags.go:10— internal/app/app_tags.go changed 3 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 2 (its worst body is App.getTagsStore at line 10), AT OR 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(app): 9 处路径守卫拒绝改返回结构化 AppError{INVALID_PATH}(3D 债务 D4)”; “fix: 修复 internal/app 4 个严重问题”; “fix: 第八轮三路并行审核——P0×3 路径守卫 + P1×8 资源泄漏 + P2×15 双轨漂移”. 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-27..2026-10-25, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-07-27 13:16:18 +08:00' --until='2026-10-25 13:16:18 +08:00' --full-history --no-merges -- internal/app/app_tags.go`: 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.
Cross-slice coupling: community → repo frontend/src/features/community/download-queue.ts:323— `cmDqEnqueue` (slice 'community') depends on `currentRepoType` from slice 'repo'.
Cross-slice coupling: context-menu → dialogs frontend/src/features/context-menu/context-menu-file-handlers.ts:21— `FileDialogDeps` (slice 'context-menu') depends on `RenameTpl` from slice 'dialogs'.
Cross-slice coupling: context-menu → dialogs frontend/src/features/context-menu/context-menu-file-handlers.ts:22— `FileDialogDeps` (slice 'context-menu') depends on `TagEditorTpl` from slice 'dialogs'.
Cross-slice coupling: context-menu → dialogs frontend/src/features/context-menu/context-menu-file-handlers.ts:56— `FILE_HANDLERS` (slice 'context-menu') depends on `showRenameDialog` from slice 'dialogs'.
Cross-slice coupling: context-menu → dialogs frontend/src/features/context-menu/context-menu-file-handlers.ts:124— `FILE_HANDLERS` (slice 'context-menu') depends on `modalTagEditor` from slice 'dialogs'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/import-dnd.ts:99— `importViaWebPlatform` (slice 'dnd') depends on `importWebFilesWithToast` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/import-dnd.ts:105— `buildResultParts` (slice 'dnd') depends on `ImportBatchResult` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/import-dnd.ts:171— `handleTreeDrop` (slice 'dnd') depends on `CollectedEntry` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/import-dnd.ts:171— `handleTreeDrop` (slice 'dnd') depends on `collectDropFiles` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/import-dnd.ts:179— `handleTreeDrop` (slice 'dnd') depends on `dropOversized` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/import-dnd.ts:187— `handleTreeDrop` (slice 'dnd') depends on `executeCollected` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/pack-dnd.ts:33— `Grouped` (slice 'dnd') depends on `groupCollected` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/pack-dnd.ts:76— `pushFolderGroups` (slice 'dnd') depends on `buildFolderItems` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/pack-dnd.ts:106— `pushSingleFiles` (slice 'dnd') depends on `fileToBase64` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/pack-dnd.ts:188— `handleInstanceDrop` (slice 'dnd') depends on `CollectedEntry` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/pack-dnd.ts:188— `handleInstanceDrop` (slice 'dnd') depends on `collectDropFiles` from slice 'import'.
Cross-slice coupling: dnd → import frontend/src/features/dnd/pack-dnd.ts:197— `handleInstanceDrop` (slice 'dnd') depends on `dropOversized` from slice 'import'.
Cross-slice coupling: import → repo frontend/src/features/import/executor.ts:265— `importWebBatch` (slice 'import') depends on `currentRepoType` from slice 'repo'.
Cross-slice coupling: maintenance → repo frontend/src/features/maintenance/oldest-models.ts:219— `loadOldestModel` (slice 'maintenance') depends on `useCurrentResourceType` from slice 'repo'.
Cross-slice coupling: maintenance → repo frontend/src/features/maintenance/recycle-bin.ts:342— `initRecycleBin` (slice 'maintenance') depends on `useCurrentResourceType` from slice 'repo'.
X3 · Exception handling· Discarded error (assigned to `_`, then its result used) · ×20
Discarded error (assigned to `_`, then its result used) internal/app/app.go:247— `ysmRoot, _ := a.GetRepoRoot("ysm")` writes the call's error to `_` and then uses `ysmRoot` as if the call succeeded. When `a.GetRepoRoot` fails, `ysmRoot` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `ysmRoot` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_config.go:86— `exe, _ := os.Executable()` writes the call's error to `_` and then uses `exe` as if the call succeeded. When `os.Executable` fails, `exe` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `exe` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_files.go:266— `root, _ := a.GetRepoRoot(rtype)` writes the call's error to `_` and then uses `root` as if the call succeeded. When `a.GetRepoRoot` fails, `root` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `root` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_import.go:85— `root, _ := a.GetRepoRoot(rtype)` writes the call's error to `_` and then uses `root` as if the call succeeded. When `a.GetRepoRoot` fails, `root` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `root` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_import.go:150— `dir, _ := a.GetRepoRoot(rtype)` writes the call's error to `_` and then uses `dir` as if the call succeeded. When `a.GetRepoRoot` fails, `dir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `dir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_import.go:162— `root, _ := a.GetRepoRoot("ysm")` writes the call's error to `_` and then uses `root` as if the call succeeded. When `a.GetRepoRoot` fails, `root` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `root` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_import.go:277— `root, _ := a.GetRepoRoot(rtype)` writes the call's error to `_` and then uses `root` as if the call succeeded. When `a.GetRepoRoot` fails, `root` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `root` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_import.go:306— `globalDir, _ := a.filesRootForSync(rtype)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.filesRootForSync` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:60— `filesRoot, _ := a.GetRepoRoot(d.RType)` writes the call's error to `_` and then uses `filesRoot` as if the call succeeded. When `a.GetRepoRoot` fails, `filesRoot` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `filesRoot` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:111— `filesRoot, _ := a.GetRepoRoot(d.RType)` writes the call's error to `_` and then uses `filesRoot` as if the call succeeded. When `a.GetRepoRoot` fails, `filesRoot` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `filesRoot` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:291— `globalDir, _ := a.GetRepoRoot(d.RType)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.GetRepoRoot` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:348— `globalDir, _ := a.GetRepoRoot(d.RType)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.GetRepoRoot` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:379— `globalDir, _ := a.filesRootForSync(rtype)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.filesRootForSync` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:416— `globalDir, _ := a.filesRootForSync(rtype)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.filesRootForSync` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:443— `globalDir, _ := a.filesRootForSync(rtype)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.filesRootForSync` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:484— `globalDir, _ := a.filesRootForSync(rtype)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.filesRootForSync` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:505— `globalDir, _ := a.filesRootForSync(rtype)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.filesRootForSync` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_install_instance.go:558— `globalDir, _ := a.filesRootForSync(rtype)` writes the call's error to `_` and then uses `globalDir` as if the call succeeded. When `a.filesRootForSync` fails, `globalDir` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `globalDir` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_scan.go:626— `ysm, _ := a.GetRepoRoot("ysm")` writes the call's error to `_` and then uses `ysm` as if the call succeeded. When `a.GetRepoRoot` fails, `ysm` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `ysm` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Discarded error (assigned to `_`, then its result used) internal/app/app_workshop.go:49— `exe, _ := os.Executable()` writes the call's error to `_` and then uses `exe` as if the call succeeded. When `os.Executable` fails, `exe` is its zero value (nil for a pointer, a map or an interface), so the program panics later or goes on with a default it never chose, and nothing records why. Check the error before using `exe` (return it, wrapped with what was being done), or, if the failure genuinely cannot matter, say why in a comment on the line.
Swallowed exception (caught, then discarded) internal/app/app_config.go:462— `if err != nil` 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) internal/app/app_config.go:657— `if err != nil` 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) internal/app/app_config.go:693— `if err != nil` 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) internal/app/app_config_windows.go:63— `if _, err := os.Stat(base); err != nil` 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) internal/app/app_container_cache.go:51— `if err != nil` 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) internal/app/app_files.go:149— `if err != nil` 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) internal/app/app_files.go:153— `if err != nil` 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) internal/app/app_files.go:161— `if err != nil` 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) internal/app/app_files.go:172— `if err != nil` 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) internal/app/app_install_import.go:59— `if err := paths.IsInside(rootClean, srcClean); err != nil` 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) internal/app/app_install_import.go:127— `if err != nil` 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) internal/app/app_install_recycle.go:95— `if err != nil` 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) internal/app/app_install_recycle.go:246— `if err != nil` 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) internal/app/app_model.go:71— `if err != nil` 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) internal/app/app_model.go:99— `if err != nil` 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) internal/app/app_scan.go:682— `if err != nil` 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) internal/app/app_workshop.go:162— `if err := loadBundledJSON(" ", &list); err != nil` 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) internal/app/app_workshop.go:258— `if err := loadBundledJSON(" ", &list); err != nil` 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) internal/app/pathmgr_android.go:28— `if err != nil` 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) internal/app/pathmgr_android.go:85— `if err := os.MkdirAll(dir, fsutil.DirPerms); err != nil` 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.
R4 · Test Coverage· No test reaches this file · ×14
No test reaches this file frontend/harness/main.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 frontend/harness/shot.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 artifacts/ground-design-probe/render-tiles.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 artifacts/ground-design-probe/mock-3d.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 frontend/src/preview-3d/adapters/mmd/mmd-pmx-parser.worker.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 artifacts/migrate-quick-groups.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 frontend/scripts/check-binding-usage.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 go/wasispike/probe.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 frontend/src/preview-3d/adapters/fbx/fbx-parser.worker.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 artifacts/cleanup-creators-mojibake.cjs: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 artifacts/audit-env-s13/probe2.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 artifacts/rename-knowledge-cards.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 artifacts/audit-env-s13/probe.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 artifacts/e2e-probe.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.
Change coupling: init-workshop.ts ↔ state.ts frontend/src/views/app-content/init-workshop.ts:1— `frontend/src/views/app-content/init-workshop.ts` and `frontend/src/views/app-content/state.ts` change together 77% of the time (10 of the 13 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 between them. They sit in the same directory, but in this ecosystem each file is its own module — a sibling reference still needs an import — so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise the coupling is hidden and worth breaking. You can check this without leaving the row: of the 10 shared commits counted here, the most recent 3 are `7c6f3473` refactor(app-content): 锐评手术 P1—拆除 showRepoModels 死链三重(god 信封死字段 + ini…; `4d707a25` refactor(community): avatarCache 上收 creator-avatar-store + 订阅桶改收工厂堵孤儿…; `249d15f0` docs+test(app-content): 修正 ADR 编号/行号漂移,补页作用域实例换新与早退用例 — run `git show` on any of them.
Change coupling: core.ts ↔ roles-views.ts frontend/src/preview-3d/menu/engine/core.ts:1— `frontend/src/preview-3d/menu/engine/core.ts` and `frontend/src/preview-3d/menu/panels/roles-views.ts` change together 73% of the time (8 of the 11 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 8 shared commits counted here, the most recent 3 are `c3b6dbb5` fix(i18n): 切片 B-2 12 处 overlay safeErrorMessage → friendlyError + fbx…; `a0630ba8` refactor(menu): ADR-302 走法丙续刀——剩余 5 处生产侧单节点工厂接入 NodeFor(panelNodeToRo…; `4cb68fad` refactor(design-tokens): 内容间距组合档续建——--sp-vh-hdr(6px 12px)/--sp-vh-car… — run `git show` on any of them.
Change coupling: core.ts ↔ roles.ts frontend/src/preview-3d/menu/engine/core.ts:1— `frontend/src/preview-3d/menu/engine/core.ts` and `frontend/src/preview-3d/menu/panels/roles.ts` change together 67% of the time (14 of the 21 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 14 shared commits counted here, the most recent 3 are `474709f2` refactor(i18n): tOf() 内置多级回退,tr/trDynamic 标记 deprecated (at that commit the files were still `frontend/src/preview-3d/menu/core.ts` and `frontend/src/preview-3d/menu/roles.ts`); `0c4b9e90` refactor(preview-3d/menu): renderMenu 分派穷举化 + roles DOM 半身迁出 roles-views (at that commit the files were still `frontend/src/preview-3d/menu/core.ts` and `frontend/src/preview-3d/menu/roles.ts`); `ddb61cbd` 设机位;此处显式设位,避免 shared 相机单例残留位/原点贴地) (at that commit the files were still `frontend/src/preview-3d/menu/core.ts` and `frontend/src/preview-3d/menu/roles.ts`) — run `git show` on any of them.
Change coupling: light-capability.ts ↔ screenshot-lights.ts frontend/src/preview-3d/caps/light-capability.ts:1— `frontend/src/preview-3d/caps/light-capability.ts` and `frontend/src/preview-3d/screenshot/screenshot-lights.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 — 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 `daed7ed0` fix(preview-3d): 环境域锐评收口 P0/P1-1——IBL 让位判据单一事实源 + isStateLoaded 跨会话复位; `158a19bb` refactor(3d/light): S2/S3 潜伏雷收口 + 灯光纯函数下沉 light-math.ts; `3bfc7381` refactor(3d/light): light-presets.ts → light-params.ts——文件名停止撒谎(零 pre… — run `git show` on any of them.
Change coupling: perf-concurrent.ts ↔ perf-scan-bench.ts frontend/src/views/app-content/diagnostics/perf-concurrent.ts:1— `frontend/src/views/app-content/diagnostics/perf-concurrent.ts` and `frontend/src/views/app-content/diagnostics/perf-scan-bench.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 — 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 between them. They sit in the same directory, but in this ecosystem each file is its own module — a sibling reference still needs an import — so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise 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 `04c68489` refactor(diagnostics): ADR-278-d1 bench控件门禁派生化——read*声明读集,PERF_UNREAD…; `47985ab5` refactor(diagnostics): ADR-332 land D1/D3/D4 (D2 kept distinct per user); `4ca3d2b6` fix(cli): 信封耗时改用纳秒精度 + 三个性能区段展示命令耗时(附字段级零读取审计脚本) — run `git show` on any of them.
Change coupling: perf.ts ↔ tpl.ts frontend/src/views/app-content/diagnostics/perf.ts:1— `frontend/src/views/app-content/diagnostics/perf.ts` and `frontend/src/views/app-content/tpl.ts` change together 63% of the time (19 of the 30 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 19 shared commits counted here, the most recent 3 are `010c4279` feat(diagnostics): 阶段→加载剖析下钻——CLI 基准跳同一模型前端实测; `d5c20ede` feat(diagnostics): 基准三件套默认收起——参数密度开关(简版/进阶)+ 收起即失效; `966d6fa8` refactor(diagnostics): 版面词典收口——三 tab 统一布局词汇,修 pill 对齐与常驻栏滚走 — run `git show` on any of them.
Change coupling: light-controls.ts ↔ light-persist.ts frontend/src/preview-3d/caps/light-controls.ts:1— `frontend/src/preview-3d/caps/light-controls.ts` and `frontend/src/preview-3d/caps/light-persist.ts` change together 58% of the time (11 of the 19 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 between them. They sit in the same directory, but in this ecosystem each file is its own module — a sibling reference still needs an import — so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise the coupling is hidden and worth breaking. You can check this without leaving the row: of the 11 shared commits counted here, the most recent 3 are `158a19bb` refactor(3d/light): S2/S3 潜伏雷收口 + 灯光纯函数下沉 light-math.ts; `3bfc7381` refactor(3d/light): light-presets.ts → light-params.ts——文件名停止撒谎(零 pre…; `4389c5cc` fix: 灯光首启默认分治——辅助线框关、fill/rim 关、环境光降档 — run `git show` on any of them.
Change coupling: contract-tests.ts ↔ gate-coverage.ts scripts/_lib/contract-tests.ts:1— `scripts/_lib/contract-tests.ts` and `scripts/_lib/gate-coverage.ts` change together 57% of the time (8 of the 14 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 between them. They sit in the same directory, but in this ecosystem each file is its own module — a sibling reference still needs an import — so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise the coupling is hidden and worth breaking. You can check this without leaving the row: of the 8 shared commits counted here, the most recent 3 are `764e013e` test(preview-3d): 补 G1/G2/G4 三闸——rAF 契约 + Worker 生命周期闸 + 会话复位等价(锐评 §五); `cfac9ee9` feat(scripts): 新增 preview-3d 模块级单例卫生闸 check-singleton-hygiene; `afc5dd6d` feat(scripts): P2② 补网——改动范围同构同胞提醒探针 check-twin-siblings(W7 候选清单 WARN … — run `git show` on any of them.
Change coupling: vmd-retarget.ts ↔ vrm-adapter.ts frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts:1— `frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts` and `frontend/src/preview-3d/adapters/vrm/vrm-adapter.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 — 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 between them. They sit in the same directory, but in this ecosystem each file is its own module — a sibling reference still needs an import — so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise 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 `ec872a36` chore(deadcode): 清死代码基线门禁 16 条新增债——15 个零消费者符号 un-export(BatchCtx/Inst…; `51508c7c` feat(vrm): ADR-309 P2/P4/P6 播放语义收口(lookAt 让道 / IK 开关时间轴 / 库动作不自动播); `f25d27de` refactor: VRM 播 VMD 锐评 P3/P5 架构——自动缩放创建期快照 + 原地 rescale 替代整库重读 + 加载代际守卫 — run `git show` on any of them.
Change coupling: light-capability.ts ↔ model-defaults.ts frontend/src/preview-3d/caps/light-capability.ts:1— `frontend/src/preview-3d/caps/light-capability.ts` and `frontend/src/preview-3d/state/model-defaults.ts` change together 50% of the time (6 of the 12 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 `84d643f5` refactor(preview-3d): 灯光与模型类别解耦——退役 applyModelPreset,重置锚定 DEFAULT_LIG…; `6ccc9d9c` feat(preview-3d): 三灯统一实例——key/fill/rim 各可切 directional/point/spot(ADR…; `75d5903c` refactor: preview-3d 契约一致性收口——light/reflector 迁 pickModelDefaultField… — run `git show` on any of them.
Change coupling: mount-preview-core.ts ↔ render-budget.ts frontend/src/preview-3d/adapters/mount-preview-core.ts:1— `frontend/src/preview-3d/adapters/mount-preview-core.ts` and `frontend/src/preview-3d/infra/render-budget.ts` change together 50% of the time (6 of the 12 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 `36de2dd9` fix(preview-3d): 审查闭环——直挂门补覆盖+语义前置、标定 clamp 自锁防线、mip 口径、有界去重; `e3886d25` feat(preview-3d): GPU 预算补全 4 维 + 直挂门 + 饱和反压 + 真机标定 + 大文件警示; `baf3dfb8` fix(3d): FPS cap 与自适应降级解耦 + getMaxFps 缓存 + 死 import 清理(code review) (at that commit the files were still `frontend/src/utils/3d/adapters/mount-preview-core.ts` and `frontend/src/utils/3d/render-budget.ts`) — run `git show` on any of them.
Change coupling: animation-controller.ts ↔ REDACTED frontend/src/utils/animation/animation-controller.ts:1— `frontend/src/utils/animation/animation-controller.ts` and `REDACTED` change together 50% of the time (5 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 between them. They sit in the same directory, but in this ecosystem each file is its own module — a sibling reference still needs an import — so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise the coupling is hidden and worth breaking. You can check this without leaving the row: of the 5 shared commits counted here, the most recent 3 are `865134ba` refactor(animation): 删双胞胎烟雾测试+currentAnimIndex 死代码+拆 parseAnimationCo…; `b6a85ec9` fix: 七轮修复5项——focus-restore栈上限+executeTimeline回绕+状态机校验+缓存优化; `344d2a78` fix: 三轮修复8项——静默catch补日志+tooltip标记复位 — run `git show` on any of them.
Change coupling: tpl-recycle.ts ↔ tpl.ts frontend/src/views/app-content/tpl-recycle.ts:1— `frontend/src/views/app-content/tpl-recycle.ts` and `frontend/src/views/app-content/tpl.ts` change together 50% of the time (5 of the 10 commits that touched whichever of the two files changed less often, counting a file under its earlier names as well — 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 between them. They sit in the same directory, but in this ecosystem each file is its own module — a sibling reference still needs an import — so the missing import edge is real: the coupling runs through shared behaviour, not a declared dependency. If they duplicate structure, extract the common part into one unit; otherwise the coupling is hidden and worth breaking. You can check this without leaving the row: of the 5 shared commits counted here, the most recent 3 are `a1d613a6` refactor(repo): 清两条 P2 死债——.recy-page 删重复内联 style 归 css 单点 + content-…; `e99b5a62` test: 补 8 处 diag/recy 元素 testid 钩子,e2e 迁 testid 定位通道; `85a9545b` refactor(css-token): 黄区 23 条全数收口——令牌化 14 + 语义登记 6 + 零值误报闸修,基线 416→346 — run `git show` on any of them.
TooManyMethods: App internal/app/app.go:43— TooManyMethods — 265 methods, declared across 29 files: app/app_scan.go (26), app/app_files.go (24), app/resource_bindings.go (24), app/app_config.go (21), +25 more file(s). The bar is 30 methods; this is 235 over it, 8.83× the bar. That list is where to read them, not a suggestion to split the file: the members belong to the type wherever they are declared, so moving them between files leaves the count unchanged. 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: GroundCapability frontend/src/preview-3d/caps/ground-capability.ts:123— TooManyMethods — 74 methods. The bar is 30 methods; this is 44 over it, 2.47× 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: WaterCapability frontend/src/preview-3d/caps/water-capability.ts:86— TooManyMethods — 69 methods. The bar is 30 methods; this is 39 over it, 2.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: SkyCapability frontend/src/preview-3d/caps/sky-capability.ts:77— TooManyMethods — 47 methods. The bar is 30 methods; this is 17 over it, 1.57× 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: PostprocessingCapability frontend/src/preview-3d/caps/postprocessing-capability.ts:73— TooManyMethods — 40 methods. The bar is 30 methods; this is 10 over it, 1.33× 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: ShadowCapability frontend/src/preview-3d/caps/shadow-capability.ts:39— TooManyMethods — 37 methods. The bar is 30 methods; this is 7 over it, 1.23× 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: EnvironmentCapability frontend/src/preview-3d/caps/environment-capability.ts:123— TooManyMethods — 32 methods. The bar is 30 methods; this is 2 over it, 1.07× 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: LightCapability frontend/src/preview-3d/caps/light-capability.ts:240— TooManyMethods — 32 methods. The bar is 30 methods; this is 2 over it, 1.07× 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: Easings frontend/src/utils/animation/molang-lib/easing.js:3— TooManyMethods — 31 methods. The bar is 30 methods; this is 1 over it, 1.03× 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.
Fake-async — async method never awaits frontend/scripts/check-binding-usage.ts:83— `main` 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 frontend/src/backend/runtime.ts:30— `Emit` 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 frontend/src/backend/web-fs.ts:421— `SaveScreenshotFile` 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 frontend/src/preview-3d/adapters/mmd/mmd-build-load.ts:398— `Stage2LoadingManager` 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 frontend/src/preview-3d/adapters/mmd/mmd-build-scene.ts:234— `Stage3Ktx2Schedule` 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 frontend/src/preview-3d/adapters/mmd/mmd-shared.ts:24— `disposeMmdMesh` 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 frontend/src/views/app-content/diagnostics/perf-matrix-render.ts:347— `populatePerfTargetOptions` 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 frontend/src/views/app-preview/detail.ts:294— `showSimplePreview` 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 frontend/src/views/app-preview/zoom.ts:24— `openFullPreview` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
FunctionTooLong: molang.Molang frontend/src/utils/animation/molang-lib/molang.js:11— FunctionTooLong — Molang runs 476 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 376 over it, 4.76× 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: dedup.createDedupSession frontend/src/views/app-content/diagnostics/dedup.ts:170— FunctionTooLong — createDedupSession 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: water-menu.buildWaterNodes frontend/src/preview-3d/caps/water-menu.ts:86— FunctionTooLong — buildWaterNodes runs 163 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 63 over it, 1.63× 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: context-menu-handlers.createContextMenuHandlers frontend/src/features/context-menu/context-menu-handlers.ts:93— FunctionTooLong — createContextMenuHandlers runs 148 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 48 over it, 1.48× 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: water-shader.assembleWaveShader.<returned closure> frontend/src/preview-3d/caps/water-shader.ts:48— FunctionTooLong — assembleWaveShader.<returned closure> runs 140 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 40 over it, 1.40× 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: repoaudit.AuditCtx go/repoaudit/repoaudit.go:200— FunctionTooLong — AuditCtx runs 117 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 17 over it, 1.17× 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: skeleton.loadModel2D frontend/src/views/app-preview/skeleton.ts:46— FunctionTooLong — loadModel2D 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.
FunctionTooLong: mount-preview-core.buildInfra frontend/src/preview-3d/adapters/mount-preview-core.ts:498— FunctionTooLong — buildInfra runs 105 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 5 over it, 1.05× 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.
D10 · Test Quality· Fixed-sleep synchronisation · ×7
Fixed-sleep synchronisation: 乐观即时反馈 + 可见进度:IPC 挂起期条目已翻、进度已显示,结束隐藏 frontend/src/views/app-tree/bus-handlers.test.ts:354— This test starts work it did not wait for (`done`, still running when the sleep starts) and then orders itself against it with `new Promise((r) => setTimeout(r, 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.
Fixed-sleep synchronisation: 同一文件并发在途 → 第二次命中 busy toast,不重复调后端,结束后在途释放 frontend/src/features/import/executor.test.ts:237— This test starts work it did not wait for (`p1`, still running when the sleep starts) and then orders itself against it with `new Promise((r) => setTimeout(r, 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.
Fixed-sleep synchronisation: 文件夹在途重复提交 → busy toast 拦截,不重复调后端 frontend/src/features/import/executor.test.ts:321— This test starts work it did not wait for (`p1`, still running when the sleep starts) and then orders itself against it with `new Promise((r) => setTimeout(r, 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.
Fixed-sleep synchronisation: 两个会话的 inFlight 互不干扰:会话 A 在途文件不被会话 B busy 拦截 frontend/src/features/import/executor.test.ts:419— This test starts work it did not wait for (`pA`, still running when the sleep starts) and then orders itself against it with `new Promise((r) => setTimeout(r, 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.
Fixed-sleep synchronisation: 同一会话内同文件并发 → busy 拦截(模块级默认行为保留) frontend/src/features/import/executor.test.ts:439— This test starts work it did not wait for (`p1`, still running when the sleep starts) and then orders itself against it with `new Promise((r) => setTimeout(r, 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.
Fixed-sleep synchronisation: save 时已 disposed → getApp 后早退,不写回 frontend/src/features/dialogs/tag-editor.test.ts:164— This test starts work it did not wait for (`pending`, still running when the sleep starts) and then orders itself against it with `new Promise((r) => setTimeout(r, 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.
Fixed-sleep synchronisation: deps.getApp 替代模块 mock 的生产实现,无需 vi.mock backend frontend/src/features/dialogs/tag-editor.test.ts:207— This test starts work it did not wait for (`pending`, still running when the sleep starts) and then orders itself against it with `new Promise((r) => setTimeout(r, 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.
Boundary violation [package:relative-cross-package] artifacts/ground-design-probe/render-tiles.mjs:19— artifacts/ground-design-probe/render-tiles.mjs:19 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/plain.ts) — import the package by name instead.
Boundary violation [package:relative-cross-package] artifacts/ground-design-probe/render-tiles.mjs:20— artifacts/ground-design-probe/render-tiles.mjs:20 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/marble.ts) — import the package by name instead.
Boundary violation [package:relative-cross-package] artifacts/ground-design-probe/render-tiles.mjs:21— artifacts/ground-design-probe/render-tiles.mjs:21 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/sand.ts) — import the package by name instead.
Boundary violation [package:relative-cross-package] artifacts/ground-design-probe/render-tiles.mjs:22— artifacts/ground-design-probe/render-tiles.mjs:22 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/grass.ts) — import the package by name instead.
Boundary violation [package:relative-cross-package] artifacts/ground-design-probe/render-tiles.mjs:23— artifacts/ground-design-probe/render-tiles.mjs:23 reaches into another package with a relative path (../../frontend/src/preview-3d/caps/surface-pixels/noise.ts) — import the package by name instead.
Boundary violation [package:test-suite-dependency] frontend/harness/mock-install.ts:5— frontend/harness/mock-install.ts:5 imports frontend/e2e/mock-data.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:test-suite-dependency] frontend/harness/shot.mjs:22— frontend/harness/shot.mjs:22 imports frontend/e2e-web/png-color-count.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.
TodoComment tests/test_adr_lingering_progress.ts:8— // 背景:原 PROGRESS_RE(进度|排期|化石|待办|TODO|未落地|仍在进行|尚未完成|下一步|后续|计划)把 — 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 tests/test_new_knowledge_card.ts:57— // ── 2. 模板不含 TODO 占位锚 ──────────────────────────── — 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-redlines.ts:583— // W3 empty JSDoc / W4 TODO no ticket 已移交 comment-checker.ts(扫描范围更全, — 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 frontend/test-setup.ts:158— // TODO(upstream): 移除条件——molangjs 修正 package.json exports(.cjs 正确标 CJS)或 — 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 frontend/src/views/app-content/site/workshop-site-opener.ts:156— // 导入改了磁盘上的站点配置 → 重载 tab 栏与创作者列表(旧 TODO 清偿)。 — 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 frontend/src/views/app-content/site/workshop-tabs.ts:226— // 导出重载入口给 init-workshop 注入 bindSiteEvents(站点导入成功后刷新列表,清旧 TODO) — 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.
FileTooLong: state/env-state-schema.ts frontend/src/preview-3d/state/env-state-schema.ts— FileTooLong — 686 significant lines (blank, comment-only and punctuation-only lines excluded), about 85% of them inside a single declaration: ENV_STATE_SCHEMA (67-933). The bar is 500 significant lines; this is 186 over it, 1.37× 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: decoder/wasm-decode.ts frontend/src/preview-3d/decoder/wasm-decode.ts— FileTooLong — 626 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 126 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: parsers/ysm-header.ts frontend/src/parsers/ysm-header.ts— FileTooLong — 567 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 67 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: adapters/ysm-adapter.ts frontend/src/preview-3d/adapters/ysm-adapter.ts— FileTooLong — 558 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 58 over it, 1.12× 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: vrm/vrm-adapter.ts frontend/src/preview-3d/adapters/vrm/vrm-adapter.ts— FileTooLong — 530 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 30 over it, 1.06× 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: app-tree/index.ts frontend/src/views/app-tree/index.ts— FileTooLong — 530 significant lines (blank, comment-only and punctuation-only lines excluded), about 84% of them inside a single declaration: AppTree (117-962). The bar is 500 significant lines; this is 30 over it, 1.06× 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.
AC6 · Visual & motion safety· Animation without a prefers-reduced-motion guard · ×5
Animation without a prefers-reduced-motion guard frontend/src/preview-3d/infra/preview-loading.ts:29— <div> moves — its inline style sets `animation: preview` — and nothing reads prefers-reduced-motion for it, so a motion-sensitive user cannot turn it off (WCAG 2.3.3). Gate it on @media (prefers-reduced-motion: no-preference) or motion-safe:.
Animation without a prefers-reduced-motion guard frontend/css/components.css:57— `.dlg-box` moves (`animation: dlgBoxIn .2s cubic-bezier(.34,1.56,.64,1)`) 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 frontend/css/components.css:59— `.dlg-overlay.dlg-closing .dlg-box` moves (`animation: dlgBoxOut .12s ease forwards`) 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 frontend/css/components.css:464— `.br-row` moves (`animation: fadeSlideUp .15s ease both`) 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 frontend/css/dialogs.css:62— `.dlg-prog-fill` moves (`transition: width 0.06s linear`) 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.
D4 · Code Duplication· Edited copy of a member (14 corresponding lines) · ×5
Edited copy of a member (14 corresponding lines) internal/app/app_files.go:66— internal/app/app_files.go:66-79 | internal/app/app_files.go:95-109 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (14 corresponding lines) go/scanner/scanindex.go:125— go/scanner/scanindex.go:125-142 | go/scanner/scanindex.go:149-162 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (14 corresponding lines) go/scanner/hashindex.go:106— go/scanner/hashindex.go:106-121 | go/scanner/scanindex.go:334-347 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (14 corresponding lines) internal/app/app_scan.go:337— internal/app/app_scan.go:337-351 | internal/app/app_scan.go:359-372 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (14 corresponding lines) go/types/registry/extensions.go:320— go/types/registry/extensions.go:320-333 | go/types/registry/extensions.go:338-351 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (21 corresponding lines) · ×4
Edited copy of a member (21 corresponding lines) go/installer/installer_file.go:122— go/installer/installer_file.go:122-142 | go/installer/installer_file.go:153-179 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (21 corresponding lines) go/recycle/recycle.go:188— go/recycle/recycle.go:188-208 | go/recycle/recycle_restore.go:82-104 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (21 corresponding lines) go/cli/fileops.go:15— go/cli/fileops.go:15-35 | go/cli/fileops.go:38-58 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (21 corresponding lines) internal/app/app_install_recycle.go:148— internal/app/app_install_recycle.go:148-169 | internal/app/app_install_recycle.go:171-191 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (9 corresponding lines) · ×4
Edited copy of a member (9 corresponding lines) go/geometry/archive_components.go:232— go/geometry/archive_components.go:232-240 | go/ysm/extracted.go:303-311 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (9 corresponding lines) go/ysm/extracted.go:70— go/ysm/extracted.go:70-78 | go/ysm/extracted.go:93-101 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (9 corresponding lines) go/cli/config_cmd.go:94— go/cli/config_cmd.go:94-102 | go/cli/install.go:51-59 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (9 corresponding lines) go/cli/scan_bench.go:230— go/cli/scan_bench.go:230-242 | go/cli/bench_matrix.go:252-260 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (7 corresponding lines) · ×4
Edited copy of a member (7 corresponding lines) go/wasispike/main.go:166— go/wasispike/main.go:166-172 | go/ysmwasi/ysmwasi.go:105-111 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (7 corresponding lines) go/fileops/fileops.go:98— go/fileops/fileops.go:98-104 | go/fileops/fileops_enable.go:120-127 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (7 corresponding lines) go/avatar/avatar.go:31— go/avatar/avatar.go:31-43 | go/texture_cache/texture_cache.go:35-41 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (7 corresponding lines) go/cli/recycle.go:72— go/cli/recycle.go:72-78 | go/fsutil/format.go:54-63 — These two members are one piece of code written twice and then edited apart: 7 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Duplicated block (7 lines × 2) go/ysm/texsize.go:64— go/ysm/texsize.go:64-74 | go/ysm/texsize.go:102-108 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/ysm/texsize.go:64` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (7 lines × 2) go/cli/dedup.go:255— go/cli/dedup.go:255-261 | go/cli/resource.go:229-235 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (7 lines × 2) go/logs/logs.go:359— go/logs/logs.go:359-365 | go/logs/runtime.go:107-113 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (7 lines × 2) go/geometry/mmd/mmd_stats.go:260— go/geometry/mmd/mmd_stats.go:260-266 | go/geometry/mmd/mmd_stats.go:270-276 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/geometry/mmd/mmd_stats.go:260` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (21 lines × 2 locations) artifacts/audit-env-s13/probe.mjs:36— artifacts/audit-env-s13/probe.mjs:36 · artifacts/audit-env-s13/probe2.mjs:48 — 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.
Duplicated block (21 lines × 2 locations) frontend/src/wasm/ysm-parser.ts:193— frontend/src/wasm/ysm-parser.ts:193 · frontend/src/wasm/ysm-worker-loader.ts:263 — 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.
Duplicated block (21 lines × 2 locations) scripts/build-novel-index.ts:169— scripts/build-novel-index.ts:169 · scripts/build-novel-index.ts:194 — all 2 copies are in the same file, 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.
Duplicated block (21 lines × 2 locations) scripts/line-counter.ts:162— scripts/line-counter.ts:162 · scripts/line-counter.ts:246 — all 2 copies are in the same file, 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.
AC1 · Text alternatives· <canvas> without a text alternative · ×3
<canvas> without a text alternative frontend/src/preview-3d/menu/render/cap-controls.ts:456— A <canvas> with no aria-label/title and no inner fallback content can't be described by assistive tech. Add a name or fallback content.
<canvas> without a text alternative frontend/src/preview-3d/menu/render/cap-controls.ts:549— A <canvas> with no aria-label/title and no inner fallback content can't be described by assistive tech. Add a name or fallback content.
<canvas> without a text alternative REDACTED:28— A <canvas> with no aria-label/title and no inner fallback content can't be described by assistive tech. Add a name or fallback content.
D30 · Dependency Vulnerabilities· Medium vulnerability · ×3
REDACTED
REDACTED
REDACTED
D4 · Code Duplication· Edited copy of a member (19 corresponding lines) · ×3
Edited copy of a member (19 corresponding lines) go/scanner/hashindex.go:42— go/scanner/hashindex.go:42-62 | go/scanner/scanindex.go:79-97 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (19 corresponding lines) go/cli/creator.go:13— go/cli/creator.go:13-33 | go/cli/dedup.go:20-38 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (19 corresponding lines) internal/app/app_allowed_roots_cache.go:26— internal/app/app_allowed_roots_cache.go:26-47 | internal/app/app_resolved_root_cache.go:39-57 — These two members are one piece of code written twice and then edited apart: 19 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (17 corresponding lines) · ×3
Edited copy of a member (17 corresponding lines) internal/app/app_files.go:186— internal/app/app_files.go:186-206 | internal/app/app_files.go:209-225 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (17 corresponding lines) go/ysm/extracted.go:47— go/ysm/extracted.go:47-67 | go/ysm/extracted.go:226-242 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (17 corresponding lines) go/fileops/fileops.go:123— go/fileops/fileops.go:123-141 | go/fileops/fileops.go:168-184 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (13 corresponding lines) · ×3
Edited copy of a member (13 corresponding lines) internal/app/app_settings_export.go:162— internal/app/app_settings_export.go:162-177 | internal/app/app_settings_export.go:344-356 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (13 corresponding lines) go/download/download_downloader.go:56— go/download/download_downloader.go:56-69 | go/updater/updater_download.go:51-63 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (13 corresponding lines) go/instance/sync_items_cache.go:47— go/instance/sync_items_cache.go:47-59 | go/instance/sync_items_cache.go:82-94 — These two members are one piece of code written twice and then edited apart: 13 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Duplicated block (8 lines × 2) internal/app/app_install_instance.go:287— internal/app/app_install_instance.go:287-294 | internal/app/app_install_instance.go:344-351 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (8 lines × 2) go/internal/testutil/determinism.go:20— go/internal/testutil/determinism.go:20-27 | go/scanner/scanner_authors.go:102-109 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Check import visibility before settling on that home: `go/internal/testutil/determinism.go` sits under a restricted `internal` directory, which only code inside its own subtree is permitted to import from — so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate.
Duplicated block (8 lines × 2) go/threejs/spec-bones.go:279— go/threejs/spec-bones.go:279-286 | go/threejs/spec-bones.go:294-301 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/threejs/spec-bones.go:279` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (6 lines × 2) go/recycle/recycle_list.go:19— go/recycle/recycle_list.go:19-25 | go/recycle/recycle_list.go:69-74 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/recycle/recycle_list.go:19` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (6 lines × 2) go/updater/updater_install.go:74— go/updater/updater_install.go:74-79 | go/updater/updater_install.go:90-95 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/updater/updater_install.go:74` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (6 lines × 2) go/importer/importer_file.go:95— go/importer/importer_file.go:95-100 | internal/app/app_install_import.go:191-196 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Check import visibility before settling on that home: `internal/app/app_install_import.go` sits under a restricted `internal` directory, which only code inside its own subtree is permitted to import from — so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate.
R10 · Code Duplication· Duplicated block with local edits (33 matched lines × 2 locations) · ×3
Duplicated block with local edits (33 matched lines × 2 locations) scripts/check-orphan-exports.ts:423— scripts/check-orphan-exports.ts:423 · scripts/check-unread-fields.ts:364 — the two spans are one implementation copied and then locally edited — 156 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 (33 matched lines × 2 locations) scripts/check-singleton-hygiene.ts:52— scripts/check-singleton-hygiene.ts:52 · scripts/check-worker-lifecycle.ts:59 — the two spans are one implementation copied and then locally edited — 297 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 (33 matched lines × 2 locations) scripts/gen-knowledge-adr.ts:113— scripts/gen-knowledge-adr.ts:113 · scripts/gen-knowledge-tests.ts:129 — the two spans are one implementation copied and then locally edited — 296 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.
Complex function parseYsmAuthority (cyclomatic 47, cognitive 86) tests/port-verification/scan-non-main-uv.ts:57— parseYsmAuthority has cyclomatic complexity 47 and cognitive complexity 86; 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.
Complex function parseYsmAuthority (cyclomatic 47, cognitive 86) tests/port-verification/scan-texslot-binding.ts:39— parseYsmAuthority has cyclomatic complexity 47 and cognitive complexity 86; 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.
Complex function parseYsmAuthority (cyclomatic 47, cognitive 86) tests/port-verification/scan-texslot-overflow.ts:52— parseYsmAuthority has cyclomatic complexity 47 and cognitive complexity 86; 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.
AC3 · Page structure· Page without a main landmark · ×2
Page without a main landmark frontend/harness/index.html:5— No <main> (or role="main") means no "skip to content" target and a weaker landmark map. This document's body is only the mount point <div id="host">, so there is no content here to wrap — render the <main> from the component mounted into it.
Page without a main landmark frontend/index.html:2— No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
AC4 · Keyboard semantics· Modal dialog does not manage focus · ×2
Modal dialog does not manage focus frontend/src/preview-3d/infra/preview-shell.ts:72— This <div role="dialog"> is a modal dialog, but focus is moved into it, but nothing keeps it there: Tab walks out to the page behind, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native <dialog> opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close.
Modal dialog does not manage focus frontend/src/utils/dom/modal-core.ts:164— This <div role="dialog"> is a modal dialog, but nothing moves focus into it when it opens and nothing keeps focus inside it while it is open, so a keyboard or screen-reader user keeps acting on the content behind it (WCAG 2.4.3). Use a native <dialog> opened with showModal(), a dialog component that traps focus, or move focus to the dialog on open, trap Tab inside it (or make the page behind inert) and return focus to the control that opened it on close.
molang.Molang::iterateExp (cyclomatic 125) frontend/src/utils/animation/molang-lib/molang.js:400— molang.Molang::iterateExp has cyclomatic complexity 125 (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. This shape REPEATS in the file: one other method here (molang.Molang::iterateString) 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. This file is where this pass's cyclomatic complexity CONCENTRATES: frontend/src/utils/animation/molang-lib/molang.js holds 2 of the 87 methods over the threshold — including the worst — and 205 of the 483 points over it (42%), 9.8× the next-largest file (go/repoaudit/repoaudit.go at 21). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository.
molang.Molang::iterateString (cyclomatic 110) frontend/src/utils/animation/molang-lib/molang.js:109— molang.Molang::iterateString has cyclomatic complexity 110 (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. This shape REPEATS in the file: one other method here (molang.Molang::iterateExp) 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. This file is where this pass's cyclomatic complexity CONCENTRATES: frontend/src/utils/animation/molang-lib/molang.js holds 2 of the 87 methods over the threshold — including the worst — and 205 of the 483 points over it (42%), 9.8× the next-largest file (go/repoaudit/repoaudit.go at 21). No single row can show this, because each is measured only against the threshold: reducing this one file moves this dimension further than any other file in the repository.
molang.Molang::iterateExp (cognitive 82) frontend/src/utils/animation/molang-lib/molang.js:400— molang.Molang::iterateExp has cognitive complexity 82 (threshold 15). Drivers by points: ternaries 11 (33 pts), if/else 15 (28 pts), boolean chains 9, match/switch 4 (8 pts), loops 2 (4 pts) (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. This shape REPEATS in the file: one other method here (molang.Molang::splitStringMultiple) 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.
molang.Molang::splitStringMultiple (cognitive 19) frontend/src/utils/animation/molang-lib/molang.js:347— molang.Molang::splitStringMultiple has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (13 pts), boolean chains 3, match/switch 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. This shape REPEATS in the file: one other method here (molang.Molang::iterateExp) 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.
Molang::iterateString (cognitive 52) frontend/src/utils/animation/molang-lib/molang.js:109— Molang::iterateString has cognitive complexity 52 (threshold 15). Drivers by points: boolean chains 24, if/else 19 (24 pts), match/switch 2 (3 pts), loops 1 (nesting depth added 6). 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.
Molang::canTrimBrackets (cognitive 18) frontend/src/utils/animation/molang-lib/molang.js:282— Molang::canTrimBrackets has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (7 pts), boolean chains 3, match/switch 1 (3 pts), ternaries 1 (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.
TooManyFields: App internal/app/app.go:43— TooManyFields — 35 stored fields beside 265 methods. The bar is 30 stored fields; this is 5 over it, 1.17× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
TooManyFields: AppConfig go/types/config.go:17— TooManyFields — 33 stored fields. The bar is 30 stored fields; this is 3 over it, 1.10× the bar. This is width in DATA, not behaviour: every reader that takes the whole type couples to all of its fields, so a change to any one of them is a change every reader has to be checked against. To reduce it, group the fields that are read together by the same callers into a smaller type of their own, and have this one hold that type as a single member — each reader then names only the group it uses.
D4 · Code Duplication· Edited copy of a member (22 corresponding lines) · ×2
Edited copy of a member (22 corresponding lines) internal/app/container_entries.go:73— internal/app/container_entries.go:73-101 | internal/app/resourcepack_models.go:66-87 — These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (22 corresponding lines) go/sync/sync_dirlevel.go:51— go/sync/sync_dirlevel.go:51-77 | go/sync/sync_dirlevel.go:227-248 — These two members are one piece of code written twice and then edited apart: 22 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (18 corresponding lines) · ×2
Edited copy of a member (18 corresponding lines) internal/app/app_container_cache.go:49— internal/app/app_container_cache.go:49-66 | internal/app/app_geo_cache.go:84-109 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (18 corresponding lines) go/tags/tags.go:148— go/tags/tags.go:148-165 | go/texture_cache/texture_cache.go:97-117 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (23 corresponding lines) · ×2
Edited copy of a member (23 corresponding lines) go/avatar/avatar.go:220— go/avatar/avatar.go:220-245 | go/texture_cache/texture_cache.go:136-158 — These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (23 corresponding lines) go/geometry/ysm_parser.go:256— go/geometry/ysm_parser.go:256-280 | go/ysm/extracted.go:180-202 — These two members are one piece of code written twice and then edited apart: 23 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copies of one member (3 members, 19+ corresponding lines) · ×2
Edited copies of one member (3 members, 19+ corresponding lines) go/cli/instance.go:13— go/cli/instance.go:13-33 | go/cli/recycle.go:15-33 | go/cli/tags.go:14-36 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
Edited copies of one member (3 members, 19+ corresponding lines) go/cli/instance.go:83— go/cli/instance.go:83-101 | go/cli/instance.go:104-122 | go/cli/instance.go:125-148 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication· Edited copy of a member (12 corresponding lines) · ×2
Edited copy of a member (12 corresponding lines) REDACTED:48— REDACTED:48-61 | go/fsutil/write.go:128-139 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (12 corresponding lines) go/scanner/scanner_browse.go:49— go/scanner/scanner_browse.go:49-60 | go/scanner/scanner_scan.go:140-154 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (15 corresponding lines) · ×2
Edited copy of a member (15 corresponding lines) go/geometry/archive_collect.go:193— go/geometry/archive_collect.go:193-207 | go/ysm/extracted.go:443-459 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (15 corresponding lines) go/sync/sync_dirlevel.go:251— go/sync/sync_dirlevel.go:251-265 | go/sync/sync_discovery.go:31-45 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (8 corresponding lines) · ×2
Edited copy of a member (8 corresponding lines) go/geometry/archive.go:121— go/geometry/archive.go:121-128 | go/packs/classify.go:380-387 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (8 corresponding lines) go/fsutil/relink_backup.go:28— go/fsutil/relink_backup.go:28-35 | go/fsutil/walk.go:126-133 — These two members are one piece of code written twice and then edited apart: 8 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (6 corresponding lines) · ×2
Edited copy of a member (6 corresponding lines) internal/app/app_install_import.go:104— internal/app/app_install_import.go:104-110 | internal/app/app_install_instance.go:319-324 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (6 corresponding lines) internal/app/app_geo_cache.go:146— internal/app/app_geo_cache.go:146-151 | internal/app/app_resolved_root_cache.go:60-65 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copies of one member (3 members, 7+ corresponding lines) · ×2
Edited copies of one member (3 members, 7+ corresponding lines) go/cli/flow_phases.go:291— go/cli/flow_phases.go:291-297 | go/cli/perf_target_set.go:245-251 | go/cli/scan_bench.go:204-210 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 7 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
Edited copies of one member (3 members, 7+ corresponding lines) go/avatar/avatar.go:31— go/avatar/avatar.go:31-37 | go/cli/bench_baseline.go:155-161 | go/texture_cache/texture_cache.go:35-41 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 7 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
Duplicated block (15 lines × 2) go/cli/cli.go:59— go/cli/cli.go:59-73 | go/cli/cli.go:183-197 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/cli/cli.go:59` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (15 lines × 2) go/ysm/texsize.go:78— go/ysm/texsize.go:78-92 | go/ysm/texsize.go:112-126 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/ysm/texsize.go:78` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (14 lines × 2) go/litematic/nbt.go:254— go/litematic/nbt.go:254-268 | go/litematic/nbt.go:272-285 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
Duplicated block (14 lines × 2) go/sync/sync_discovery.go:73— go/sync/sync_discovery.go:73-86 | go/sync/sync_discovery.go:106-119 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/sync/sync_discovery.go:73` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `go/sync/sync_discovery.go:70` calls `Name`, `Join` and `go/sync/sync_discovery.go:104` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (13 lines × 2) go/importer/importer.go:148— go/importer/importer.go:148-160 | go/importer/importer.go:221-233 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (13 lines × 2) go/scanner/hashindex.go:109— go/scanner/hashindex.go:109-121 | go/scanner/scanindex.go:335-347 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `go/scanner/hashindex.go:109` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `go/scanner/scanindex.go:334` calls `saveLocked` and `go/scanner/hashindex.go:108` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (12 lines × 2) internal/app/app_install_import.go:302— internal/app/app_install_import.go:302-313 | internal/app/app_install_instance.go:501-512 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (12 lines × 2) internal/app/app_model.go:413— internal/app/app_model.go:413-424 | internal/app/app_model.go:447-458 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `internal/app/app_model.go:413` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (11 lines × 2) internal/app/app_files.go:280— internal/app/app_files.go:280-290 | internal/app/app_files.go:309-319 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (11 lines × 2) go/cli/resource.go:133— go/cli/resource.go:133-143 | go/cli/resource.go:206-216 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/cli/resource.go:133` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (9 lines × 2) go/litematic/parser.go:64— go/litematic/parser.go:64-72 | go/litematic/voxel.go:132-140 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (9 lines × 2) internal/app/resourcepack_models.go:74— internal/app/resourcepack_models.go:74-82 | internal/app/resourcepack_models.go:104-112 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `internal/app/resourcepack_models.go:74` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) go/ysm/extracted_components.go:195— go/ysm/extracted_components.go:195-199 | go/ysm/extracted_components.go:216-220 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/ysm/extracted_components.go:195` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) go/threejs/spec-bones.go:273— go/threejs/spec-bones.go:273-277 | go/threejs/spec-bones.go:288-292 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/threejs/spec-bones.go:273` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Sync-over-async blocking artifacts/audit-env-s13/probe.mjs:48— `readFileSync` in `serve` 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 artifacts/audit-env-s13/probe2.mjs:58— `readFileSync` in `serve` 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.
Duplicated block (30 lines × 2 locations) frontend/src/preview-3d/caps/fog-capability.ts:222— frontend/src/preview-3d/caps/fog-capability.ts:222 · frontend/src/preview-3d/caps/shadow-capability.ts:488 — 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.
Duplicated block (30 lines × 2 locations) frontend/src/preview-3d/mesh/quaternion.ts:41— frontend/src/preview-3d/mesh/quaternion.ts:41 · scripts/port-align.ts:239 — 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.
Duplicated block (28 lines × 2 locations) scripts/check-design-tokens.ts:437— scripts/check-design-tokens.ts:437 · scripts/check-design-tokens.ts:740 — all 2 copies are in the same file, 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.
Duplicated block (28 lines × 2 locations) scripts/check-design-tokens.ts:632— scripts/check-design-tokens.ts:632 · scripts/check-i18n-unused.ts:180 — 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 with local edits (27 matched lines × 2 locations) · ×2
Duplicated block with local edits (27 matched lines × 2 locations) frontend/src/preview-3d/materials/alpha-index.ts:28— frontend/src/preview-3d/materials/alpha-index.ts:28 · scripts/_attic/translucency-probe.ts:144 — the two spans are one implementation copied and then locally edited — 288 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 (27 matched lines × 2 locations) scripts/_attic/perf-gate.ts:58— scripts/_attic/perf-gate.ts:58 · scripts/gui-flow-gate.ts:41 — the two spans are one implementation copied and then locally edited — 163 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 (23 lines × 2 locations) scripts/check-menu-health.ts:133— scripts/check-menu-health.ts:133 · scripts/check-menu-health.ts:234 — all 2 copies are in the same file, 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.
Duplicated block (23 lines × 2 locations) scripts/line-counter.ts:136— scripts/line-counter.ts:136 · scripts/line-counter.ts:220 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
X2 · Cancellation propagation· Function without context.Context · ×2
Function without context.Context: fetchReleaseList go/updater/updater.go:182— `fetchReleaseList` calls `http.NewRequest(…)` but takes no context.Context and reaches none its caller controls, so its caller cannot cancel the request once it has started. Take `ctx context.Context` as the first parameter and build the request with it: `http.NewRequestWithContext(ctx, …)`, `(&net.Dialer{}).DialContext(ctx, …)`.
Function without context.Context: fetchExpectedHash go/updater/updater_semver.go:79— `fetchExpectedHash` calls `http.NewRequest(…)` but takes no context.Context and reaches none its caller controls, so its caller cannot cancel the request once it has started. Take `ctx context.Context` as the first parameter and build the request with it: `http.NewRequestWithContext(ctx, …)`, `(&net.Dialer{}).DialContext(ctx, …)`.
X2 · Cancellation propagation· Async function without AbortSignal · ×2
Async function without AbortSignal: loadBundle frontend/src/utils/dom/locale-host.ts:12— `loadBundle` 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: loadBasisModule REDACTED:50— `loadBasisModule` 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 })`.
repoaudit.AuditCtx (cyclomatic 36) go/repoaudit/repoaudit.go:200— repoaudit.AuditCtx has cyclomatic complexity 36 (threshold 15). Most of this is not in the body itself: 8 of the 36 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 256, 241). 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.
RendererHost.animate (cyclomatic 30) frontend/src/preview-3d/infra/render-host.ts:273— RendererHost.animate 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.
tpl.statsCardHTML (cyclomatic 25) frontend/src/views/app-preview/tpl.ts:199— tpl.statsCardHTML has cyclomatic complexity 25 (threshold 15). Of this number, 19 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.
context-menu-handlers.createContextMenuHandlers (cyclomatic 25) frontend/src/features/context-menu/context-menu-handlers.ts:93— context-menu-handlers.createContextMenuHandlers 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 6 function items inside it that branch (runBatchFileOp, a function literal at line 216, a function literal at line 167, …). 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.
main.main (cyclomatic 24) build/android/scripts/deps/install_deps.go:12— main.main 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.
app.decodeYSMViaWASI (cyclomatic 23) internal/app/wasm_decoder.go:72— app.decodeYSMViaWASI 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.
texture_cache.pruneDir (cyclomatic 22) go/texture_cache/texture_cache.go:345— texture_cache.pruneDir has cyclomatic complexity 22 (threshold 15). Of this number, 19 points are the body's own statements and 3 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.
edit.eeApplyFilters (cyclomatic 21) REDACTED:96— edit.eeApplyFilters has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 8 of the 21 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 113, 109). 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.
dropdown.initDropdown (cyclomatic 21) frontend/src/utils/dom/dropdown.ts:50— dropdown.initDropdown 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 6 function items inside it that branch (onDocClick, close, onMenuClick, …). 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.
perf-trace.renderTraceRecord (cyclomatic 21) frontend/src/views/app-content/diagnostics/perf-trace.ts:43— perf-trace.renderTraceRecord has cyclomatic complexity 21 (threshold 15). Of this number, 18 points are the body's own statements and 3 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.
fileops.WriteModelFolder (cyclomatic 20) go/fileops/folder_import.go:21— fileops.WriteModelFolder has cyclomatic complexity 20 (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.
litematic.ParseNbtStructure (cyclomatic 20) go/litematic/structure.go:6— litematic.ParseNbtStructure 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.
litematic.BuildVoxelDataFromRoot (cyclomatic 20) go/litematic/voxel.go:128— litematic.BuildVoxelDataFromRoot has cyclomatic complexity 20 (threshold 15). Of this number, 15 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.
scanner.processScanDirEntry (cyclomatic 20) go/scanner/scanner_scan.go:247— scanner.processScanDirEntry 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.
scanner.hashEntriesParallel (cyclomatic 20) go/scanner/scanner_scan.go:412— scanner.hashEntriesParallel has cyclomatic complexity 20 (threshold 15). Of this number, 12 points are the body's own statements and 8 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.
sync.collectEntriesFromScan (cyclomatic 20) go/sync/sync_dirlevel_sync.go:323— sync.collectEntriesFromScan 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.
App.MergeWorkshopSitesFromJSON (cyclomatic 20) internal/app/app_workshop.go:393— App.MergeWorkshopSitesFromJSON 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.
loader.doLoadInstances (cyclomatic 20) frontend/src/views/app-sidebar/loader.ts:76— loader.doLoadInstances has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 8 of the 20 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 97, 123). 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.
detail-3d.showVrmMeta (cyclomatic 20) frontend/src/views/app-preview/detail-3d.ts:52— detail-3d.showVrmMeta has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 3 of the 20 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 63, 80). 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.
move-dnd.bindTreeMoveDnD (cyclomatic 20) frontend/src/features/dnd/move-dnd.ts:171— move-dnd.bindTreeMoveDnD has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 1 of the 20 points is its own statement and the rest belongs to 5 function items inside it that branch (onDragStart, onDrop, onDragOver, …). 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.
logs.dgLsBuildDiagMsg (cyclomatic 20) frontend/src/views/app-content/diagnostics/logs.ts:221— logs.dgLsBuildDiagMsg has cyclomatic complexity 20 (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.
instance.nestDirLevelTree (cyclomatic 19) go/instance/instance_tree.go:73— instance.nestDirLevelTree has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 3 of the 19 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 103, 75). 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.
sync.RelinkDir (cyclomatic 19) go/sync/sync_relink.go:28— sync.RelinkDir has cyclomatic complexity 19 (threshold 15). 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, 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.
ysm.FindGeometryInExtractedYSM (cyclomatic 19) go/ysm/extracted_find.go:16— ysm.FindGeometryInExtractedYSM 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.
app.ysmTextureOrder (cyclomatic 19) internal/app/texture_order.go:61— app.ysmTextureOrder 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.
vrm-bone-ui.makeBonePanelRenderer.<returned closure> (cyclomatic 19) frontend/src/preview-3d/adapters/vrm/vrm-bone-ui.ts:61— vrm-bone-ui.makeBonePanelRenderer.<returned closure> has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 3 of the 19 points are its own statements and the rest belongs to 4 function items inside it that branch (renderList, renderDetail, onPick, …). 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.
path-cards.initAdvancedGrid.refreshAdvanced (cyclomatic 19) frontend/src/views/app-content/settings/path-cards.ts:207— path-cards.initAdvancedGrid.refreshAdvanced has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 4 of the 19 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 243, 272, 216). 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.
main.run (cyclomatic 18) cmd/ccheck/main.go:34— main.run 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.
cli.validateModelData (cyclomatic 18) go/cli/bench_model_validate.go:14— cli.validateModelData 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.
cli.runDedupClean (cyclomatic 18) go/cli/dedup.go:164— cli.runDedupClean 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.
cli.runVerify (cyclomatic 18) go/cli/model.go:224— cli.runVerify 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.
fsutil.CopyDirRecursive (cyclomatic 18) go/fsutil/copy.go:149— fsutil.CopyDirRecursive 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.
mmd.ParsePmdStats (cyclomatic 18) go/geometry/mmd/mmd_stats.go:220— mmd.ParsePmdStats 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.
updater.InstallUpdate (cyclomatic 18) go/updater/updater_install.go:43— updater.InstallUpdate 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.
ysm.HasModInDir (cyclomatic 18) go/ysm/ysm.go:109— ysm.HasModInDir 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.
App.MergeCommunityCreatorsFromJSON (cyclomatic 18) internal/app/app_workshop.go:528— App.MergeCommunityCreatorsFromJSON 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.
bus-handlers.runBatchToggle (cyclomatic 18) frontend/src/views/app-tree/bus-handlers.ts:358— bus-handlers.runBatchToggle 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, 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.
events.toggleFolderBatch (cyclomatic 18) frontend/src/views/app-tree/events.ts:474— events.toggleFolderBatch 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.
edit.eeBindCreatorsEdit (cyclomatic 18) REDACTED:358— edit.eeBindCreatorsEdit 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 4 function literals inside it that branch (lines 384, 417, 367, …). 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.
error-diary.registerErrorDiary (cyclomatic 18) frontend/src/core/error-diary.ts:87— error-diary.registerErrorDiary has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 5 of the 18 points are its own statements and the rest belongs to 4 function items inside it that branch (logUiMsg, a function literal at line 143, dispose, …). 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.
instance-ops.registerInstanceOps (cyclomatic 18) frontend/src/features/pack-ops/instance-ops.ts:15— instance-ops.registerInstanceOps 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 2 function literals inside it that branch (lines 18, 93). 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.
LightCapability.onEnvChanged (cyclomatic 18) frontend/src/preview-3d/caps/light-capability.ts:323— LightCapability.onEnvChanged 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.
texture-loader.loadTextures (cyclomatic 18) frontend/src/preview-3d/texture/texture-loader.ts:9— texture-loader.loadTextures has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 6 of the 18 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 57, 44, 65, …). 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.
display.parseModelName (cyclomatic 18) REDACTED:59— display.parseModelName 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.
instance.absorbSelfMarker (cyclomatic 17) go/instance/instance_tree.go:215— instance.absorbSelfMarker 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.
ysm.AnalyzeYSMHeader (cyclomatic 17) go/ysm/header.go:261— ysm.AnalyzeYSMHeader 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.
ysm.extractFileStats (cyclomatic 17) go/ysm/summary_extract.go:19— ysm.extractFileStats 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.
App.SearchModels (cyclomatic 17) internal/app/app_scan.go:80— App.SearchModels 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.
render.compareTreeChildren (cyclomatic 17) frontend/src/views/app-tree/render.ts:353— render.compareTreeChildren 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.
context-menus.buildMenuItems (cyclomatic 17) frontend/src/features/context-menu/context-menus.ts:38— context-menus.buildMenuItems has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 66, 56, 48). 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.
batch-rename-form.dgBrBindReplaceTab (cyclomatic 17) frontend/src/features/dialogs/batch-rename-form.ts:141— batch-rename-form.dgBrBindReplaceTab 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 3 function items inside it that branch (a function literal at line 180, applyReplaceDebounced, a function literal at line 174). 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.
render.rmAppendFolder (cyclomatic 17) frontend/src/preview-3d/menu/render/render.ts:179— render.rmAppendFolder has cyclomatic complexity 17 (threshold 15). Of this number, 13 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.
perf.initPerfMode.apply (cyclomatic 17) frontend/src/views/app-content/diagnostics/perf.ts:99— perf.initPerfMode.apply 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.
avatar.extractAvatarFromContainerWithAuthors (cyclomatic 16) go/avatar/avatar_extract_container.go:119— avatar.extractAvatarFromContainerWithAuthors 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.
cli.evaluateBaseline (cyclomatic 16) go/cli/bench_baseline.go:180— cli.evaluateBaseline 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.
cli.runSingleBench (cyclomatic 16) go/cli/bench_single.go:51— cli.runSingleBench 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.
container.bestDecode (cyclomatic 16) go/container/encoding.go:35— container.bestDecode has cyclomatic complexity 16 (threshold 15). 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.
geometry.parseProjModels (cyclomatic 16) go/geometry/ysm_parser.go:133— geometry.parseProjModels 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.
geometry.parseYsmArchive (cyclomatic 16) go/geometry/ysm_parser.go:285— geometry.parseYsmArchive 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.
sync.patternFindMemo (cyclomatic 16) go/sync/sync_dirlevel.go:146— sync.patternFindMemo 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.
registry.LoadRegistry (cyclomatic 16) go/types/registry/resource.go:189— registry.LoadRegistry 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.
ysm.FindComponentsInExtractedYSM (cyclomatic 16) go/ysm/extracted_components.go:236— ysm.FindComponentsInExtractedYSM 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.
app.modelMatchesFilters (cyclomatic 16) internal/app/app_scan.go:201— app.modelMatchesFilters has cyclomatic complexity 16 (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.
App.importModelFileWithSubpath (cyclomatic 16) internal/app/app_install_import.go:161— App.importModelFileWithSubpath 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.
App.startProxy (cyclomatic 16) REDACTED:263— App.startProxy has cyclomatic complexity 16 (threshold 15). Of this number, 10 points are the body's own statements and 6 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.
main.run (cyclomatic 16) go/wasispike/main.go:34— main.run 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.
AppTree._onKeyArrowNav (cyclomatic 16) frontend/src/views/app-tree/index.ts:756— AppTree._onKeyArrowNav 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.
AppTree._executeTreeMove (cyclomatic 16) frontend/src/views/app-tree/index.ts:847— AppTree._executeTreeMove 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.
renderer.renderStatusTabs (cyclomatic 16) frontend/src/views/app-sync-manager/renderer.ts:147— renderer.renderStatusTabs has cyclomatic complexity 16 (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.
AppToast.show (cyclomatic 16) frontend/src/views/app-toast/index.ts:86— AppToast.show 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.
skeleton.loadModel2D (cyclomatic 16) frontend/src/views/app-preview/skeleton.ts:46— skeleton.loadModel2D has cyclomatic complexity 16 (threshold 15). Of this number, 9 points are the body's own statements and 7 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.
pack-meta.parsePackMetaJson (cyclomatic 16) frontend/src/parsers/pack-meta.ts:107— pack-meta.parsePackMetaJson 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.
ysm-header.mergeHeaderFields (cyclomatic 16) frontend/src/parsers/ysm-header.ts:125— ysm-header.mergeHeaderFields 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.
mount-session.teardown (cyclomatic 16) frontend/src/preview-3d/adapters/mount-session.ts:213— mount-session.teardown 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.
mmd-zip-overlay.resolveMmdZipConfig (cyclomatic 16) frontend/src/preview-3d/adapters/mmd/mmd-zip-overlay.ts:40— mmd-zip-overlay.resolveMmdZipConfig has cyclomatic complexity 16 (threshold 15). Of this number, 13 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.
mmd-zip-overlay.makeZipOverlayPort (cyclomatic 16) frontend/src/preview-3d/adapters/mmd/mmd-zip-overlay.ts:119— mmd-zip-overlay.makeZipOverlayPort 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 4 function literals inside it that branch (lines 175, 137, 156, …). 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.
vmd-retarget.buildVmdRetargetClip (cyclomatic 16) frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts:787— vmd-retarget.buildVmdRetargetClip 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.
light-persist.restoreLightParams (cyclomatic 16) frontend/src/preview-3d/caps/light-persist.ts:127— light-persist.restoreLightParams 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.
water-shader.assembleWaveShader.<returned closure> (cyclomatic 16) frontend/src/preview-3d/caps/water-shader.ts:48— water-shader.assembleWaveShader.<returned closure> 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.
postproc-cost-probe.runPostprocCostProbe (cyclomatic 16) frontend/src/preview-3d/infra/postproc-cost-probe.ts:368— postproc-cost-probe.runPostprocCostProbe 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.
rows.nodeControlToView (cyclomatic 16) frontend/src/preview-3d/menu/render/rows.ts:303— rows.nodeControlToView 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, 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.
screenshot.screenshotFromRenderer (cyclomatic 16) frontend/src/preview-3d/screenshot/screenshot.ts:32— screenshot.screenshotFromRenderer has cyclomatic complexity 16 (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.
animate.animateNumber (cyclomatic 16) frontend/src/utils/animation/animate.ts:18— animate.animateNumber has cyclomatic complexity 16 (threshold 15). Of this number, 10 points are the body's own statements and 6 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.
bind-roving.rovingOnKeydown (cyclomatic 16) frontend/src/utils/dom/bind-roving.ts:172— bind-roving.rovingOnKeydown 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.
ui-prefs.initUiPrefs (cyclomatic 16) frontend/src/views/app-content/settings/ui-prefs.ts:113— ui-prefs.initUiPrefs has cyclomatic complexity 16 (threshold 15). Of this number, 8 points are the body's own statements and 8 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.
XxxComment scripts/comment-checker.ts:97— // 超长行跳过:数据文件(如 wasm base64)含 XXX 子串会被误命中,注释不可能 >500 字符 — 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.
ysm.AnalyzeYSMHeader (cognitive 55) go/ysm/header.go:261— ysm.AnalyzeYSMHeader has cognitive complexity 55 (threshold 15). Drivers by points: if/else 16 (55 pts) (nesting depth added 39). 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.
main.main (cognitive 47) build/android/scripts/deps/install_deps.go:12— main.main has cognitive complexity 47 (threshold 15). Drivers by points: if/else 28 (38 pts), loops 3 (7 pts), boolean chains 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.
geometry.parseProjModels (cognitive 44) go/geometry/ysm_parser.go:133— geometry.parseProjModels has cognitive complexity 44 (threshold 15). Drivers by points: if/else 10 (31 pts), loops 2 (9 pts), boolean chains 4 (nesting depth added 28). 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.
app.decodeYSMViaWASI (cognitive 44) internal/app/wasm_decoder.go:72— app.decodeYSMViaWASI has cognitive complexity 44 (threshold 15). Drivers by points: if/else 16 (32 pts), loops 4 (9 pts), boolean chains 3 (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.
repoaudit.AuditCtx (cognitive 43) go/repoaudit/repoaudit.go:200— repoaudit.AuditCtx has cognitive complexity 43 (threshold 15). Drivers by points: if/else 31 (39 pts), boolean chains 4 (nesting depth added 8). Most of this is not in the body itself: 8 of the 43 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 256, 241). 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.
texture_cache.pruneDir (cognitive 42) go/texture_cache/texture_cache.go:345— texture_cache.pruneDir has cognitive complexity 42 (threshold 15). Drivers by points: if/else 16 (32 pts), loops 5 (9 pts), boolean chains 1 (nesting depth added 20). Of this number, 39 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.
RendererHost.animate (cognitive 42) frontend/src/preview-3d/infra/render-host.ts:273— RendererHost.animate has cognitive complexity 42 (threshold 15). Drivers by points: if/else 16 (24 pts), loops 4 (7 pts), ternaries 3 (5 pts), boolean chains 4, error handling 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.
ysm.FindGeometryInExtractedYSM (cognitive 39) go/ysm/extracted_find.go:16— ysm.FindGeometryInExtractedYSM has cognitive complexity 39 (threshold 15). Drivers by points: if/else 17 (34 pts), loops 3 (5 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.
ysm.extractFileStats (cognitive 39) go/ysm/summary_extract.go:19— ysm.extractFileStats has cognitive complexity 39 (threshold 15). Drivers by points: if/else 18 (35 pts), loops 1 (3 pts), boolean chains 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.
app.ysmTextureOrder (cognitive 36) internal/app/texture_order.go:61— app.ysmTextureOrder has cognitive complexity 36 (threshold 15). Drivers by points: if/else 17 (34 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.
scanner.hashEntriesParallel (cognitive 35) go/scanner/scanner_scan.go:412— scanner.hashEntriesParallel has cognitive complexity 35 (threshold 15). Drivers by points: if/else 12 (26 pts), loops 5 (7 pts), boolean chains 2 (nesting depth added 16). Most of this is not in the body itself: 15 of the 35 points are its own statements and the rest belongs to one function literal inside it that branches (line 440). 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.
sync.RelinkDir (cognitive 35) go/sync/sync_relink.go:28— sync.RelinkDir has cognitive complexity 35 (threshold 15). Drivers by points: if/else 16 (31 pts), boolean chains 3, loops 1 (nesting depth added 15). Of this number, 32 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.
fsutil.CopyDirRecursive (cognitive 34) go/fsutil/copy.go:149— fsutil.CopyDirRecursive has cognitive complexity 34 (threshold 15). Drivers by points: if/else 15 (33 pts), boolean chains 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.
geometry.parseYsmArchive (cognitive 33) go/geometry/ysm_parser.go:285— geometry.parseYsmArchive has cognitive complexity 33 (threshold 15). Drivers by points: if/else 8 (21 pts), loops 5 (10 pts), boolean chains 2 (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.
geometry.buildModel (cognitive 32) go/geometry/parse.go:80— geometry.buildModel has cognitive complexity 32 (threshold 15). Drivers by points: if/else 10 (28 pts), loops 2 (3 pts), boolean chains 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.
litematic.BuildVoxelDataFromRoot (cognitive 32) go/litematic/voxel.go:128— litematic.BuildVoxelDataFromRoot has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (26 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 15). Of this number, 25 points are the body's own statements and 7 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.
scanner.processScanDirEntry (cognitive 32) go/scanner/scanner_scan.go:247— scanner.processScanDirEntry has cognitive complexity 32 (threshold 15). Drivers by points: if/else 18 (31 pts), boolean chains 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.
sync.collectEntriesFromScan (cognitive 32) go/sync/sync_dirlevel_sync.go:323— sync.collectEntriesFromScan has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (25 pts), loops 4, boolean chains 3 (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.
ysm.HasModInDir (cognitive 32) go/ysm/ysm.go:109— ysm.HasModInDir has cognitive complexity 32 (threshold 15). Drivers by points: if/else 12 (24 pts), loops 3 (5 pts), boolean chains 3 (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.
sync.patternFindMemo (cognitive 31) go/sync/sync_dirlevel.go:146— sync.patternFindMemo has cognitive complexity 31 (threshold 15). Drivers by points: if/else 13 (27 pts), loops 2 (4 pts) (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.
sync.planToggleRenames (cognitive 30) go/sync/sync.go:255— sync.planToggleRenames has cognitive complexity 30 (threshold 15). Drivers by points: if/else 11 (28 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.
instance.nestDirLevelTree (cognitive 29) go/instance/instance_tree.go:73— instance.nestDirLevelTree has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (21 pts), boolean chains 4, loops 3 (4 pts) (nesting depth added 13). Most of this is not in the body itself: 3 of the 29 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 103, 75). 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.
launcher.jsonArrayContains (cognitive 29) go/launcher/detect.go:300— launcher.jsonArrayContains has cognitive complexity 29 (threshold 15). Drivers by points: if/else 5 (19 pts), loops 3 (9 pts), match/switch 1 (nesting depth added 20). 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.
App.MergeWorkshopSitesFromJSON (cognitive 29) internal/app/app_workshop.go:393— App.MergeWorkshopSitesFromJSON has cognitive complexity 29 (threshold 15). Drivers by points: if/else 17 (25 pts), loops 3, 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.
context-menu-handlers.createContextMenuHandlers (cognitive 29) frontend/src/features/context-menu/context-menu-handlers.ts:93— context-menu-handlers.createContextMenuHandlers has cognitive complexity 29 (threshold 15). Drivers by points: if/else 11, error handling 5 (7 pts), ternaries 4 (5 pts), boolean chains 4, loops 2 (nesting depth added 3). None of this is in the body itself: all 29 points belong to 6 function items inside it that branch (runBatchFileOp, a function literal at line 216, a function literal at line 167, …). 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.
avatar.extractAvatarFromContainerWithAuthors (cognitive 28) go/avatar/avatar_extract_container.go:119— avatar.extractAvatarFromContainerWithAuthors has cognitive complexity 28 (threshold 15). Drivers by points: if/else 9 (20 pts), loops 3 (5 pts), boolean chains 3 (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.
geometry.applyL0ManifestItem (cognitive 28) go/geometry/maid_l0_resolve.go:174— geometry.applyL0ManifestItem has cognitive complexity 28 (threshold 15). Drivers by points: if/else 11 (27 pts), boolean chains 1 (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.
packs.classifyByLocationStrict (cognitive 28) go/packs/classify.go:169— packs.classifyByLocationStrict has cognitive complexity 28 (threshold 15). Drivers by points: if/else 7 (19 pts), loops 4 (7 pts), boolean chains 2 (nesting depth added 15). 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.
ysm.FindComponentsInExtractedYSM (cognitive 28) go/ysm/extracted_components.go:236— ysm.FindComponentsInExtractedYSM has cognitive complexity 28 (threshold 15). Drivers by points: if/else 13 (23 pts), loops 3 (4 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.
tpl.statsCardHTML (cognitive 28) frontend/src/views/app-preview/tpl.ts:199— tpl.statsCardHTML has cognitive complexity 28 (threshold 15). Drivers by points: ternaries 11 (15 pts), boolean chains 12, if/else 1 (nesting depth added 4). Of this number, 21 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.
cli.runCacheDiag (cognitive 27) go/cli/cache.go:405— cli.runCacheDiag has cognitive complexity 27 (threshold 15). Drivers by points: if/else 17 (21 pts), match/switch 2 (6 pts) (nesting depth added 8). 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.
geometry.mergeParsedGeos (cognitive 27) go/geometry/archive_merge.go:194— geometry.mergeParsedGeos has cognitive complexity 27 (threshold 15). Drivers by points: if/else 6 (13 pts), loops 5 (13 pts), boolean chains 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.
instance.absorbSelfMarker (cognitive 27) go/instance/instance_tree.go:215— instance.absorbSelfMarker has cognitive complexity 27 (threshold 15). Drivers by points: if/else 6 (15 pts), boolean chains 6, loops 4 (6 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.
registry.descString (cognitive 27) go/types/registry/resource_lookup.go:177— registry.descString has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (19 pts), loops 2 (7 pts), boolean chains 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.
edit.eeBindCreatorsEdit (cognitive 27) REDACTED:358— edit.eeBindCreatorsEdit has cognitive complexity 27 (threshold 15). Drivers by points: if/else 14 (21 pts), boolean chains 6 (nesting depth added 7). None of this is in the body itself: all 27 points belong to 4 function literals inside it that branch (lines 384, 417, 443, …). 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.
cli.runConfigShow (cognitive 26) go/cli/config.go:15— cli.runConfigShow has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (21 pts), loops 1 (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.
geometry.buildSubModels (cognitive 26) go/geometry/archive_merge.go:13— geometry.buildSubModels has cognitive complexity 26 (threshold 15). Drivers by points: if/else 8 (20 pts), loops 2 (4 pts), boolean chains 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.
sync.PushResources (cognitive 26) go/sync/sync_push.go:53— sync.PushResources has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (22 pts), loops 2 (3 pts), boolean chains 1 (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.
ysm-adapter.scanAnimFiles (cognitive 26) frontend/src/preview-3d/adapters/ysm-adapter.ts:315— ysm-adapter.scanAnimFiles has cognitive complexity 26 (threshold 15). Drivers by points: if/else 5 (9 pts), ternaries 2 (6 pts), loops 3 (5 pts), error handling 2 (4 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.
AnimationControllerRuntime.update (cognitive 26) frontend/src/utils/animation/animation-controller.ts:266— AnimationControllerRuntime.update has cognitive complexity 26 (threshold 15). Drivers by points: if/else 6 (15 pts), error handling 2 (7 pts), loops 2 (4 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.
cli.runVerify (cognitive 25) go/cli/model.go:224— cli.runVerify has cognitive complexity 25 (threshold 15). Drivers by points: if/else 8 (14 pts), loops 3 (5 pts), boolean chains 4, match/switch 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.
repo-events-bindings.cmReBindRowClick (cognitive 25) frontend/src/features/community/repo-events-bindings.ts:182— repo-events-bindings.cmReBindRowClick has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (17 pts), error handling 2 (7 pts), boolean chains 1 (nesting depth added 15). Most of this is not in the body itself: 1 of the 25 points is its own statement and the rest belongs to one function literal inside it that branches (line 186). 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.
LightCapability.onEnvChanged (cognitive 25) frontend/src/preview-3d/caps/light-capability.ts:323— LightCapability.onEnvChanged has cognitive complexity 25 (threshold 15). Drivers by points: if/else 13 (19 pts), boolean chains 4, loops 1 (2 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.
perf-trace.renderTraceRecord (cognitive 25) frontend/src/views/app-content/diagnostics/perf-trace.ts:43— perf-trace.renderTraceRecord has cognitive complexity 25 (threshold 15). Drivers by points: ternaries 17 (23 pts), boolean chains 1, if/else 1 (nesting depth added 6). Of this number, 20 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.
main.run (cognitive 24) cmd/ccheck/main.go:34— main.run has cognitive complexity 24 (threshold 15). Drivers by points: if/else 15 (21 pts), loops 2, boolean chains 1 (nesting depth added 6). 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.
ysm.scanZipBasicStats (cognitive 24) go/ysm/summary.go:237— ysm.scanZipBasicStats has cognitive complexity 24 (threshold 15). Drivers by points: if/else 8 (20 pts), boolean chains 3, loops 1 (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.
app.migrateFlatStorageToGrouped (cognitive 24) internal/app/app.go:445— app.migrateFlatStorageToGrouped has cognitive complexity 24 (threshold 15). Drivers by points: if/else 9 (21 pts), boolean chains 2, loops 1 (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.
events.atTeBindSelCheckboxes (cognitive 24) frontend/src/views/app-tree/events.ts:78— events.atTeBindSelCheckboxes has cognitive complexity 24 (threshold 15). Drivers by points: if/else 10 (19 pts), boolean chains 3, ternaries 1 (2 pts) (nesting depth added 10). Most of this is not in the body itself: 11 of the 24 points are its own statements and the rest belongs to 4 function items inside it that branch (a function literal at line 132, flipLocal, a function literal at line 121, …). 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.
community-fetch.fetchWithFallback (cognitive 24) frontend/src/features/community/community-fetch.ts:21— community-fetch.fetchWithFallback has cognitive complexity 24 (threshold 15). Drivers by points: if/else 7 (16 pts), ternaries 3 (4 pts), error handling 1 (2 pts), boolean chains 1, 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.
env-dispatcher.dispatchEnvChange (cognitive 24) frontend/src/preview-3d/state/env-dispatcher.ts:62— env-dispatcher.dispatchEnvChange has cognitive complexity 24 (threshold 15). Drivers by points: if/else 6 (15 pts), loops 3 (7 pts), error handling 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.
packs.classifyByNestedPattern (cognitive 23) go/packs/classify.go:134— packs.classifyByNestedPattern has cognitive complexity 23 (threshold 15). Drivers by points: if/else 4 (12 pts), loops 4 (9 pts), boolean chains 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.
packs.readZipPackMeta (cognitive 23) go/packs/mcmeta.go:82— packs.readZipPackMeta has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (18 pts), boolean chains 4, loops 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.
registry.TypeByLocation (cognitive 23) go/types/registry/location.go:17— registry.TypeByLocation has cognitive complexity 23 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 4 (7 pts), boolean chains 4 (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.
registry.LoadRegistry (cognitive 23) go/types/registry/resource.go:189— registry.LoadRegistry has cognitive complexity 23 (threshold 15). Drivers by points: if/else 12 (18 pts), loops 2 (3 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.
App.MergeCommunityCreatorsFromJSON (cognitive 23) internal/app/app_workshop.go:528— App.MergeCommunityCreatorsFromJSON has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (17 pts), boolean chains 3, loops 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.
events.toggleFolderBatch (cognitive 23) frontend/src/views/app-tree/events.ts:474— events.toggleFolderBatch has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (15 pts), loops 2 (3 pts), boolean chains 2, ternaries 2, error handling 1 (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.
web-fs-bedrock.webExtractPreviewTexture (cognitive 23) frontend/src/backend/web-fs-bedrock.ts:213— web-fs-bedrock.webExtractPreviewTexture has cognitive complexity 23 (threshold 15). Drivers by points: if/else 6 (12 pts), ternaries 4 (7 pts), error handling 1 (2 pts), loops 1 (2 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.
logs.dgLsBuildDiagMsg (cognitive 23) frontend/src/views/app-content/diagnostics/logs.ts:221— logs.dgLsBuildDiagMsg has cognitive complexity 23 (threshold 15). Drivers by points: boolean chains 10, if/else 7 (9 pts), ternaries 3 (4 pts) (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.
dedup.hashFilesParallel (cognitive 22) go/dedup/dedup.go:142— dedup.hashFilesParallel has cognitive complexity 22 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 4 (5 pts), match/switch 1 (3 pts), jumps 2 (nesting depth added 8). Of this number, 15 points are the body's own statements and 7 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.
fsutil.RecoverAtomicRename (cognitive 22) go/fsutil/copy.go:276— fsutil.RecoverAtomicRename has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (17 pts), loops 3 (4 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.
ysm.detectYSGPHeader (cognitive 22) go/ysm/header.go:354— ysm.detectYSGPHeader has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (19 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.
App.SyncModelToggleStatusForType (cognitive 22) internal/app/app_install_instance.go:266— App.SyncModelToggleStatusForType has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (18 pts), loops 2 (3 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.
App.DeleteResourcePack (cognitive 22) internal/app/resource_bindings.go:397— App.DeleteResourcePack has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (20 pts), boolean chains 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.
render.flattenVisible (cognitive 22) frontend/src/views/app-tree/render.ts:440— render.flattenVisible has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (13 pts), ternaries 3 (5 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.
edit.eeApplyFilters (cognitive 22) REDACTED:96— edit.eeApplyFilters has cognitive complexity 22 (threshold 15). Drivers by points: boolean chains 11, if/else 7 (10 pts), ternaries 1 (nesting depth added 3). Of this number, 11 points are the body's own statements and 11 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.
data.fetchModelsOne (cognitive 22) frontend/src/features/community/data.ts:156— data.fetchModelsOne has cognitive complexity 22 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 2, error handling 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.
safe-dispose.disposeObject3D (cognitive 22) frontend/src/preview-3d/infra/safe-dispose.ts:31— safe-dispose.disposeObject3D has cognitive complexity 22 (threshold 15). Drivers by points: if/else 9 (17 pts), loops 1 (2 pts), ternaries 1 (2 pts), boolean chains 1 (nesting depth added 10). Most of this is not in the body itself: 3 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 42). 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.
geometry.deriveModelTexOrder (cognitive 21) go/geometry/archive_merge.go:77— geometry.deriveModelTexOrder has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (15 pts), loops 4 (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.
packs.DetectByEntries (cognitive 21) go/packs/classify.go:83— packs.DetectByEntries has cognitive complexity 21 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 3 (5 pts), boolean chains 2, match/switch 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.
packs.classifyByFingerprint (cognitive 21) go/packs/classify.go:229— packs.classifyByFingerprint has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 3, 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.
sync.PushTargetsForUnit (cognitive 21) go/sync/sync_targets.go:46— sync.PushTargetsForUnit has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (14 pts), loops 2 (4 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.
componentBindCtx.bindPerComponentTex (cognitive 21) go/ysm/extracted_components.go:184— componentBindCtx.bindPerComponentTex has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (19 pts), boolean chains 2 (nesting depth added 10). 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.
loader.doLoadInstances (cognitive 21) frontend/src/views/app-sidebar/loader.ts:76— loader.doLoadInstances has cognitive complexity 21 (threshold 15). Drivers by points: boolean chains 10, ternaries 5 (7 pts), if/else 3, error handling 1 (nesting depth added 2). Most of this is not in the body itself: 7 of the 21 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 97, 123). 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.
sidebar-push.runPush (cognitive 21) frontend/src/views/app-sidebar/sidebar-push.ts:188— sidebar-push.runPush has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (14 pts), loops 3 (4 pts), error handling 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.
animation.extractKeyframe (cognitive 21) REDACTED:165— animation.extractKeyframe has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (11 pts), ternaries 4 (9 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.
animation.parseClipBones (cognitive 21) REDACTED:402— animation.parseClipBones has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 3 (6 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.
web-stats.runPoolChunk (cognitive 21) frontend/src/backend/web-stats.ts:407— web-stats.runPoolChunk has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (18 pts), boolean chains 2, loops 1 (nesting depth added 8). Of this number, 19 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.
error-diary.registerErrorDiary (cognitive 21) frontend/src/core/error-diary.ts:87— error-diary.registerErrorDiary has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (11 pts), ternaries 4 (5 pts), error handling 2, loops 1 (2 pts), boolean chains 1 (nesting depth added 5). Most of this is not in the body itself: 5 of the 21 points are its own statements and the rest belongs to 4 function items inside it that branch (logUiMsg, a function literal at line 143, dispose, …). 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.
mmd-zip-overlay.resolveMmdZipConfig (cognitive 21) frontend/src/preview-3d/adapters/mmd/mmd-zip-overlay.ts:40— mmd-zip-overlay.resolveMmdZipConfig has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 4 (5 pts), boolean chains 2, ternaries 2 (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.
water-persist.restoreWaterSchemaKeys (cognitive 21) frontend/src/preview-3d/caps/water-persist.ts:115— water-persist.restoreWaterSchemaKeys has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (20 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.
screenshot-render.applyLights (cognitive 21) frontend/src/preview-3d/screenshot/screenshot-render.ts:41— screenshot-render.applyLights has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (14 pts), boolean chains 3, ternaries 1 (3 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.
logs.dgLsMakeStatusLabel (cognitive 21) frontend/src/views/app-content/diagnostics/logs.ts:197— logs.dgLsMakeStatusLabel has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 7 (20 pts), if/else 1 (nesting depth added 13). 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.
cli.evaluateBaseline (cognitive 20) go/cli/bench_baseline.go:180— cli.evaluateBaseline has cognitive complexity 20 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 2, loops 2, match/switch 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.
conc.parallelN (cognitive 20) go/conc/pool.go:53— conc.parallelN has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (12 pts), loops 4 (5 pts), match/switch 1 (2 pts), jumps 1 (nesting depth added 7). Of this number, 12 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.
fileops.WriteModelFolder (cognitive 20) go/fileops/folder_import.go:21— fileops.WriteModelFolder has cognitive complexity 20 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 4, loops 1 (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.
geometry.parseLegacyMetadata (cognitive 20) go/geometry/archive.go:253— geometry.parseLegacyMetadata has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 2 (3 pts), boolean chains 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.
geometry.matchGeoEntryBySubPath (cognitive 20) go/geometry/archive_parse.go:182— geometry.matchGeoEntryBySubPath has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (15 pts), loops 3 (4 pts), boolean chains 1 (nesting depth added 6). Of this number, 14 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.
rtypeCtx.appendOneItem (cognitive 20) go/instance/instance.go:203— rtypeCtx.appendOneItem has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 1 (3 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.
litematic.aggregateBlockStatsFromPalette (cognitive 20) go/litematic/parser.go:93— litematic.aggregateBlockStatsFromPalette has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 2 (3 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.
ysm.collectDeclaredTexByModel (cognitive 20) go/ysm/extracted_components.go:23— ysm.collectDeclaredTexByModel has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (16 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.
app.jpegPixelArea (cognitive 20) internal/app/texture_order.go:254— app.jpegPixelArea has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (17 pts), loops 1 (2 pts), boolean chains 1 (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.
App.ServiceStartup (cognitive 20) internal/app/app.go:198— App.ServiceStartup has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (18 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.
bus-handlers.runBatchToggle (cognitive 20) frontend/src/views/app-tree/bus-handlers.ts:358— bus-handlers.runBatchToggle has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (9 pts), boolean chains 4, loops 3 (4 pts), ternaries 2, error handling 1 (nesting depth added 3). 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, 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.
AppTree._executeTreeMove (cognitive 20) frontend/src/views/app-tree/index.ts:847— AppTree._executeTreeMove has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (10 pts), loops 2 (4 pts), boolean chains 3, ternaries 1 (2 pts), error handling 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.
detail-3d.showVrmMeta (cognitive 20) frontend/src/views/app-preview/detail-3d.ts:52— detail-3d.showVrmMeta has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 10 (11 pts), boolean chains 8, if/else 1 (nesting depth added 1). 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 literals inside it that branch (lines 63, 80). 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.
pack-meta.formatRangeToPair (cognitive 20) frontend/src/parsers/pack-meta.ts:79— pack-meta.formatRangeToPair has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (9 pts), ternaries 4 (8 pts), boolean chains 3 (nesting depth added 7). 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, 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.
ysm-header.zipSummary (cognitive 20) frontend/src/parsers/ysm-header.ts:469— ysm-header.zipSummary has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (12 pts), boolean chains 4, loops 2 (3 pts), 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.
env-pixels.luminanceHistogram (cognitive 20) frontend/src/preview-3d/caps/env-pixels.ts:179— env-pixels.luminanceHistogram has cognitive complexity 20 (threshold 15). Drivers by points: if/else 5 (9 pts), loops 2 (7 pts), error handling 1 (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.
anti-repeat.maxSeamDiscontinuity (cognitive 20) frontend/src/preview-3d/caps/surface-pixels/anti-repeat.ts:383— anti-repeat.maxSeamDiscontinuity has cognitive complexity 20 (threshold 15). Drivers by points: loops 6 (14 pts), if/else 2 (6 pts) (nesting depth added 12). 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.
model-cache.collectBlobUrls (cognitive 20) frontend/src/preview-3d/decoder/model-cache.ts:47— model-cache.collectBlobUrls has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 3 (4 pts), boolean chains 3, 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.
model-cache.cacheSet (cognitive 20) frontend/src/preview-3d/decoder/model-cache.ts:64— model-cache.cacheSet has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (16 pts), loops 1 (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.
ysm-animation-player.mdApApplyPose (cognitive 20) frontend/src/preview-3d/model/ysm-animation-player.ts:153— ysm-animation-player.mdApApplyPose has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (18 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.
dropdown.initDropdown (cognitive 20) frontend/src/utils/dom/dropdown.ts:50— dropdown.initDropdown has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 4, loops 1, ternaries 1 (nesting depth added 1). Most of this is not in the body itself: 2 of the 20 points are its own statements and the rest belongs to 6 function items inside it that branch (onDocClick, decorateItems, close, …). 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.
stats-core.statsFromDecodedFiles (cognitive 20) frontend/src/workers/stats-core.ts:88— stats-core.statsFromDecodedFiles has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (19 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.
avatar.CacheAvatarsFromJSON (cognitive 19) go/avatar/avatar_extract_json.go:71— avatar.CacheAvatarsFromJSON has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (17 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.
avatar.matchAvatarByAuthor (cognitive 19) go/avatar/avatar_extract_ysm.go:84— avatar.matchAvatarByAuthor has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 4 (7 pts), boolean chains 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.
cli.buildBaselineJSON (cognitive 19) go/cli/bench_baseline.go:377— cli.buildBaselineJSON has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (17 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.
cli.runSingleBench (cognitive 19) go/cli/bench_single.go:51— cli.runSingleBench has cognitive complexity 19 (threshold 15). Drivers by points: if/else 14 (16 pts), match/switch 1 (2 pts), boolean chains 1 (nesting depth added 3). 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: 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.
cli.avgBenchStages (cognitive 19) go/cli/bench_stage_utils.go:28— cli.avgBenchStages has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 3 (4 pts), boolean chains 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.
cli.runDedupClean (cognitive 19) go/cli/dedup.go:164— cli.runDedupClean has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (11 pts), loops 5 (7 pts), boolean chains 1 (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.
download.copyResponseBodyWithProgress (cognitive 19) go/download/download_downloader.go:184— download.copyResponseBodyWithProgress has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (15 pts), match/switch 1 (2 pts), boolean chains 1, loops 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.
litematic.ParseNbtStructure (cognitive 19) go/litematic/structure.go:6— litematic.ParseNbtStructure has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 2, loops 1 (2 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.
litematic.nextSchematicV1Block (cognitive 19) go/litematic/voxel_schematic.go:121— litematic.nextSchematicV1Block has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (16 pts), boolean chains 2, 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.
logs.trimRing (cognitive 19) go/logs/ring.go:42— logs.trimRing has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 2 (3 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.
Watcher.loop (cognitive 19) go/watcher/watcher.go:191— Watcher.loop has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (16 pts), match/switch 1 (2 pts), loops 1 (nesting depth added 10). 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.
app.appendSpecKey (cognitive 19) internal/app/cli_bridge.go:252— app.appendSpecKey has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (18 pts), match/switch 1 (nesting depth added 9). 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.
App.SearchModels (cognitive 19) internal/app/app_scan.go:80— App.SearchModels has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (15 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.
App.finalizeScanEntries (cognitive 19) internal/app/app_scan.go:411— App.finalizeScanEntries has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 3 (5 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.
App.MergeWorkshopCreatorsFromJSON (cognitive 19) internal/app/app_workshop.go:341— App.MergeWorkshopCreatorsFromJSON has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 2, boolean chains 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.
init-github.fetchAndRenderRepo (cognitive 19) frontend/src/views/app-content/init-github.ts:165— init-github.fetchAndRenderRepo has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 4, error handling 1 (nesting depth added 5). Of this number, 15 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.
community-data.mergeCommunityCreators (cognitive 19) frontend/src/features/community/community-data.ts:259— community-data.mergeCommunityCreators has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (15 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.
instance-ops.registerInstanceOps (cognitive 19) frontend/src/features/pack-ops/instance-ops.ts:15— instance-ops.registerInstanceOps has cognitive complexity 19 (threshold 15). Drivers by points: if/else 11 (12 pts), error handling 5 (6 pts), loops 1 (nesting depth added 2). None of this is in the body itself: all 19 points belong to 2 function literals inside it that branch (lines 18, 93). 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.
mmd-zip-overlay.makeZipOverlayPort (cognitive 19) frontend/src/preview-3d/adapters/mmd/mmd-zip-overlay.ts:119— mmd-zip-overlay.makeZipOverlayPort has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (12 pts), ternaries 2 (3 pts), boolean chains 2, loops 2 (nesting depth added 4). None of this is in the body itself: all 19 points belong to 4 function literals inside it that branch (lines 175, 137, 156, …). 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.
vmd-retarget.buildVmdRetargetClip (cognitive 19) frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts:787— vmd-retarget.buildVmdRetargetClip has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 4, ternaries 3 (4 pts), loops 3 (nesting depth added 4). 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 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.
animate.animateNumber (cognitive 19) frontend/src/utils/animation/animate.ts:18— animate.animateNumber has cognitive complexity 19 (threshold 15). Drivers by points: if/else 12 (14 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 3). Of this number, 13 points are the body's own statements and 6 belong to 4 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.
animation-evaluator.executeTimeline (cognitive 19) frontend/src/utils/animation/animation-evaluator.ts:128— animation-evaluator.executeTimeline has cognitive complexity 19 (threshold 15). Drivers by points: loops 5 (9 pts), if/else 4 (7 pts), boolean chains 2, ternaries 1 (nesting depth added 7). 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.
perf-single-bench.runSingleBench (cognitive 19) frontend/src/views/app-content/diagnostics/perf-single-bench.ts:504— perf-single-bench.runSingleBench has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (15 pts), ternaries 2 (3 pts), 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.
container.bestDecode (cognitive 18) go/container/encoding.go:35— container.bestDecode has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (7 pts), boolean chains 4, loops 3 (4 pts), match/switch 1 (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.
fileops.writeModelFolderFiles (cognitive 18) go/fileops/folder_import.go:93— fileops.writeModelFolderFiles 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.
mmd.ParsePmdStats (cognitive 18) go/geometry/mmd/mmd_stats.go:220— mmd.ParsePmdStats has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 3, loops 1, 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.
litematic.filterSurfaceOnly (cognitive 18) go/litematic/voxel_schematic.go:195— litematic.filterSurfaceOnly has cognitive complexity 18 (threshold 15). Drivers by points: if/else 3 (9 pts), loops 5 (9 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.
main.main (cognitive 18) go/litematic/gen/main.go:27— main.main has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (12 pts), loops 5 (6 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.
ResourceType.MatchZipEntry (cognitive 18) go/types/registry/resource.go:134— ResourceType.MatchZipEntry has cognitive complexity 18 (threshold 15). Drivers by points: if/else 3 (12 pts), loops 2 (3 pts), match/switch 1 (3 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.
app.buildComponentTextureMap (cognitive 18) internal/app/app_model.go:465— app.buildComponentTextureMap has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (14 pts), loops 2 (3 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.
App.BatchExtractCreatorAvatars (cognitive 18) internal/app/app_avatar.go:23— App.BatchExtractCreatorAvatars has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (15 pts), loops 2, boolean chains 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.
App.GetVoxelDataInContainer (cognitive 18) internal/app/container_entries.go:108— App.GetVoxelDataInContainer has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (14 pts), match/switch 1 (2 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.
render.compareTreeChildren (cognitive 18) frontend/src/views/app-tree/render.ts:353— render.compareTreeChildren has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 9, ternaries 3 (5 pts), if/else 4 (nesting depth added 2). 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.
web-community.batchExtractCreatorAvatars (cognitive 18) frontend/src/backend/web-community.ts:165— web-community.batchExtractCreatorAvatars has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 3 (4 pts), 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.
t.interpolate (cognitive 18) frontend/src/core/i18n/t.ts:32— t.interpolate has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), ternaries 2 (5 pts), loops 1 (2 pts) (nesting depth added 10). 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.
download-queue-web.runWebEnqueue (cognitive 18) frontend/src/features/community/download-queue-web.ts:103— download-queue-web.runWebEnqueue has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (11 pts), boolean chains 5, error handling 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.
move-dnd.bindTreeMoveDnD (cognitive 18) frontend/src/features/dnd/move-dnd.ts:171— move-dnd.bindTreeMoveDnD has cognitive complexity 18 (threshold 15). Drivers by points: if/else 13, boolean chains 3, ternaries 2. None of this is in the body itself: all 18 points belong to 5 function items inside it that branch (onDragStart, onDrop, onDragOver, …). 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.
extract.parseZipCentralDir (cognitive 18) frontend/src/parsers/extract.ts:73— extract.parseZipCentralDir has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 2, loops 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.
voxel-pipeline.filterSurfaceOnly (cognitive 18) frontend/src/parsers/voxel-pipeline.ts:96— voxel-pipeline.filterSurfaceOnly has cognitive complexity 18 (threshold 15). Drivers by points: if/else 3 (9 pts), loops 5 (9 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.
fbx-adapter.buildFbxTexUrlMap (cognitive 18) frontend/src/preview-3d/adapters/fbx/fbx-adapter.ts:147— fbx-adapter.buildFbxTexUrlMap has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (8 pts), loops 3 (6 pts), ternaries 1 (2 pts), boolean chains 1, error handling 1 (nesting depth added 8). 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.
debug-render.rebuildDebug (cognitive 18) frontend/src/preview-3d/infra/debug-render.ts:82— debug-render.rebuildDebug has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (9 pts), loops 3 (5 pts), ternaries 1 (3 pts), boolean chains 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.
rows.nodeControlToView (cognitive 18) frontend/src/preview-3d/menu/render/rows.ts:303— rows.nodeControlToView has cognitive complexity 18 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 3, ternaries 2 (nesting depth added 3). Of this number, 15 points are the body's own statements and 3 belong to 2 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.
texture-loader.loadTextures (cognitive 18) frontend/src/preview-3d/texture/texture-loader.ts:9— texture-loader.loadTextures has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 3, loops 1 (nesting depth added 3). Most of this is not in the body itself: 8 of the 18 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 57, 42, 44, …). 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.
animation-controller.parseAnimationControllerJSON (cognitive 18) frontend/src/utils/animation/animation-controller.ts:55— animation-controller.parseAnimationControllerJSON has cognitive complexity 18 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 4, loops 2 (3 pts), 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.
mc-format.renderFormattedText (cognitive 18) frontend/src/utils/html/mc-format.ts:45— mc-format.renderFormattedText has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (15 pts), loops 2, boolean chains 1 (nesting depth added 4). Most of this is not in the body itself: 2 of the 18 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 52, 63, 69). 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.
cli.validateModelData (cognitive 17) go/cli/bench_model_validate.go:14— cli.validateModelData has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (9 pts), boolean chains 5, loops 3 (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.
cli.runHealthReport (cognitive 17) go/cli/health.go:35— cli.runHealthReport has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (14 pts), loops 1 (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.
geometry.extractFirstPNG (cognitive 17) go/geometry/archive.go:92— geometry.extractFirstPNG has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (14 pts), loops 2, 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.
geometry.buildTexIdxMap (cognitive 17) go/geometry/archive_merge.go:162— geometry.buildTexIdxMap has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (12 pts), loops 2 (4 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.
launcher.resolveRunDirectory (cognitive 17) go/launcher/detect.go:208— launcher.resolveRunDirectory has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 1, match/switch 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.
recycle.DeduplicateEntries (cognitive 17) go/recycle/recycle_clean.go:179— recycle.DeduplicateEntries has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (13 pts), loops 3 (4 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.
sync.collectEntriesWalk (cognitive 17) go/sync/sync_dirlevel_sync.go:228— sync.collectEntriesWalk has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (17 pts) (nesting depth added 7). None of this is in the body itself: all 17 points belong to one function literal inside it that branches (line 235). 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.
updater.InstallUpdate (cognitive 17) go/updater/updater_install.go:43— updater.InstallUpdate has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2. 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.
ysm.fallbackWalkDir (cognitive 17) go/ysm/extracted.go:386— ysm.fallbackWalkDir has cognitive complexity 17 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 1 (nesting depth added 6). None of this is in the body itself: all 17 points belong to one function literal inside it that branches (line 390). 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.
ysm.modsTomlDeclares (cognitive 17) go/ysm/ysm.go:67— ysm.modsTomlDeclares 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.
app.decodeYSMComponentsViaWASI (cognitive 17) internal/app/wasm_decoder.go:160— app.decodeYSMComponentsViaWASI has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (9 pts), loops 4 (7 pts), boolean chains 1 (nesting depth added 6). 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 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.
App.findMoveRoot (cognitive 17) internal/app/app_files.go:146— App.findMoveRoot has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (14 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.
App.startProxy (cognitive 17) REDACTED:263— App.startProxy has cognitive complexity 17 (threshold 15). Drivers by points: if/else 12 (14 pts), boolean chains 3 (nesting depth added 2). Of this number, 10 points are the body's own statements and 7 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.
DownloadQueue.consume (cognitive 17) internal/app/install/queue.go:192— DownloadQueue.consume has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (13 pts), match/switch 1 (2 pts), boolean chains 1, loops 1 (nesting depth added 6). 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.
animation.finalizeClipLengthAndEnqueue (cognitive 17) REDACTED:509— animation.finalizeClipLengthAndEnqueue has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (12 pts), loops 2 (3 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.
ysm-header.collectLooseAnims (cognitive 17) frontend/src/parsers/ysm-header.ts:748— ysm-header.collectLooseAnims has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (10 pts), loops 3 (6 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.
vmd-retarget.resolveVmdBindings (cognitive 17) frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts:429— vmd-retarget.resolveVmdBindings has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (9 pts), boolean chains 3, ternaries 3, loops 2 (nesting depth added 5). 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 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.
vrm-adapter.Stage4MenuPanels (cognitive 17) frontend/src/preview-3d/adapters/vrm/vrm-adapter.ts:405— vrm-adapter.Stage4MenuPanels has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 3, ternaries 2 (nesting depth added 6). Most of this is not in the body itself: 3 of the 17 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 491, 445, 482, …). 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.
vrm-bone-ui.makeBonePanelRenderer.<returned closure> (cognitive 17) frontend/src/preview-3d/adapters/vrm/vrm-bone-ui.ts:61— vrm-bone-ui.makeBonePanelRenderer.<returned closure> has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 3, ternaries 3, loops 1 (nesting depth added 2). Most of this is not in the body itself: 2 of the 17 points are its own statements and the rest belongs to 4 function items inside it that branch (renderList, renderDetail, onPick, …). 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.
ysm-preview-pipeline.fillAuthorsAsync (cognitive 17) frontend/src/preview-3d/adapters/ysm-preview-pipeline.ts:293— ysm-preview-pipeline.fillAuthorsAsync has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (8 pts), boolean chains 5, error handling 2 (4 pts) (nesting depth added 4). Of this number, 14 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.
env-pixels.customHdrThumbnail (cognitive 17) frontend/src/preview-3d/caps/env-pixels.ts:106— env-pixels.customHdrThumbnail has cognitive complexity 17 (threshold 15). Drivers by points: loops 4 (10 pts), if/else 4 (6 pts), boolean chains 1 (nesting depth added 8). 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.
ShadowCapability.collectLights (cognitive 17) frontend/src/preview-3d/caps/shadow-capability.ts:255— ShadowCapability.collectLights has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (14 pts), 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.
postproc-cost-probe.runPostprocCostProbe (cognitive 17) frontend/src/preview-3d/infra/postproc-cost-probe.ts:368— postproc-cost-probe.runPostprocCostProbe has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (6 pts), ternaries 4 (5 pts), boolean chains 3, loops 3 (nesting depth added 3). 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.
unified-pick.makeUnifiedPickHandler.handle (cognitive 17) frontend/src/preview-3d/infra/unified-pick.ts:29— unified-pick.makeUnifiedPickHandler.handle has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (14 pts), 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.
unload-model.unloadModel (cognitive 17) frontend/src/preview-3d/infra/unload-model.ts:32— unload-model.unloadModel has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11 (14 pts), loops 2, boolean chains 1 (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.
display.parseModelName (cognitive 17) REDACTED:59— display.parseModelName has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 7 (8 pts), boolean chains 5, if/else 3 (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.
model2d-draw.computeBounds (cognitive 17) frontend/src/views/app-preview/model2d/model2d-draw.ts:367— model2d-draw.computeBounds has cognitive complexity 17 (threshold 15). Drivers by points: if/else 4 (12 pts), loops 2 (3 pts), boolean chains 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.
ysm-parser.decodeYsmFile (cognitive 17) frontend/src/wasm/ysm-parser.ts:169— ysm-parser.decodeYsmFile has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 1, 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.
dedup.collectFiles (cognitive 16) go/dedup/dedup.go:73— dedup.collectFiles has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 2 (nesting depth added 4). None of this is in the body itself: all 16 points belong to one function literal inside it that branches (line 78). 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.
fsutil.DisabledAncestorPath (cognitive 16) go/fsutil/disabled_counterpart.go:70— fsutil.DisabledAncestorPath has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), loops 2 (3 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.
geometry.parsePlayerTextures (cognitive 16) go/geometry/ysm_parser.go:98— geometry.parsePlayerTextures has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (13 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.
installer.validateInstallPaths (cognitive 16) go/installer/installer.go:77— installer.validateInstallPaths has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (16 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.
installer.installSingleDirEntry (cognitive 16) go/installer/installer_dir.go:281— installer.installSingleDirEntry has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 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.
installer.IsValidRepoRoot (cognitive 16) go/installer/installer_file.go:250— installer.IsValidRepoRoot has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 4, loops 2 (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.
launcher.findJSONString (cognitive 16) go/launcher/detect.go:327— launcher.findJSONString has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (11 pts), loops 2 (4 pts), match/switch 1 (nesting depth added 9). 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.
litematic.ParseMeta (cognitive 16) go/litematic/parser.go:30— litematic.ParseMeta has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12 (15 pts), boolean chains 1 (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.
Watcher.syncAll (cognitive 16) go/watcher/watcher.go:315— Watcher.syncAll has cognitive complexity 16 (threshold 15). Drivers by points: if/else 11 (13 pts), boolean chains 2, loops 1 (nesting depth added 2). Of this number, 13 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.
ysm.extractTexSizeFromZipGeo (cognitive 16) go/ysm/summary.go:281— ysm.extractTexSizeFromZipGeo has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (12 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.
ysmwasi.readOutBuf (cognitive 16) go/ysmwasi/ysmwasi.go:202— ysmwasi.readOutBuf has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 1, 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.
app.orderTexByYSM (cognitive 16) internal/app/texture_order.go:150— app.orderTexByYSM has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 3 (4 pts), boolean chains 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.
App.importModelFileWithSubpath (cognitive 16) internal/app/app_install_import.go:161— App.importModelFileWithSubpath has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14 (15 pts), boolean chains 1 (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.
main.run (cognitive 16) go/wasispike/main.go:34— main.run has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14 (15 pts), loops 1 (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.
render.updateStat (cognitive 16) frontend/src/views/app-tree/render.ts:821— render.updateStat has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 5 (nesting depth added 3). 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, 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.
events.atTeClickRowFile (cognitive 16) frontend/src/views/app-tree/events.ts:226— events.atTeClickRowFile has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 3, loops 1 (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.
AppTree._renderTree (cognitive 16) frontend/src/views/app-tree/index.ts:590— AppTree._renderTree has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 3, loops 1 (2 pts), 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.
workshop-site-opener.bindSiteEvents (cognitive 16) frontend/src/views/app-content/site/workshop-site-opener.ts:92— workshop-site-opener.bindSiteEvents has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10 (11 pts), error handling 3 (4 pts), boolean chains 1 (nesting depth added 2). None of this is in the body itself: all 16 points belong to 5 function items inside it that branch (a function literal at line 146, a function literal at line 117, a function literal at line 98, …). 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.
skeleton.loadModel2D (cognitive 16) frontend/src/views/app-preview/skeleton.ts:46— skeleton.loadModel2D has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, error handling 2, boolean chains 1. Of this number, 9 points are the body's own statements and 7 belong to 6 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.
pack-meta.parsePackMetaJson (cognitive 16) frontend/src/parsers/pack-meta.ts:107— pack-meta.parsePackMetaJson has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (7 pts), boolean chains 4, ternaries 3, error handling 1, loops 1 (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.
pack-meta.parseShaderpackLang (cognitive 16) frontend/src/parsers/pack-meta.ts:152— pack-meta.parseShaderpackLang has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 3, 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.
mount-session.teardown (cognitive 16) frontend/src/preview-3d/adapters/mount-session.ts:213— mount-session.teardown has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9 (10 pts), loops 3 (4 pts), boolean chains 2 (nesting depth added 2). 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.
litematic-adapter.buildBlockMesh (cognitive 16) frontend/src/preview-3d/adapters/litematic-adapter.ts:183— litematic-adapter.buildBlockMesh has cognitive complexity 16 (threshold 15). Drivers by points: if/else 3 (8 pts), loops 4 (8 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.
pack-model-adapter.buildModelGroup (cognitive 16) frontend/src/preview-3d/adapters/pack-model-adapter.ts:190— pack-model-adapter.buildModelGroup has cognitive complexity 16 (threshold 15). Drivers by points: loops 6 (13 pts), if/else 2 (3 pts) (nesting depth added 8). 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.
EnvIbl.build (cognitive 16) frontend/src/preview-3d/caps/env-ibl.ts:223— EnvIbl.build has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 4, match/switch 1, ternaries 1 (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.
environment-capability.applyEnvIntensity (cognitive 16) frontend/src/preview-3d/caps/environment-capability.ts:72— environment-capability.applyEnvIntensity has cognitive complexity 16 (threshold 15). Drivers by points: if/else 3 (8 pts), loops 2 (3 pts), ternaries 2 (3 pts), boolean chains 2 (nesting depth added 7). Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs 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.
GroundOverlay.refresh (cognitive 16) frontend/src/preview-3d/caps/ground-overlay.ts:49— GroundOverlay.refresh has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (13 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.
light-persist.restoreLightParams (cognitive 16) frontend/src/preview-3d/caps/light-persist.ts:127— light-persist.restoreLightParams has cognitive complexity 16 (threshold 15). Drivers by points: if/else 12 (13 pts), boolean chains 3 (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.
water-shader.assembleWaveShader.<returned closure> (cognitive 16) frontend/src/preview-3d/caps/water-shader.ts:48— water-shader.assembleWaveShader.<returned closure> has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 6 (12 pts), boolean chains 2, if/else 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.
SceneCapabilityRegistry.topoLoadOrder (cognitive 16) frontend/src/preview-3d/caps/scene-capability-registry.ts:230— SceneCapabilityRegistry.topoLoadOrder has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 3 (5 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.
SceneRegistry.register (cognitive 16) frontend/src/preview-3d/infra/scene-registry.ts:155— SceneRegistry.register has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (9 pts), loops 3 (7 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.
menu-graph.collectMenuGraph (cognitive 16) frontend/src/preview-3d/menu/engine/menu-graph.ts:155— menu-graph.collectMenuGraph has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (7 pts), error handling 2 (4 pts), loops 3, boolean chains 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.
model-group-builder.buildMeshesFromCubes (cognitive 16) frontend/src/preview-3d/model/model-group-builder.ts:229— model-group-builder.buildMeshesFromCubes has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (11 pts), loops 2 (3 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.
pack-format.describeVersionRange (cognitive 16) frontend/src/utils/format/pack-format.ts:30— pack-format.describeVersionRange has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (9 pts), ternaries 2 (4 pts), boolean chains 3 (nesting depth added 5). 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, 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.
perf-single-bench.singleBenchParsePayload (cognitive 16) frontend/src/views/app-content/diagnostics/perf-single-bench.ts:271— perf-single-bench.singleBenchParsePayload has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 5, loops 1 (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.
init.stgBindLinkMode (cognitive 16) frontend/src/views/app-content/settings/init.ts:266— init.stgBindLinkMode has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (8 pts), boolean chains 4, error handling 2 (4 pts) (nesting depth added 5). Most of this is not in the body itself: 3 of the 16 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 286, 282). 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.
stats.worker.statsOne (cognitive 16) frontend/src/workers/stats.worker.ts:72— stats.worker.statsOne has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 2, loops 1 (2 pts), error handling 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.
D22 · Internal API Consistency· `AppService.CachedCreatorAvatar` signals absence with `(T, error)` (an error when absent) where its 3 sibling single-key reads use a bare `T` (the zero value when absent) · ×1
`AppService.CachedCreatorAvatar` signals absence with `(T, error)` (an error when absent) where its 3 sibling single-key reads use a bare `T` (the zero value when absent) go/cli/appservice.go:76— 3 of 4 single-key reads of `AppService` return a bare `T` (the zero value when absent) (3 of 4). Siblings: AppService.AnalyzeYSMModel (go/cli/appservice.go:26); AppService.AnalyzeBedrockModel (go/cli/appservice.go:27); AppService.ExportModelStructureJSON (go/cli/appservice.go:28). Return a bare `T` (the zero value when absent) like its siblings. [rule A5]
D22 · Internal API Consistency· `importer.DetectContainerTypeFromBase64Tail` signals absence with comma-ok `(T, bool)` where its 3 sibling single-key reads use a nil `*T` · ×1
`importer.DetectContainerTypeFromBase64Tail` signals absence with comma-ok `(T, bool)` where its 3 sibling single-key reads use a nil `*T` go/importer/detect_tail.go:36— 3 of 4 single-key reads of `package importer` return a nil `*T` (3 of 4). Siblings: importer.Get (go/importer/importer.go:44); importer.NewSimpleCopy (go/importer/importer.go:124); importer.NewDirectoryCopy (go/importer/importer.go:195). Return a nil `*T` like its siblings. [rule A5]
D22 · Internal API Consistency· `registry.SubDirAll` returns a map (`map[K]V`) where its 9 siblings return a slice (`[]T`) · ×1
`registry.SubDirAll` returns a map (`map[K]V`) where its 9 siblings return a slice (`[]T`) go/types/registry/extensions.go:460— 9 of 10 collection-returning members of `package registry` return a slice (`[]T`) (9 of 10). Siblings: registry.AllExts (go/types/registry/extensions.go:67); registry.ContainerExts (go/types/registry/extensions.go:91); registry.DisableSuffixes (go/types/registry/extensions.go:175); registry.ExtBelongsToBy (go/types/registry/extensions.go:338); registry.SupportedExtsForSubtype (go/types/registry/extensions.go:367). Return a slice (`[]T`). [rule A4]
D22 · Internal API Consistency· `registry.RegistryType` signals absence with a nil `*T` where its 13 sibling single-key reads use a bare `T` (the zero value when absent) · ×1
`registry.RegistryType` signals absence with a nil `*T` where its 13 sibling single-key reads use a bare `T` (the zero value when absent) go/types/registry/resource_lookup.go:32— 13 of 14 single-key reads of `package registry` return a bare `T` (the zero value when absent) (13 of 14). Siblings: registry.StripDisableSuffix (go/types/registry/extensions.go:182); registry.StripBanSuffix (go/types/registry/extensions.go:193); registry.StripDisableSuffixSegments (go/types/registry/extensions.go:203); registry.NormalizeResourceName (go/types/registry/extensions.go:231); registry.MatchZipEntry (go/types/registry/extensions.go:305). Return a bare `T` (the zero value when absent) like its siblings. [rule A5]
ClassTooLong: AppTree frontend/src/views/app-tree/index.ts:117— ClassTooLong — 444 significant lines (blank, comment-only and punctuation-only lines excluded), 28 methods. The bar is 400 significant lines; this is 44 over it, 1.11× 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.
D4 · Code Duplication· Edited copy of a member (78 corresponding lines) · ×1
Edited copy of a member (78 corresponding lines) go/scanner/scanner_browse.go:92— go/scanner/scanner_browse.go:92-169 | go/scanner/scanner_scan.go:47-136 — These two members are one piece of code written twice and then edited apart: 78 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (27 corresponding lines) · ×1
Edited copy of a member (27 corresponding lines) go/geometry/maid_l0_resolve.go:105— go/geometry/maid_l0_resolve.go:105-134 | go/geometry/maid_l0_resolve.go:140-166 — These two members are one piece of code written twice and then edited apart: 27 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (41 corresponding lines) · ×1
Edited copy of a member (41 corresponding lines) go/importer/importer.go:130— go/importer/importer.go:130-176 | go/importer/importer.go:204-244 — These two members are one piece of code written twice and then edited apart: 41 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (29 corresponding lines) · ×1
Edited copy of a member (29 corresponding lines) go/ysm/texsize.go:60— go/ysm/texsize.go:60-92 | go/ysm/texsize.go:98-126 — These two members are one piece of code written twice and then edited apart: 29 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (28 corresponding lines) · ×1
Edited copy of a member (28 corresponding lines) go/sync/sync_discovery.go:59— go/sync/sync_discovery.go:59-86 | go/sync/sync_discovery.go:89-119 — These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (30 corresponding lines) · ×1
Edited copy of a member (30 corresponding lines) go/geometry/maid_l0.go:105— go/geometry/maid_l0.go:105-134 | go/geometry/maid_l0.go:140-170 — These two members are one piece of code written twice and then edited apart: 30 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (31 corresponding lines) · ×1
Edited copy of a member (31 corresponding lines) go/avatar/avatar_extract_container.go:76— go/avatar/avatar_extract_container.go:76-106 | go/avatar/avatar_extract_ysm.go:115-158 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (16 corresponding lines) · ×1
Edited copy of a member (16 corresponding lines) go/types/registry/findinst.go:13— go/types/registry/findinst.go:13-28 | go/types/registry/findinst.go:33-48 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copies of one member (3 members, 17+ corresponding lines) · ×1
Edited copies of one member (3 members, 17+ corresponding lines) go/geometry/archive_collect.go:101— go/geometry/archive_collect.go:101-117 | go/geometry/archive_collect.go:122-140 | go/geometry/archive_collect.go:145-162 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 17 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication· Edited copies of one member (4 members, 19+ corresponding lines) · ×1
Edited copies of one member (4 members, 19+ corresponding lines) internal/app/app_install_instance.go:411— internal/app/app_install_instance.go:411-432 | internal/app/app_install_instance.go:437-458 | internal/app/app_install_instance.go:479-497 | internal/app/app_install_instance.go:500-518 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 19 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication· Edited copy of a member (24 corresponding lines) · ×1
Edited copy of a member (24 corresponding lines) go/litematic/nbt.go:198— go/litematic/nbt.go:198-221 | go/litematic/nbt.go:224-250 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copies of one member (3 members, 9+ corresponding lines) · ×1
Edited copies of one member (3 members, 9+ corresponding lines) go/ccheck/ccheck.go:225— go/ccheck/ccheck.go:225-234 | go/ccheck/ccheck.go:237-246 | go/ccheck/ccheck.go:259-267 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication· Edited copy of a member (11 corresponding lines) · ×1
Edited copy of a member (11 corresponding lines) go/avatar/avatar.go:204— go/avatar/avatar.go:204-215 | go/avatar/avatar_extract.go:121-131 — These two members are one piece of code written twice and then edited apart: 11 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Duplicated block (14–22 lines × 2) go/scanner/scanner_browse.go:93— go/scanner/scanner_browse.go:93-106 | go/scanner/scanner_scan.go:48-69 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (19–21 lines × 2) internal/app/app_install_instance.go:41— internal/app/app_install_instance.go:41-59 | internal/app/app_install_instance.go:78-98 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `internal/app/app_install_instance.go:41` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (13–16 lines × 2) go/sync/sync_dirlevel.go:52— go/sync/sync_dirlevel.go:52-67 | go/sync/sync_dirlevel.go:228-240 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/sync/sync_dirlevel.go:52` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (14–15 lines × 2) go/geometry/archive_merge.go:218— go/geometry/archive_merge.go:218-231 | internal/app/wasm_decoder.go:93-107 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `go/geometry/archive_merge.go:218` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Check import visibility before settling on that home: `internal/app/wasm_decoder.go` sits under a restricted `internal` directory, which only code inside its own subtree is permitted to import from — so it is reachable from some of these sites and not from others, and being able to see the copies is not the same as being allowed to share them. The home has to be somewhere every one of these sites is permitted to import from; if there is no such place, that restriction may be exactly why the copies are separate.
Duplicated block (13–15 lines × 2) go/sync/sync_push.go:81— go/sync/sync_push.go:81-95 | go/sync/sync_push.go:101-113 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/sync/sync_push.go:81` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (13–14 lines × 3) go/ysm/summary.go:286— go/ysm/summary.go:286-298 | go/ysm/texsize.go:76-89 | go/ysm/texsize.go:110-123 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `go/ysm/summary.go:286` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (13–14 lines × 2) internal/app/app_model.go:267— internal/app/app_model.go:267-280 | internal/app/app_model.go:366-378 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (10 lines × 2) go/sync/sync_discovery.go:61— go/sync/sync_discovery.go:61-70 | go/sync/sync_discovery.go:90-99 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `go/sync/sync_discovery.go:61` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (9 lines × 3) go/cli/instance.go:85— go/cli/instance.go:85-93 | go/cli/instance.go:106-114 | go/cli/instance.go:127-135 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
End-of-life runtime: Node.js 14 scripts/_lib/vendor/yaml/package.json:95— scripts/_lib/vendor/yaml/package.json declares Node.js 14 as this project's engines.node, and Node.js 14, support ended 2023-04-30. An unsupported runtime receives no security patches, so every vulnerability disclosed in it since 2023-04-30 is present and unfixable without moving off it. This is a migration rather than an upgrade: there is no newer release of a runtime that has ended.
Low cohesion: App (LCOM4 27) internal/app/app.go:43— App's methods fall into 27 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 27 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
IC1 · Incompleteness & stubs· Guard cannot change the result · ×1
Guard cannot change the result — returns what the code already falls through to frontend/src/preview-3d/decoder/utils.ts:122— The guard above `return bytes;` also returns `bytes`, so no input can make it matter. Implement the distinction that was intended, or delete the guard.
P12 · CI test-gate honesty· Test failure does not fail the CI gate · ×1
Test failure does not fail the CI gate REDACTED:695— `continue-on-error: true` lets the step or job that runs `pnpm exec playwright test --config playwright.coverage.config.ts` fail without failing the pipeline — the suite can go red and the change still merges. Remove it from the test step, or quarantine the specific failing tests instead.
Duplication concentrated across 6 sibling directories (16 clone groups) frontend/src/features/import/collector.ts:17— 16 duplicated blocks under frontend/src/ have copies in at least two of the sibling directories backend, features, parsers, preview-3d, utils, views — 9 of them are reported below, and 7 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.
Duplication concentrated across 8 sibling directories (12 clone groups) frontend/src/preview-3d/bone/bone-raycast.ts:155— 12 duplicated blocks under frontend/src/preview-3d/ have copies in at least two of the sibling directories adapters, bone, caps, infra, menu, mesh (+2 more sibling(s) not listed) — 6 of them are reported below, and 6 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 12 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 12 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 12 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.
Duplication concentrated across 7 sibling directories (6 clone groups) frontend/src/views/app-sync-manager/renderer.ts:326— 6 duplicated blocks under frontend/src/views/ have copies in at least two of the sibling directories app-content, app-nav, app-preview, app-sidebar, app-sync-manager, app-toast (+1 more sibling(s) not listed) — 5 of them are reported below, and 1 is 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.
Duplication concentrated across 2 sibling directories (5 clone groups) frontend/src/preview-3d/mesh/quaternion.ts:41— 5 duplicated blocks under the repository root have copies in at least two of the sibling directories frontend, scripts — 4 of them are reported below, and 1 is 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 (190 matched lines × 2 locations) · ×1
Duplicated block with local edits (190 matched lines × 2 locations) scripts/check-complexity.ts:90— scripts/check-complexity.ts:90 · scripts/check-params.ts:72 — the two spans are one implementation copied and then locally edited — 1291 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 (128 matched lines × 2 locations) · ×1
Duplicated block with local edits (128 matched lines × 2 locations) scripts/check-singleton-hygiene.ts:168— scripts/check-singleton-hygiene.ts:168 · scripts/check-worker-lifecycle.ts:130 — the two spans are one implementation copied and then locally edited — 939 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 (92 matched lines × 2 locations) · ×1
Duplicated block with local edits (92 matched lines × 2 locations) frontend/src/preview-3d/caps/ground-capability.ts:571— frontend/src/preview-3d/caps/ground-capability.ts:571 · frontend/src/preview-3d/caps/water-capability.ts:308 — the two spans are one implementation copied and then locally edited — 583 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 (83 matched lines × 2 locations) · ×1
Duplicated block with local edits (83 matched lines × 2 locations) scripts/i18n-frozen-t-check.ts:59— scripts/i18n-frozen-t-check.ts:59 · scripts/i18n-ui-check.ts:85 — the two spans are one implementation copied and then locally edited — 720 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 (71 lines × 2 locations) scripts/check-menu-test-layout.ts:245— scripts/check-menu-test-layout.ts:245 · scripts/check-singleton-hygiene.ts:180 — 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.
Duplicated block (60 lines × 2 locations) scripts/check-singleton-hygiene.ts:195— scripts/check-singleton-hygiene.ts:195 · scripts/check-vitest-assert-quality.ts:312 — 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 (57 matched lines × 2 locations) · ×1
Duplicated block with local edits (57 matched lines × 2 locations) scripts/check-vitest-assert-quality.ts:377— scripts/check-vitest-assert-quality.ts:377 · scripts/check-worker-lifecycle.ts:256 — the two spans are one implementation copied and then locally edited — 430 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 (55 lines × 2 locations) scripts/_lib/css-layer-utils.ts:143— scripts/_lib/css-layer-utils.ts:143 · scripts/css-token-check.ts:57 — 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 with local edits (53 matched lines × 2 locations) · ×1
Duplicated block with local edits (53 matched lines × 2 locations) scripts/_attic/check-naming-blacktalk.ts:54— scripts/_attic/check-naming-blacktalk.ts:54 · scripts/check-boolean-naming.ts:151 — the two spans are one implementation copied and then locally edited — 329 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 (51 matched lines × 2 locations) · ×1
Duplicated block with local edits (51 matched lines × 2 locations) scripts/check-dynamic-import.ts:79— scripts/check-dynamic-import.ts:79 · scripts/check-tpl-refs.ts:93 — the two spans are one implementation copied and then locally edited — 338 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 (50 matched lines × 2 locations) · ×1
Duplicated block with local edits (50 matched lines × 2 locations) scripts/gen-routes-quick.ts:291— scripts/gen-routes-quick.ts:291 · scripts/gen-routes.ts:194 — the two spans are one implementation copied and then locally edited — 400 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 (47 matched lines × 2 locations) · ×1
Duplicated block with local edits (47 matched lines × 2 locations) scripts/check-cap-enabled-duality.ts:31— scripts/check-cap-enabled-duality.ts:31 · scripts/check-env-schema-consumers.ts:34 — the two spans are one implementation copied and then locally edited — 354 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 (46 matched lines × 2 locations) · ×1
Duplicated block with local edits (46 matched lines × 2 locations) frontend/src/wasm/ysm-parser.ts:113— frontend/src/wasm/ysm-parser.ts:113 · frontend/src/wasm/ysm-worker-loader.ts:201 — the two spans are one implementation copied and then locally edited — 289 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 (41 matched lines × 2 locations) · ×1
Duplicated block with local edits (41 matched lines × 2 locations) scripts/check-diff-coverage.ts:186— scripts/check-diff-coverage.ts:186 · scripts/check-go-diff-coverage.ts:627 — the two spans are one implementation copied and then locally edited — 293 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 (39 matched lines × 2 locations) · ×1
Duplicated block with local edits (39 matched lines × 2 locations) frontend/src/views/app-sidebar/sidebar-pull.ts:74— frontend/src/views/app-sidebar/sidebar-pull.ts:74 · frontend/src/views/app-sidebar/sidebar-push.ts:178 — the two spans are one implementation copied and then locally edited — 221 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 (29 lines × 2 locations) artifacts/ground-design-probe/mock-3d.mjs:13— artifacts/ground-design-probe/mock-3d.mjs:13 · artifacts/ground-design-probe/render-tiles.mjs:32 — 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 (24 matched lines × 2 locations) · ×1
Duplicated block with local edits (24 matched lines × 2 locations) frontend/src/views/app-tree/bus-handlers.ts:362— frontend/src/views/app-tree/bus-handlers.ts:362 · frontend/src/views/app-tree/events.ts:474 — the two spans are one implementation copied and then locally edited — 199 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 (24 lines × 2 locations) frontend/src/views/app-tree/row-tpl-list.ts:28— frontend/src/views/app-tree/row-tpl-list.ts:28 · frontend/src/views/app-tree/row-tpl.ts:46 — 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.
Duplicated block (24 lines × 3 locations) scripts/check-menu-test-layout.ts:345— scripts/check-menu-test-layout.ts:345 · scripts/check-singleton-hygiene.ts:277 · scripts/check-worker-lifecycle.ts:287 — the 3 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. There is one copy in each of 3 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 (23 matched lines × 2 locations) · ×1
Duplicated block with local edits (23 matched lines × 2 locations) frontend/src/preview-3d/menu/render/cap-controls.ts:358— frontend/src/preview-3d/menu/render/cap-controls.ts:358 · frontend/src/preview-3d/menu/render/cap-controls.ts:403 — the two spans are one implementation copied and then locally edited — 177 tokens are still identical, in the same order in both spans, 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 (20 lines × 2 locations) scripts/check-design-tokens.ts:603— scripts/check-design-tokens.ts:603 · scripts/check-i18n-unused.ts:157 — 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.
Complex function iterateExp (cyclomatic 125, cognitive 82) frontend/src/utils/animation/molang-lib/molang.js:400— iterateExp has cyclomatic complexity 125 and cognitive complexity 82; 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.
Complex function validate (cyclomatic 120, cognitive 221) tests/test_resource_schema.ts:43— validate has cyclomatic complexity 120 and cognitive complexity 221; 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.
Complex function iterateString (cyclomatic 110, cognitive 52) frontend/src/utils/animation/molang-lib/molang.js:109— iterateString has cyclomatic complexity 110 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 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 main (cyclomatic 93, cognitive 157) · ×1
Complex function main (cyclomatic 93, cognitive 157) scripts/check-go-diff-coverage.ts:623— main has cyclomatic complexity 93 and cognitive complexity 157; 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 main (cyclomatic 81, cognitive 156) · ×1
Complex function main (cyclomatic 81, cognitive 156) scripts/check-layering.ts:384— main has cyclomatic complexity 81 and cognitive complexity 156; 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.
Complex function findFunctionEnd (cyclomatic 74, cognitive 198) scripts/line-counter.ts:122— findFunctionEnd has cyclomatic complexity 74 and cognitive complexity 198; 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 main (cyclomatic 64, cognitive 122) · ×1
Complex function main (cyclomatic 64, cognitive 122) REDACTED:58— main has cyclomatic complexity 64 and cognitive complexity 122; 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 main (cyclomatic 51, cognitive 70) · ×1
Complex function main (cyclomatic 51, cognitive 70) scripts/pre-push-gate.ts:123— main has cyclomatic complexity 51 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.
Complex function tokenize (cyclomatic 50, cognitive 138) scripts/auto-import-lexer.ts:288— tokenize has cyclomatic complexity 50 and cognitive complexity 138; 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.
Complex function buildModelTexMap (cyclomatic 47, cognitive 86) tests/port-verification/scan-cube-texslot.ts:49— buildModelTexMap has cyclomatic complexity 47 and cognitive complexity 86; 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 main (cyclomatic 46, cognitive 121) · ×1
Complex function main (cyclomatic 46, cognitive 121) scripts/gen-knowledge-autogen.ts:371— main has cyclomatic complexity 46 and cognitive complexity 121; 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 human (cyclomatic 44, cognitive 83) · ×1
Complex function human (cyclomatic 44, cognitive 83) scripts/audit-split.ts:222— human has cyclomatic complexity 44 and cognitive complexity 83; 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.
Complex function extractImports (cyclomatic 44, cognitive 76) scripts/check-orphan-exports.ts:103— extractImports has cyclomatic complexity 44 and cognitive complexity 76; 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.
Complex function findSites (cyclomatic 44, cognitive 70) scripts/codemod-bare-assert-noerror.ts:172— findSites has cyclomatic complexity 44 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.
Complex function htmlLiteralHits (cyclomatic 43, cognitive 87) scripts/check-layering.ts:229— htmlLiteralHits has cyclomatic complexity 43 and cognitive complexity 87; 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.
Complex function runFrontendDomain (cyclomatic 43, cognitive 51) scripts/_lib/gate-blocks/frontend-domain.ts:16— runFrontendDomain has cyclomatic complexity 43 and cognitive complexity 51; 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 main (cyclomatic 42, cognitive 73) · ×1
Complex function main (cyclomatic 42, cognitive 73) scripts/check-orphan-exports.ts:327— main has cyclomatic complexity 42 and cognitive complexity 73; 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.
Complex function renderMarkdown (cyclomatic 42, cognitive 72) REDACTED:522— renderMarkdown has cyclomatic complexity 42 and cognitive complexity 72; 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.
Complex function deriveAuthoritative (cyclomatic 42, cognitive 60) tests/port-verification/scan-texture-gap.ts:43— deriveAuthoritative has cyclomatic complexity 42 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.
Complex function findStrayCommentClose (cyclomatic 41, cognitive 78) scripts/_lib/css-layer-utils.ts:143— findStrayCommentClose has cyclomatic complexity 41 and cognitive complexity 78; 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 main (cyclomatic 41, cognitive 75) · ×1
Complex function main (cyclomatic 41, cognitive 75) scripts/jscpd-go.ts:113— main has cyclomatic complexity 41 and cognitive complexity 75; 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.
Complex function checkFile (cyclomatic 41, cognitive 63) scripts/auto-import-detect.ts:43— checkFile has cyclomatic complexity 41 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 main (cyclomatic 41, cognitive 47) · ×1
Complex function main (cyclomatic 41, cognitive 47) scripts/new-adr.ts:308— main has cyclomatic complexity 41 and cognitive complexity 47; 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 main (cyclomatic 40, cognitive 58) · ×1
Complex function main (cyclomatic 40, cognitive 58) scripts/check-diff-coverage.ts:182— main has cyclomatic complexity 40 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.
Complex function simulateArchiveGo (cyclomatic 39, cognitive 62) tests/port-verification/scan-texture-gap.ts:119— simulateArchiveGo has cyclomatic complexity 39 and cognitive complexity 62; 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.
Complex function runGoDomain (cyclomatic 38, cognitive 56) scripts/_lib/gate-blocks/go-domain.ts:36— runGoDomain has cyclomatic complexity 38 and cognitive complexity 56; 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.
Complex function codeAsserts (cyclomatic 38, cognitive 38) scripts/check-adr-drift.ts:86— codeAsserts has cyclomatic complexity 38 and cognitive complexity 38; 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.
Complex function fnHeaderName (cyclomatic 37, cognitive 65) REDACTED:295— fnHeaderName 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 human (cyclomatic 36, cognitive 82) · ×1
Complex function human (cyclomatic 36, cognitive 82) scripts/api-break.ts:210— human has cyclomatic complexity 36 and cognitive complexity 82; 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.
Complex function checkKnowledgeMeta (cyclomatic 36, cognitive 60) scripts/check-knowledge-drift.ts:153— checkKnowledgeMeta has cyclomatic complexity 36 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.
Complex function stripA11yNoise (cyclomatic 35, cognitive 67) scripts/check-a11y.ts:93— stripA11yNoise has cyclomatic complexity 35 and cognitive complexity 67; 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.
Complex function decodePng (cyclomatic 35, cognitive 55) scripts/_attic/translucency-probe.ts:31— decodePng has cyclomatic complexity 35 and cognitive complexity 55; 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 main (cyclomatic 35, cognitive 53) · ×1
Complex function main (cyclomatic 35, cognitive 53) scripts/check-complexity.ts:285— main has cyclomatic complexity 35 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.
Complex function analyze (cyclomatic 34, cognitive 44) scripts/_attic/trace-analyze.ts:90— analyze has cyclomatic complexity 34 and cognitive complexity 44; 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.
Complex function extractFunctions (cyclomatic 33, cognitive 81) scripts/line-counter.ts:312— extractFunctions has cyclomatic complexity 33 and cognitive complexity 81; 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.
Complex function scanTextFull (cyclomatic 33, cognitive 54) scripts/check-vitest-assert-quality.ts:209— scanTextFull has cyclomatic complexity 33 and cognitive complexity 54; 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.
Complex function scanModel (cyclomatic 33, cognitive 52) tests/port-verification/scan-non-main-uv.ts:197— scanModel has cyclomatic complexity 33 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.
R3 · Large Files· scripts/check-knowledge-drift.ts · ×1
scripts/check-knowledge-drift.ts: 1211 lines of code scripts/check-knowledge-drift.ts:1— scripts/check-knowledge-drift.ts has 1211 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/check-redlines.ts: 1116 lines of code scripts/check-redlines.ts:1— scripts/check-redlines.ts has 1116 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· frontend/src/preview-3d/state/env-state-schema.ts · ×1
frontend/src/preview-3d/state/env-state-schema.ts: 1030 lines of code frontend/src/preview-3d/state/env-state-schema.ts:1— frontend/src/preview-3d/state/env-state-schema.ts has 1030 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· frontend/src/settings-keys.ts · ×1
frontend/src/settings-keys.ts: 1012 lines of code frontend/src/settings-keys.ts:1— frontend/src/settings-keys.ts has 1012 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/check-go-diff-coverage.ts · ×1
scripts/check-go-diff-coverage.ts: 981 lines of code scripts/check-go-diff-coverage.ts:1— scripts/check-go-diff-coverage.ts has 981 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· frontend/src/views/app-tree/index.ts · ×1
frontend/src/views/app-tree/index.ts: 908 lines of code frontend/src/views/app-tree/index.ts:1— frontend/src/views/app-tree/index.ts has 908 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/port-align.ts: 907 lines of code scripts/port-align.ts:1— scripts/port-align.ts has 907 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· frontend/src/preview-3d/decoder/wasm-decode.ts · ×1
frontend/src/preview-3d/decoder/wasm-decode.ts: 904 lines of code frontend/src/preview-3d/decoder/wasm-decode.ts:1— frontend/src/preview-3d/decoder/wasm-decode.ts has 904 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: 864 lines of code REDACTED:1— REDACTED has 864 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· frontend/src/preview-3d/caps/sky-capability.ts · ×1
frontend/src/preview-3d/caps/sky-capability.ts: 860 lines of code frontend/src/preview-3d/caps/sky-capability.ts:1— frontend/src/preview-3d/caps/sky-capability.ts has 860 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· frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts · ×1
frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts: 834 lines of code frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts:1— frontend/src/preview-3d/adapters/vrm/vmd-retarget.ts has 834 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· frontend/src/preview-3d/adapters/ysm-adapter.ts · ×1
frontend/src/preview-3d/adapters/ysm-adapter.ts: 826 lines of code frontend/src/preview-3d/adapters/ysm-adapter.ts:1— frontend/src/preview-3d/adapters/ysm-adapter.ts has 826 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· frontend/src/parsers/ysm-header.ts · ×1
frontend/src/parsers/ysm-header.ts: 807 lines of code frontend/src/parsers/ysm-header.ts:1— frontend/src/parsers/ysm-header.ts has 807 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· frontend/src/views/app-tree/render.ts · ×1
frontend/src/views/app-tree/render.ts: 805 lines of code frontend/src/views/app-tree/render.ts:1— frontend/src/views/app-tree/render.ts has 805 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/check-design-tokens.ts · ×1
scripts/check-design-tokens.ts: 796 lines of code scripts/check-design-tokens.ts:1— scripts/check-design-tokens.ts has 796 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· frontend/src/preview-3d/menu/engine/core.ts · ×1
frontend/src/preview-3d/menu/engine/core.ts: 789 lines of code frontend/src/preview-3d/menu/engine/core.ts:1— frontend/src/preview-3d/menu/engine/core.ts has 789 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· frontend/src/preview-3d/caps/ground-capability.ts · ×1
frontend/src/preview-3d/caps/ground-capability.ts: 785 lines of code frontend/src/preview-3d/caps/ground-capability.ts:1— frontend/src/preview-3d/caps/ground-capability.ts has 785 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· frontend/src/preview-3d/adapters/mount-preview-core.ts · ×1
frontend/src/preview-3d/adapters/mount-preview-core.ts: 764 lines of code frontend/src/preview-3d/adapters/mount-preview-core.ts:1— frontend/src/preview-3d/adapters/mount-preview-core.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· frontend/src/preview-3d/adapters/vrm/vrm-adapter.ts · ×1
frontend/src/preview-3d/adapters/vrm/vrm-adapter.ts: 731 lines of code frontend/src/preview-3d/adapters/vrm/vrm-adapter.ts:1— frontend/src/preview-3d/adapters/vrm/vrm-adapter.ts has 731 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/token-shift-audit.ts · ×1
scripts/token-shift-audit.ts: 702 lines of code scripts/token-shift-audit.ts:1— scripts/token-shift-audit.ts has 702 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/css-layer-check.ts: 693 lines of code scripts/css-layer-check.ts:1— scripts/css-layer-check.ts has 693 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/line-counter.ts: 693 lines of code scripts/line-counter.ts:1— scripts/line-counter.ts has 693 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/check-layering.ts: 677 lines of code scripts/check-layering.ts:1— scripts/check-layering.ts has 677 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· frontend/src/preview-3d/menu/render/cap-controls.ts · ×1
frontend/src/preview-3d/menu/render/cap-controls.ts: 675 lines of code frontend/src/preview-3d/menu/render/cap-controls.ts:1— frontend/src/preview-3d/menu/render/cap-controls.ts has 675 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/probe-water-wave.ts · ×1
scripts/probe-water-wave.ts: 648 lines of code scripts/probe-water-wave.ts:1— scripts/probe-water-wave.ts has 648 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· frontend/src/preview-3d/caps/ground-surface-spec.ts · ×1
frontend/src/preview-3d/caps/ground-surface-spec.ts: 624 lines of code frontend/src/preview-3d/caps/ground-surface-spec.ts:1— frontend/src/preview-3d/caps/ground-surface-spec.ts has 624 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· frontend/src/preview-3d/caps/light-capability.ts · ×1
frontend/src/preview-3d/caps/light-capability.ts: 608 lines of code frontend/src/preview-3d/caps/light-capability.ts:1— frontend/src/preview-3d/caps/light-capability.ts has 608 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· frontend/src/preview-3d/caps/water-capability.ts · ×1
frontend/src/preview-3d/caps/water-capability.ts: 591 lines of code frontend/src/preview-3d/caps/water-capability.ts:1— frontend/src/preview-3d/caps/water-capability.ts has 591 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· frontend/src/utils/animation/molang-lib/molang.js · ×1
frontend/src/utils/animation/molang-lib/molang.js: 588 lines of code frontend/src/utils/animation/molang-lib/molang.js:1— frontend/src/utils/animation/molang-lib/molang.js has 588 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/gen-knowledge-autogen.ts · ×1
scripts/gen-knowledge-autogen.ts: 575 lines of code scripts/gen-knowledge-autogen.ts:1— scripts/gen-knowledge-autogen.ts has 575 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· frontend/src/views/app-tree/events.ts · ×1
frontend/src/views/app-tree/events.ts: 573 lines of code frontend/src/views/app-tree/events.ts:1— frontend/src/views/app-tree/events.ts has 573 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· frontend/src/preview-3d/adapters/litematic-adapter.ts · ×1
frontend/src/preview-3d/adapters/litematic-adapter.ts: 566 lines of code frontend/src/preview-3d/adapters/litematic-adapter.ts:1— frontend/src/preview-3d/adapters/litematic-adapter.ts has 566 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· frontend/src/backend/web-community.ts · ×1
frontend/src/backend/web-community.ts: 562 lines of code frontend/src/backend/web-community.ts:1— frontend/src/backend/web-community.ts has 562 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/check-menu-health.ts · ×1
scripts/check-menu-health.ts: 556 lines of code scripts/check-menu-health.ts:1— scripts/check-menu-health.ts has 556 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/codemod.ts: 543 lines of code scripts/codemod.ts:1— scripts/codemod.ts has 543 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· frontend/src/preview-3d/caps/shadow-capability.ts · ×1
frontend/src/preview-3d/caps/shadow-capability.ts: 539 lines of code frontend/src/preview-3d/caps/shadow-capability.ts:1— frontend/src/preview-3d/caps/shadow-capability.ts has 539 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· frontend/src/preview-3d/menu/render/render.ts · ×1
frontend/src/preview-3d/menu/render/render.ts: 538 lines of code frontend/src/preview-3d/menu/render/render.ts:1— frontend/src/preview-3d/menu/render/render.ts has 538 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· frontend/src/preview-3d/caps/environment-capability.ts · ×1
frontend/src/preview-3d/caps/environment-capability.ts: 537 lines of code frontend/src/preview-3d/caps/environment-capability.ts:1— frontend/src/preview-3d/caps/environment-capability.ts has 537 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· frontend/src/preview-3d/caps/postprocessing-composer.ts · ×1
frontend/src/preview-3d/caps/postprocessing-composer.ts: 531 lines of code frontend/src/preview-3d/caps/postprocessing-composer.ts:1— frontend/src/preview-3d/caps/postprocessing-composer.ts has 531 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: 527 lines of code REDACTED:1— REDACTED has 527 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· This package's lint script runs in no CI job · ×1
This package's lint script runs in no CI job package.json:19— The root package declares the lint script `lint:scripts` (`biome check scripts/`), but no step of this repository's CI runs it, by name, through another script, a Makefile target or a workspace runner, and no CI step runs the linter over the package itself. The rules it sets are enforced nowhere a pull request can fail. Run it in CI: a step that runs `npm run lint:scripts` in `.` (or the workspace's task runner).
Dead file (~339 LoC) frontend/harness/main.ts— no import path from any entry point (801 application, 351 tooling, 849 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 (~291 LoC) scripts/_attic/ai-mistake-tracker.ts— no import path from any entry point (801 application, 351 tooling, 849 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 (~80 LoC) artifacts/cleanup-creators-mojibake.cjs— no import path from any entry point (801 application, 351 tooling, 849 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 (~23 LoC) frontend/harness/mock-install.ts— no import path from any entry point (801 application, 351 tooling, 849 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (frontend/harness/main.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 (~14 LoC) check-test-paths.ts— no import path from any entry point (801 application, 351 tooling, 849 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 (~1 LoC) wasm_decoder_glue.js— no import path from any entry point (801 application, 351 tooling, 849 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
SC1 · Supply-chain hygiene· JavaScript dependencies are not locked · ×1
JavaScript dependencies are not locked scripts/_lib/vendor/yaml/package.json:71— scripts/_lib/vendor/yaml/package.json declares dependencies that no committed lockfile resolves — there is no REDACTED / yarn.lock / REDACTED / bun.lock beside it, and no locked workspace above it names it — so its installs aren't reproducible (SSDF PW.4.4). Commit its package manager's lockfile (or add it to the locked workspace) and install from it (`npm ci`, `yarn --immutable`, `pnpm i --frozen-lockfile` or `bun i --frozen-lockfile`). Advisory — never scored.
Mock-dominated test: SW 已控制当前页 → 不 reload(无论标记有无) frontend/src/workers/coi-sw.test.ts:81— This test sets up 3 test doubles (for example `a double assigned in a shared setup`) 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: 3D FAB:createLitematic3D 拒绝 → catch 兜底(无 unhandled rejection) frontend/src/views/app-preview/litematic-meta.test.ts:161— This test sets up 3 test doubles (for example `vi.spyOn`) 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: cooperate 跨类型 → 降级关旧开新:cleanupPreview + opener,不走 switchPreview frontend/src/views/app-preview/preview-library-cooperate.test.ts:55— 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: 显式 rtype 透传 → 不调 DetectResourceType(避免歧义扩展名重复探测) frontend/src/views/app-preview/preview-library-route.test.ts:65— This test sets up 4 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: DetectResourceType 抛错 → 不弹「后端不可用」,rtype 空串继续路由(扩展名兜底仍生效) frontend/src/views/app-preview/preview-library-route.test.ts:75— This test sets up 5 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: 容器兜底:routeKey=EntityPlayer(无 .zip 变体)→ 落该 rtype 默认预览适配器(mmd) frontend/src/views/app-preview/preview-library-route.test.ts:103— 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: 分支顺序:routeKey 为空串时先走扩展名兜底,不再下探容器默认适配器 frontend/src/views/app-preview/preview-library-route.test.ts:116— 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: 直查命中即用,不再下探兜底(routeKey 已注册) frontend/src/views/app-preview/preview-library-route.test.ts:127— 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: action 触发截图调用(saveScreenshot 被 mock,fire-and-forget) frontend/src/views/app-preview/ysm-controls.test.ts:83— This test sets up 3 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: FAB 点击:无最近模型 → 空场景 3D(openEmpty3DFullscreen,不弹 toast) frontend/src/views/app-nav/index.test.ts:346— This test sets up 4 test doubles (for example `vi.fn`) 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: FAB 点击:有最近模型 → openModel3DFullscreen(path);打开失败 → console.error + 错误 toast frontend/src/views/app-nav/index.test.ts:360— This test sets up 6 test doubles (for example `vi.spyOn`) against 1 real object(s) of its own, and its only verification is 5 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: 重绑先清旧 + 新 cleanup 经桶登记(ADR-260 行为口径) frontend/src/views/app-content/init-github.test.ts:367— This test sets up 4 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: 旧 cleanup reject → 不阻断新绑定(c7cd6363 模式回归) frontend/src/views/app-content/init-github.test.ts:399— 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: 桌面导入成功 → success toast 带站点数 + 触发列表重载(旧 TODO 清偿:导入即所见) frontend/src/views/app-content/site/workshop-site-opener.test.ts:342— 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: 导入 0 个 → 不触发重载(无变化不打扰) frontend/src/views/app-content/site/workshop-site-opener.test.ts:359— This test sets up 3 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: relink 有实例 → RelinkAllInstanceResources + 成功 toast frontend/src/views/app-content/settings/init.test.ts:397— 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: relink 多实例 → 逐实例增量进度 toast(末个不重发,ADR-296 D5) frontend/src/views/app-content/settings/init.test.ts:425— 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: 实例全被跳过(无 Exists / 无 Name)→ 「没有需要重新链接」toast 且不调 Relink frontend/src/views/app-content/settings/init.test.ts:1180— This test sets up 3 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: 导入顺序:读校验 → 磁盘落盘 → 浏览器回写(safeSet 晚于 ImportSettingsData) frontend/src/views/app-content/settings/settings-backup.test.ts:290— This test sets up 3 test doubles (for example `a double assigned in a shared setup`) against 0 real object(s) of its own, and its only verification is 5 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: 磁盘侧失败:浏览器偏好完全不写、不 emit(旧行为是写后再回滚) frontend/src/views/app-content/settings/settings-backup.test.ts:312— This test sets up 4 test doubles (for example `a double assigned in a shared setup`) 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: 用户取消文件选择:不读盘、不写盘、不 emit、不报错 frontend/src/views/app-content/settings/settings-backup.test.ts:329— This test sets up 4 test doubles (for example `a double assigned in a shared setup`) against 0 real object(s) of its own, and its only verification is 5 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: 用户取消导入确认:磁盘与浏览器都不动、不 emit(P1-①) frontend/src/views/app-content/settings/settings-backup.test.ts:370— This test sets up 5 test doubles (for example `a double assigned in a shared setup`) against 0 real object(s) of its own, and its only verification is 5 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: 用户取消恢复确认:不调 RestoreSettingsBackup、不 emit(P2-④) frontend/src/views/app-content/settings/settings-backup.test.ts:403— This test sets up 3 test doubles (for example `a double assigned in a shared setup`) 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: 无备份:提示 toast 且不调 RestoreSettingsBackup、不弹确认(P2-④) frontend/src/views/app-content/settings/settings-backup.test.ts:415— This test sets up 3 test doubles (for example `a double assigned in a shared setup`) 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: 扫描请求直传 strategy token(锐评①收口:不再 JSON 文本协议) frontend/src/views/app-content/diagnostics/dedup.test.ts:235— This test sets up 3 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.
Duplicated predicate go/avatar/avatar_extract_container.go:150— `!strings.HasPrefix(low, "avatar/") && !strings.Contains(low, "/avatar/")` appears character-identically in 2 files — go/avatar/avatar_extract_container.go, go/avatar/avatar_extract_ysm.go. 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 go/avatar/avatar_extract_container.go:122— `SafeName(au.Name) == safeName && au.Avatar != ""` appears character-identically in 2 files — go/avatar/avatar_extract_container.go, go/avatar/avatar_extract_ysm.go. 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 go/packs/classify.go:206— `ancNorm == cNorm || strings.HasSuffix(ancNorm, "/"+cNorm)` appears character-identically in 2 files — go/packs/classify.go, go/types/registry/location.go. 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 go/packs/classify.go:445— `d != "." && d != "" && d != string(filepath.Separator)` appears character-identically in 2 files — go/packs/classify.go, go/types/registry/location.go. 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 internal/app/container_entries.go:120— `e.IsDir() || !strings.EqualFold(e.Name(), entry)` appears character-identically in 2 files — internal/app/container_entries.go, internal/app/resourcepack_models.go. 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 go/fileops/fileops_enable.go:177— `err != nil || rel == "." || rel == ".." || strings.HasPrefix(rel, ".."+string(filepath.Separator))` appears character-identically in 3 files — go/fileops/fileops_enable.go, go/fsutil/disabled_counterpart.go, internal/app/resource_bindings.go. 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 go/cli/dedup.go:186— `err != nil || rel == ".." || strings.HasPrefix(rel, ".."+string(filepath.Separator))` appears character-identically in 2 files — go/cli/dedup.go, internal/app/app_install_recycle.go. 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 go/geometry/archive_collect.go:95— `maidNs != "" && !strings.HasPrefix(low, maidNs)` appears character-identically in 2 files — go/geometry/archive_collect.go, go/geometry/maid_l0.go. 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 go/packs/classify.go:45— `reg == nil || len(reg.ResourceTypes) == 0` appears character-identically in 2 files — go/packs/classify.go, internal/app/app_install_instance.go. 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 go/ysm/extracted.go:403— `relErr == nil && strings.Count(rel, string(filepath.Separator)) > 10` appears character-identically in 2 files — go/ysm/extracted.go, go/ysm/texsize.go. 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 go/download/download_downloader.go:60— `req.URL.Scheme != "https" && req.URL.Scheme != "http"` appears character-identically in 2 files — go/download/download_downloader.go, go/updater/updater_download.go. 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 go/geometry/archive_collect.go:56— `strings.Contains(low, "animation") || strings.Contains(low, "controller")` appears character-identically in 3 files — go/geometry/archive_collect.go, go/geometry/maid_l0.go, go/ysm/summary.go. 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 go/fileops/fileops_preview.go:141— `strings.HasSuffix(low, ".png") || strings.HasSuffix(low, ".jpg")` appears character-identically in 3 files — go/fileops/fileops_preview.go, go/geometry/archive_collect.go, go/geometry/maid_l0.go. 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 go/wasispike/main.go:168— `uint32(len(cwd)) > size || !mod.Memory().WriteString(buf, cwd)` appears character-identically in 2 files — go/wasispike/main.go, go/ysmwasi/ysmwasi.go. 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 scripts/check-dynamic-import.ts:89— `!/\.test\./.test(f) && !/\.spec\./.test(f)` appears character-identically in 2 files — scripts/check-dynamic-import.ts, scripts/check-tpl-refs.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 scripts/_lib/cli-registry.ts:134— `!f.endsWith(".go") || f.endsWith("_test.go")` appears character-identically in 2 files — scripts/_lib/cli-registry.ts, scripts/_lib/write-surface-gate.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 REDACTED:73— `(await ListVersionInstances(mcRoot)) || []` appears character-identically in 2 files — REDACTED, frontend/src/views/app-content/settings/init.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 scripts/_lib/changed-scope.ts:58— `(err.stdout || "").trim() || (err.stderr || "").trim()` appears character-identically in 2 files — scripts/_lib/changed-scope.ts, scripts/_lib/gate-resolve.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 scripts/check-singleton-hygiene.ts:179— `/\.(test|spec)\.tsx?$/.test(n) || /\.d\.ts$/.test(n)` appears character-identically in 2 files — scripts/check-singleton-hygiene.ts, scripts/check-worker-lifecycle.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 scripts/check-complexity.ts:277— `/\.(ts|js)$/.test(entry.name) && !/\.(test|spec)\.[jt]s$/.test(entry.name)` appears character-identically in 2 files — scripts/check-complexity.ts, scripts/check-params.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 scripts/check-design-tokens.ts:143— `Boolean(args.baseline) || Boolean(args["update-baseline"])` appears character-identically in 2 files — scripts/check-design-tokens.ts, scripts/check-i18n-unused.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 scripts/check-dynamic-import.ts:164— `a.file.localeCompare(b.file) || a.line - b.line` appears character-identically in 4 files — scripts/check-dynamic-import.ts, scripts/check-menu-test-layout.ts, scripts/check-tpl-refs.ts, scripts/check-vitest-assert-quality.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 scripts/auto-import.ts:63— `a.startsWith("--") && !KNOWN_FLAGS.has(a)` appears character-identically in 4 files — scripts/auto-import.ts, scripts/i18n-frozen-t-check.ts, scripts/i18n-ui-check.ts, scripts/link-checker.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 frontend/src/views/app-preview/model2d/model2d-draw.ts:64— `c.pivot || [x + sx / 2, y + sy / 2, z + sz / 2]` appears character-identically in 2 files — frontend/src/views/app-preview/model2d/model2d-draw.ts, frontend/src/views/app-preview/model2d/model2d-geom.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 frontend/src/preview-3d/decoder/wasm-decode.ts:900— `cause !== null && typeof cause === "object" && "Code" in cause` appears character-identically in 2 files — frontend/src/preview-3d/decoder/wasm-decode.ts, frontend/src/utils/dom/errors.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.
Silent fallback default on error go/avatar/avatar_extract.go:112— `modelSignature` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/fileops/fileops_preview.go:165— `GetPackInfo` turns a non-nil `err` into `return types.PackInfo{}` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/fsutil/format.go:27— `FileSize` turns a non-nil `err` into `return 0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/geometry/archive_parse.go:279— `parseModelFromArchive` turns a non-nil `err` into `return nil, nil, nil, nil` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/importer/importer_file.go:196— `DetectContainerType` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/instance/instance.go:276— `entrySize` turns a non-nil `err` into `return 0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/litematic/parser.go:166— `convertPreviewImage` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/packs/mcmeta.go:304— `ReadShaderpackLangParts` turns a non-nil `err` into `return "", map[string]string{}` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/scanner/scanner_scan.go:367— `ComputeFileHash` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/sync/sync.go:393— `relKey` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/sync/sync_dirlevel.go:280— `relKeyDirLevel` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/sync/sync_dirlevel_sync.go:201— `dirLevelRel` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/sync/sync_discovery.go:62— `listVanillaInstances` turns a non-nil `err` into `return []types.VersionInstance{}` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/sync/sync_discovery.go:91— `listPrismInstances` turns a non-nil `err` into `return []types.VersionInstance{}` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/ysm/header.go:314— `AnalyzeYSMHeader` turns a non-nil `err` into `return YSMHeader{}` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/ysm/parse.go:102— `countJSONArrayLen` turns a non-nil `err` into `return 0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/ysm/texsize.go:64— `readTexFromZip` turns a non-nil `err` into `return 0, 0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error go/ysm/texsize.go:102— `readTexFrom7z` turns a non-nil `err` into `return 0, 0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error internal/app/resourcepack_models.go:31— `packModelElementsCount` turns a non-nil `err` into `return 0` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error internal/app/pathmgr_android.go:28— `androidSandboxDir` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error internal/app/app_config.go:693— `ValidateMinecraftDir` turns a non-nil `err` into `return "", "路径格式错误"` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error internal/app/app_files.go:149— `findMoveRoot` turns a non-nil `err` into `return ""` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error internal/app/app_install_import.go:127— `DetectContainerType` turns a non-nil `err` into `return "unknown"` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error internal/app/app_model.go:56— `ExtractYSMHeaderFromBase64` turns a non-nil `err` into `return ysm.YSMHeader{}` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default on error internal/app/app_model.go:247— `analyzeBedrockModelUncached` turns a non-nil `err` into `return types.BedrockModel{}` — a failure becomes a plausible value and a silent behavior change with no trail. Log the error or return it. 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 `if` or in the doc comment, and the row stops firing.
Silent fallback default in catch frontend/src/views/app-preview/siblings.ts:39— `resolveSiblingsByType` 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 frontend/src/views/app-preview/siblings.ts:132— `resolveStageSiblings` 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 frontend/src/views/app-preview/preview-library.ts:111— `resolveRouteType` 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 frontend/src/views/app-preview/preview-library.ts:286— `scanModelsByType` 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 frontend/src/views/app-preview/litematic-3d.ts:88— `listContainerEntries` 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 frontend/src/views/app-preview/mmd-data-port.ts:22— `makeMmdDataPort.readFileBytesBatch` 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 frontend/src/views/app-preview/mmd-data-port.ts:38— `makeMmdDataPort.readFileBytesBatchWithMeta` 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 frontend/src/views/app-preview/mmd-data-port.ts:74— `makeMmdDataPort.hasCachedTextures` 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 frontend/src/backend/web-fs-bedrock.ts:225— `webExtractPreviewTexture` 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 frontend/src/backend/web-fs-bedrock.ts:470— `webAnalyzeBedrockModel` 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 frontend/src/backend/web-fs-bedrock.ts:515— `webAnalyzeBedrockModelEntry` 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 frontend/src/backend/web-fs-container.ts:54— `listWebContainerEntries` 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.
redundant comment frontend/src/features/context-menu/context-menus-async.test.ts:249— 5 comments in this file only repeat the code they sit on (lines 249, 264, 369, 421, 476), for example "── batch.copy-paths ──". Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment frontend/src/parsers/extract.test.ts:68— "local header offset" repeats the code it sits on: 3 of its 3 words (local, header, offset) are already in `cdeDv.setUint32(42, localHeaderOffset, true);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment frontend/src/preview-3d/adapters/mmd/mmd-pmx-parser.worker.test.ts:101— 6 comments in this file only repeat the code they sit on (lines 101, 105, 284, 285, 287, 289), for example "axis limit:0x0400". Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment frontend/src/preview-3d/caps/environment-capability.test.ts:1184— "customHdr folder" repeats the code it sits on: 3 of its 3 words (custom, hdr, folder) are already in `const hdrFolderTop = findNodeById(nodes, "cap-group-env-custom-hdr");`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment scripts/_lib/frontmatter.test.ts:108— "── parseSourceFiles ──" repeats the code it sits on: 3 of its 3 words (parse, source, files) are already in `test('parseSourceFiles block list', () =>`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
Subsumed condition operand scripts/check-type-safety.ts:218— `t.startsWith("*/")` can never decide this `||` — every value satisfying `t.startsWith("*/")` also satisfies `t.startsWith("*")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
Subsumed condition operand go/ysm/ysm.go:82— `strings.HasPrefix(trimmed, "[[")` can never decide this `||` — every value satisfying `strings.HasPrefix(trimmed, "[[")` also satisfies `strings.HasPrefix(trimmed, "[")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
Subsumed condition operand go/download/resolve_path_edge_test.go:209— `strings.Contains(savePath, "/main/")` can never decide this `||` — every value satisfying `strings.Contains(savePath, "/main/")` also satisfies `strings.Contains(savePath, "/main")`, so the `||` chain is already decided by the latter. The expression is equivalent to the chain without it, which means it is wider than it reads. Delete the dead operand, or narrow the surviving one if IT is the accident.
D26 · Project Cohesion· Projects may be oversized for their cohesion · ×2
Projects may be oversized for their cohesion frontend/package.json:1— `frontend` (137615 LoC, 1289 module-visible types across 90 directories) overshoots its size bounds. 2 of 4 build unit(s) (Gradle, npm) overshoot their size bounds, lowering Project Cohesion to 0.0/10. 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.
Projects may be oversized for their cohesion package.json:1— `(repository root)` (103677 LoC, 535 module-visible types across 56 directories) overshoots its size bounds. 2 of 4 build unit(s) (Gradle, npm) overshoot their size bounds, lowering Project Cohesion to 0.0/10. 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.
IC1 · Incompleteness & stubs· Empty method body · ×2
Empty method body frontend/src/preview-3d/adapters/ysm-preview-pipeline.ts:49— `appendDebug` has an empty body — confirm it's an intentional no-op and not an unfinished method.
Empty method body go/wasispike/probe.mjs:69— `emscripten_notify_memory_growth` has an empty body — confirm it's an intentional no-op and not an unfinished method.
Fat interface: AppService (49 methods) go/cli/appservice.go:16— `AppService` declares 49 methods: `ScanModelEntries`, `ScanModelEntriesForBrowse`, `SearchModels`, `ListModelAuthors`, `ScanLocalAuthors`, `AnalyzeYSMModel`, `AnalyzeBedrockModel`, `ExportModelStructureJSON`, `ReadFileBytes`, `ReadFileBytesBatch`, `LoadAppConfig`, `GetConfigPath`, `GetMinecraftPaths`, `SetDownloadMirror`, `SetSessionFilesRoot`, `RenameDir`, `RenameFile`, `MoveModelFile`, `CopyModelFile`, `ToggleModelEnable`, `InstallModelFile`, `InstallModelTo`, `SetLinkMode`, `GetLinkMode`, `ListVersionInstances`, `SyncResources`, `PushResourceToInstance`, `PullResourceFromInstance`, `ListRecycleBin`, `RestoreFromRecycle`, `EmptyRecycleBin`, `EnqueueDownloads`, `CancelQueue`, `QueueStatus`, `DownloadFromGitHub`, `AllTags`, `GetModelTags`, `SetModelTags`, `ListByTag`, `CachedCreatorAvatar`, and 9 more. Counted over the exported method specs the interface itself declares, once per name; an embedded interface is a role it composes, judged on its own declaration, and is not counted here. 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.
D21 · Naming Consistency· `matchZipEntryTS` spells `TS` where 15 names in the project spell it `Ts` · ×1
`matchZipEntryTS` spells `TS` where 15 names in the project spell it `Ts` frontend/src/utils/resource/types.ts:505— 15 of 16 names in project ysm-model-manager spell the token `Ts` (15 of 16; unit: names in project ysm-model-manager containing `Ts`). Peers: RendererHost._lastPerFrameWarnTs (frontend/src/preview-3d/infra/render-host.ts:92); RendererHost._lastRemoveMissWarnTs (frontend/src/preview-3d/infra/render-host.ts:101); toolbar-search.ensureTsBadgeStyles (frontend/src/views/app-tree/toolbar-search.ts:36); rtype-panel-gate.productionTsFiles (scripts/_lib/rtype-panel-gate.ts:66); check-file-lines.listTsFiles (scripts/check-file-lines.ts:174). Rename to `matchZipEntryTs`. [rule N6]
P3 · Security & performance tooling· Dependabot does not watch cargo/gradle · ×1
Dependabot does not watch cargo/gradle REDACTED:5— `REDACTED` schedules updates, but no `package-ecosystem` entry covers `cargo`, `gradle`, which this tree depends on — so those dependencies get no update pull requests and no advisory pressure, however complete the dep-scan credit looks. Add the missing entries to the `updates:` list.
Unused export 'FACE_KEYS' frontend/src/preview-3d/decoder/wasm-geometry.ts:65— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'SEMANTIC_MORPH_IDS' · ×1
Unused export 'SEMANTIC_MORPH_IDS' frontend/src/preview-3d/infra/semantic-morphs.ts:24— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'WorkerErrorStrategy' · ×1
Unused export 'WorkerErrorStrategy' frontend/src/preview-3d/infra/worker-bridge.ts:22— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'VrmMaterialControlBridge' · ×1
Unused export 'VrmMaterialControlBridge' frontend/src/views/app-preview/vrm-controls.ts:14— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused module-local declaration 'tileH' · ×1
Unused module-local declaration 'tileH' artifacts/ground-design-probe/render-tiles.mjs:123— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration 'started' · ×1
Unused module-local declaration 'started' go/wasispike/probe.mjs:41— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration '_TOTAL_RE' · ×1
Unused module-local declaration '_TOTAL_RE' scripts/_attic/perf-gate.ts:38— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration '_STAGE_ORDER' · ×1
Unused module-local declaration '_STAGE_ORDER' scripts/_attic/perf-gate.ts:40— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration 'LINES_RED' · ×1
Unused module-local declaration 'LINES_RED' scripts/audit-complexity-cross.ts:48— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration 'LINES_ORANGE' · ×1
Unused module-local declaration 'LINES_ORANGE' scripts/audit-complexity-cross.ts:49— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration '_statusRows' · ×1
Unused module-local declaration '_statusRows' scripts/check-adr-health.ts:50— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration 'applySite' · ×1
Unused module-local declaration 'applySite' scripts/codemod-bare-assert-noerror.ts:301— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration 'pad' · ×1
Unused module-local declaration 'pad' scripts/gen-docs-index.ts:66— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
R7 · Dead Code· Unused module-local declaration '_has' · ×1
Unused module-local declaration '_has' tests/verify-adr-042.ts:12— This top-level declaration is not exported and its name occurs nowhere else in its module — not called, read, typed against, re-exported or named by a string. Nothing outside the module can reach a non-exported binding, so this is the whole search: remove it, or use it.
X2 · Cancellation propagation· Not all functions that make a request accept a context.Context or an AbortSignal · ×1
Not all functions that make a request accept a context.Context or an AbortSignal — Only 5/9 functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http; net/http, net.Dial) accept a context.Context or an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, a cancelled request, a shutdown, an expired deadline. Take a `signal` (Go: `ctx context.Context`) 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.
Null assertions (`!`) override strict null checking — ~0.5 `!` null assertions per 1k TypeScript source lines — 77 assertion(s) across the 143113 source line(s) of the 637 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: frontend/src/wasm/ysm-worker-loader.ts (6), frontend/src/preview-3d/caps/postprocessing-composer.ts (5), frontend/src/preview-3d/adapters/mmd/mmd-build-menu.ts (4). Each one tells the compiler to trust the author about null, suppressing the very diagnostic `strictNullChecks` exists to produce. Many are correct: each is a claim the checker could not verify, and it is wrong only where the value can in fact be missing, so review the densest places first.
Outdated: github.com/wailsapp/wails/v3 — `github.com/wailsapp/wails/v3` is required at v3.0.0-beta.26 in REDACTED, but v3.1.0 is the module's current release — so this build is missing every fix published since, including any security fix. Run `go get github.com/wailsapp/wails/v3@v3.1.0 && go mod tidy` and commit the updated REDACTED and go.sum.
Outdated: golang.org/x/mod — `golang.org/x/mod` is required at v0.41.0 in REDACTED, but v0.43.0 is the module's current release — so this build is missing every fix published since, including any security fix. Run `go get golang.org/x/mod@v0.43.0 && go mod tidy` and commit the updated REDACTED and go.sum.
Outdated: golang.org/x/net — `golang.org/x/net` is required at v0.59.0 in REDACTED, but v0.62.0 is the module's current release — so this build is missing every fix published since, including any security fix. Run `go get golang.org/x/net@v0.62.0 && go mod tidy` and commit the updated REDACTED and go.sum.
Outdated: golang.org/x/sys — `golang.org/x/sys` is required at v0.48.0 in REDACTED, but v0.50.0 is the module's current release — so this build is missing every fix published since, including any security fix. Run `go get golang.org/x/sys@v0.50.0 && go mod tidy` and commit the updated REDACTED and go.sum.
Outdated: golang.org/x/text — `golang.org/x/text` is required at v0.42.0 in REDACTED, but v0.44.0 is the module's current release — so this build is missing every fix published since, including any security fix. Run `go get golang.org/x/text@v0.44.0 && go mod tidy` and commit the updated REDACTED and go.sum.
doc comments repeat the names frontend/src/views/app-preview/model2d/model2d.ts:27— 0 of 5 documented parameters and 1 of 46 summaries in `frontend` only repeat the member or parameter name (e.g. "Bedrock bone" for `BedrockBone`). Delete the restating tags, or add what the name does not say.
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.
trivy: not applicable — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.
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 44 file(s) — `frontend/src/backend/browser-adapter.ts`, `frontend/src/backend/web-common.ts`, `frontend/src/backend/web-community.ts`, `frontend/src/backend/web-fs.ts`, `frontend/src/backend/web-stats.ts`, … (+39 more) — so the PII/GDPR sweep did not cover the unparsed regions of them; rows reported elsewhere in those files are real.
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.
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.
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.
Run 01a1e8da-5f8f-72fd-b297-8910428f2877 · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.
Issues: 110 · Warnings: 942 · Recommendations: 157 · Info: 6 — Appendix A · all findings · full markdown report.
Generated by the Canine Code Analyzer: deterministic code-health analysis. 17-11-2026 @ 09:33 UTC.
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.