Public report of zen-browser/desktop, published 13 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.3). 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, 13 November 2026, 17:47 UTC · Survey ID cd_ab8a83d666224312bc23f987db59c613
zen-browser/desktop
Measured 13 November 2026, 17:46 UTC, at code version cad6b2f
CAI scoreWeak
CriticalWeakAdequateStrongExemplary
No change since the last survey
The score is built from these lenses. Each lens grades one area of the code, such as how easy it is to change or how well it is protected. The weakest lens counts most, so one weak area pulls the score down instead of being averaged away.
A medium codebase: 55,696 lines of product code in 6 projects, tests not counted · Estimated rebuild effort: about 1.0 person-years · Weakest lens: Accessibility, 26
Findings by how serious they are
200 critical630 serious102 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
13 November 2026, 17:46 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 ▸
67of 67 dimensions measured by tools.
915of 932 findings point to an exact file and line, so you can open each one in the code. The other 17 concern the repository as a whole, such as missing documentation.
67dimensions across 7 lenses, read from 55,696 lines of product code in 6 projects.
zen-browser/desktop falls short of our standard for production, held back most by its Accessibility lens, the interface's usability with a keyboard or assistive technology. It scores 37 out of 100 and is rated Weak, and 179 of its 200 critical findings are security problems in the build pipeline and in the packages it uses.
Accessibility, at 26, is the weakest lens and counts most in the score. The best first steps are making the controls keyboard-usable and fixing focus, motion and contrast, each worth about 4 points. Raising Accessibility to 70 would lift the score to about 45.
121 pipeline tools are referenced by a changeable name, so the build pipeline can be tampered with. Thirty secrets can leak from the build pipeline, and twenty pipeline steps put outside input straight into a shell command, so an attacker can run commands in the build pipeline. Pinning each tool to an exact version, limiting each secret to its own step and passing outside input through environment variables would close these risks. Updating the vulnerable packages would fix the two packages with a known security hole, and the five pipeline steps that run downloads without checking them need each download checked against a known checksum first. The nine buttons or links with no name need a name, even when they only show an icon.
The product code is 55,696 lines, about €140,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 26 to 70, the lowest score rated Strong, the score would rise from 37 to about 45.
Code composition: what the lines of code are
Product code 34%Tests 66%
New since the last survey: 191 findings
These 191 critical or serious findings weren't in the previous survey, on 24 October 2026. The first 100 are listed here, and the findings file in the download package lists them all.
We compare every finding with the previous survey's. A finding that has only moved to another line in the same file counts as the same finding, so only new findings appear here. Advisory notes from the AI model are left out, because the model words them afresh in every survey.
Fixed since the last survey: 200 findings
These 200 critical or serious findings were in the previous survey, on 24 October 2026, and are gone from this one. The first 100 are listed here.
Large Files · src/zen/spaces/ZenSpaceManager.mjs: 3404 lines of code src/zen/spaces/ZenSpaceManager.mjs
Large Files · src/zen/drag-and-drop/ZenDragAndDrop.js: 2056 lines of code src/zen/drag-and-drop/ZenDragAndDrop.js
Large Files · REDACTED: 1918 lines of code REDACTED
Large Files · src/zen/glance/ZenGlanceManager.mjs: 1895 lines of code src/zen/glance/ZenGlanceManager.mjs
Large Files · src/zen/sessionstore/ZenWindowSync.sys.mjs: 1664 lines of code src/zen/sessionstore/ZenWindowSync.sys.mjs
Large Files · src/zen/kbs/ZenKeyboardShortcuts.mjs: 1507 lines of code src/zen/kbs/ZenKeyboardShortcuts.mjs
Large Files · src/zen/boosts/ZenBoostsEditor.mjs: 1460 lines of code src/zen/boosts/ZenBoostsEditor.mjs
Large Files · src/browser/components/preferences/zen-settings.js: 1068 lines of code src/browser/components/preferences/zen-settings.js
Large Files · src/zen/library/ZenLibrary.mjs: 1063 lines of code src/zen/library/ZenLibrary.mjs
Large Files · src/zen/library/sections/ZenLibrarySpacesSection.mjs: 1031 lines of code src/zen/library/sections/ZenLibrarySpacesSection.mjs
Large Files · REDACTED: 1024 lines of code REDACTED
Large Files · src/zen/welcome/ZenWelcome.mjs: 981 lines of code src/zen/welcome/ZenWelcome.mjs
Large Files · src/zen/urlbar/ZenSiteDataPanel.sys.mjs: 920 lines of code src/zen/urlbar/ZenSiteDataPanel.sys.mjs
Large Files · src/zen/sync/ZenSpacesSyncApplier.sys.mjs: 917 lines of code src/zen/sync/ZenSpacesSyncApplier.sys.mjs
Large Files · src/zen/share/ZenShareManager.mjs: 764 lines of code src/zen/share/ZenShareManager.mjs
Large Files · src/zen/boosts/ZenBoostsManager.sys.mjs: 731 lines of code src/zen/boosts/ZenBoostsManager.sys.mjs
Large Files · src/zen/library/sections/ZenLibraryHistorySection.mjs: 726 lines of code src/zen/library/sections/ZenLibraryHistorySection.mjs
Large Files · src/zen/library/sections/ZenLibraryDownloadsSection.mjs: 719 lines of code src/zen/library/sections/ZenLibraryDownloadsSection.mjs
Large Files · src/zen/boosts/ZenSelectorComponent.sys.mjs: 694 lines of code src/zen/boosts/ZenSelectorComponent.sys.mjs
Large Files · src/zen/library/ZenLibraryWidget.sys.mjs: 687 lines of code src/zen/library/ZenLibraryWidget.sys.mjs
Large Files · src/zen/common/modules/ZenVerticalTabsManager.mjs: 675 lines of code src/zen/common/modules/ZenVerticalTabsManager.mjs
Large Files · src/zen/boosts/actors/ZenBoostsChild.sys.mjs: 654 lines of code src/zen/boosts/actors/ZenBoostsChild.sys.mjs
Large Files · src/zen/urlbar/ZenUBActionsProvider.sys.mjs: 561 lines of code src/zen/urlbar/ZenUBActionsProvider.sys.mjs
Large Files · src/zen/migration/ZenMigrationUtils.sys.mjs: 559 lines of code src/zen/migration/ZenMigrationUtils.sys.mjs
Large Files · src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs: 557 lines of code src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs
Large Files · src/zen/library/ZenLibraryMediaPreview.mjs: 543 lines of code src/zen/library/ZenLibraryMediaPreview.mjs
Large Files · src/zen/common/modules/ZenUIManager.mjs: 500 lines of code src/zen/common/modules/ZenUIManager.mjs
Large Files · src/zen/spaces/ZenSpace.mjs: 404 lines of code src/zen/spaces/ZenSpace.mjs
Dead Code · Dead file (~3703 LoC) src/zen/spaces/ZenSpaceManager.mjs
Dead Code · Dead file (~2196 LoC) src/zen/drag-and-drop/ZenDragAndDrop.js
Dead Code · Dead file (~2133 LoC) src/zen/glance/ZenGlanceManager.mjs
Dead Code · Dead file (~2123 LoC) REDACTED
Dead Code · Dead file (~1772 LoC) src/zen/sessionstore/ZenWindowSync.sys.mjs
Dead Code · Dead file (~1672 LoC) src/zen/kbs/ZenKeyboardShortcuts.mjs
Dead Code · Dead file (~1265 LoC) src/browser/components/preferences/zen-settings.js
Dead Code · Dead file (~1192 LoC) src/zen/tabs/ZenPinnedTabManager.mjs
Dead Code · Dead file (~1080 LoC) REDACTED
Dead Code · Dead file (~1047 LoC) src/zen/welcome/ZenWelcome.mjs
Dead Code · Dead file (~1026 LoC) src/zen/urlbar/ZenSiteDataPanel.sys.mjs
Dead Code · Dead file (~967 LoC) src/zen/sync/ZenSpacesSyncApplier.sys.mjs
Dead Code · Dead file (~731 LoC) src/zen/common/modules/ZenVerticalTabsManager.mjs
Dead Code · Dead file (~593 LoC) src/zen/migration/ZenMigrationUtils.sys.mjs
Dead Code · Dead file (~589 LoC) src/zen/urlbar/ZenUBActionsProvider.sys.mjs
Dead Code · Dead file (~583 LoC) src/zen/library/ZenLibraryMediaPreview.mjs
Dead Code · Dead file (~547 LoC) src/zen/common/modules/ZenUIManager.mjs
Dead Code · Dead file (~460 LoC) src/zen/spaces/ZenSpace.mjs
Dead Code · Dead file (~380 LoC) src/zen/urlbar/ZenUBGlobalActions.sys.mjs
Dead Code · Dead file (~362 LoC) src/zen/library/ZenLibraryDragAndDrop.mjs
Dead Code · Dead file (~358 LoC) src/zen/common/sys/ZenCustomizableUI.sys.mjs
Dead Code · Dead file (~330 LoC) src/zen/spaces/ZenSpacesSwipe.mjs
Dead Code · Dead file (~300 LoC) src/zen/spaces/ZenSpaceAddSwipe.mjs
Dead Code · Dead file (~274 LoC) src/zen/spaces/ZenSpaceIcons.mjs
Dead Code · Dead file (~258 LoC) src/zen/live-folders/ZenLiveFoldersUI.sys.mjs
Dead Code · Dead file (~249 LoC) src/zen/spaces/ZenSpaceBookmarksStorage.js
Dead Code · Dead file (~239 LoC) src/zen/urlbar/ZenUBSidebarProvider.sys.mjs
Dead Code · Dead file (~223 LoC) src/zen/common/modules/ZenStartup.mjs
Rebuild cost: about €140,000 · Estimate
Cost to rebuild
€46,000 to €230,000, for 774 to 2,457 hours of work, about 1.0 person-years for 1 to 2 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.7 at a score of 37. 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
Medium: 55,696 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.
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.
Declare <html lang>, a document <title> and a <main> landmark, keep headings in order, leave zoom enabled, title iframes and drop meta-refresh.
Raises the score by about 3 points · Medium effort · Page structure
Diagnosis: what the measurements show together
Each conclusion below combines several dimensions into one point that no single dimension shows, and lists the measurements it rests on.
Where the investment is most exposed · Value at risk
This code would cost about €140,000 to build again, about 1.0 person-years of work. Its weakest lens is Accessibility, at 26 (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 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
What hard-to-read code costs each year · Cost
Four dimensions measure how easy the code is to work in: two measure how tangled its logic is, one how much of it is copied, and one how well each part sticks to a single job. In this codebase they average 6.2 out of 10. Code at that level is slower to change than clean code, and we estimate the extra work at 4% to 10% on every change. The history of the code shows how much it changes: about 247,875 lines over the last 90 days, which is about 1,005,271 lines a year. At that pace, the extra work comes to an estimated 112.8 to 676.5 engineer-days a year, and it grows as more code changes.
How this is estimated: The number of changed lines is measured from the history of the code. The rest rests on two assumptions of our own: code scoring 8 out of 10 or more adds no extra work, and each point below 8 adds 2.5% to 5.6% to every change, never less than 2% to 5% and never more than 40% to 60% in all; and an engineer changes 150 to 400 lines in a day. The result is a range for planning, not a measurement.
Based on: Cyclomatic Complexity · Cognitive Complexity · Cohesion (LCOM4) · the code's change history
What to do: Start with the files listed under Churn × Complexity Hotspots, which change often and are hard to read, because that is where the extra work is paid most often.
Architecture — module dependency graph
Project dependencies, layered top-to-bottom; arrows show direction. Any dashed red edge points upward or sideways, which only happens where the projects form a dependency cycle. A graph without cycles has none.
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.
108 modules, with 23 dependencies between them. Every module uses only modules listed above it, so there are no loops.
The table shows the 40 modules with the most connections; 68 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.
src.zen.common.emojis.ZenEmojiPicker uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.common.emojis.ZenEmojiPicker, while a change to src.zen.common.emojis.ZenEmojiPicker can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.common.emojis.ZenEmojiPicker uses a module listed above it, which is the healthy direction.
src.zen.common.modules.ZenSessionStore uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.common.modules.ZenSessionStore, while a change to src.zen.common.modules.ZenSessionStore can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.common.modules.ZenSessionStore uses a module listed above it, which is the healthy direction.
src.zen.common.sys.ui.ZenProgressBar_sys uses src.zen.common.sys.ui.ZenUIComponent_sys, so a change to src.zen.common.sys.ui.ZenUIComponent_sys can break src.zen.common.sys.ui.ZenProgressBar_sys, while a change to src.zen.common.sys.ui.ZenProgressBar_sys can't break src.zen.common.sys.ui.ZenUIComponent_sys.
Position
Below the diagonal: src.zen.common.sys.ui.ZenProgressBar_sys uses a module listed above it, which is the healthy direction.
src.zen.downloads.ZenDownloadAnimation uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.downloads.ZenDownloadAnimation, while a change to src.zen.downloads.ZenDownloadAnimation can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.downloads.ZenDownloadAnimation uses a module listed above it, which is the healthy direction.
src.zen.folders.ZenFolders uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.folders.ZenFolders, while a change to src.zen.folders.ZenFolders can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.folders.ZenFolders uses a module listed above it, which is the healthy direction.
src.zen.glance.ZenGlanceManager uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.glance.ZenGlanceManager, while a change to src.zen.glance.ZenGlanceManager can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.glance.ZenGlanceManager uses a module listed above it, which is the healthy direction.
src.zen.library.sections.ZenLibraryBoostsSection uses src.zen.library.sections.ZenLibrarySearchSection, so a change to src.zen.library.sections.ZenLibrarySearchSection can break src.zen.library.sections.ZenLibraryBoostsSection, while a change to src.zen.library.sections.ZenLibraryBoostsSection can't break src.zen.library.sections.ZenLibrarySearchSection.
Position
Below the diagonal: src.zen.library.sections.ZenLibraryBoostsSection uses a module listed above it, which is the healthy direction.
src.zen.library.sections.ZenLibraryDownloadsSection uses src.zen.library.sections.ZenLibrarySearchSection, so a change to src.zen.library.sections.ZenLibrarySearchSection can break src.zen.library.sections.ZenLibraryDownloadsSection, while a change to src.zen.library.sections.ZenLibraryDownloadsSection can't break src.zen.library.sections.ZenLibrarySearchSection.
Position
Below the diagonal: src.zen.library.sections.ZenLibraryDownloadsSection uses a module listed above it, which is the healthy direction.
src.zen.library.sections.ZenLibraryHistorySection uses src.zen.library.sections.ZenLibrarySearchSection, so a change to src.zen.library.sections.ZenLibrarySearchSection can break src.zen.library.sections.ZenLibraryHistorySection, while a change to src.zen.library.sections.ZenLibraryHistorySection can't break src.zen.library.sections.ZenLibrarySearchSection.
Position
Below the diagonal: src.zen.library.sections.ZenLibraryHistorySection uses a module listed above it, which is the healthy direction.
src.zen.library.sections.ZenLibraryMediaSection uses src.zen.library.sections.ZenLibrarySearchSection, so a change to src.zen.library.sections.ZenLibrarySearchSection can break src.zen.library.sections.ZenLibraryMediaSection, while a change to src.zen.library.sections.ZenLibraryMediaSection can't break src.zen.library.sections.ZenLibrarySearchSection.
Position
Below the diagonal: src.zen.library.sections.ZenLibraryMediaSection uses a module listed above it, which is the healthy direction.
1 pair of types, where a type in src.zen.library.sections.ZenLibrarySpaceRoutingSection uses a type in src.zen.library.sections.ZenLibrarySearchSection.
src.zen.library.sections.ZenLibrarySpaceRoutingSection uses src.zen.library.sections.ZenLibrarySearchSection, so a change to src.zen.library.sections.ZenLibrarySearchSection can break src.zen.library.sections.ZenLibrarySpaceRoutingSection, while a change to src.zen.library.sections.ZenLibrarySpaceRoutingSection can't break src.zen.library.sections.ZenLibrarySearchSection.
Position
Below the diagonal: src.zen.library.sections.ZenLibrarySpaceRoutingSection uses a module listed above it, which is the healthy direction.
src.zen.live-folders.ZenLiveFoldersUI_sys uses src.zen.common.sys.ui.ZenUIComponent_sys, so a change to src.zen.common.sys.ui.ZenUIComponent_sys can break src.zen.live-folders.ZenLiveFoldersUI_sys, while a change to src.zen.live-folders.ZenLiveFoldersUI_sys can't break src.zen.common.sys.ui.ZenUIComponent_sys.
Position
Below the diagonal: src.zen.live-folders.ZenLiveFoldersUI_sys uses a module listed above it, which is the healthy direction.
src.zen.live-folders.providers.GithubLiveFolder_sys uses src.zen.live-folders.ZenLiveFolder_sys, so a change to src.zen.live-folders.ZenLiveFolder_sys can break src.zen.live-folders.providers.GithubLiveFolder_sys, while a change to src.zen.live-folders.providers.GithubLiveFolder_sys can't break src.zen.live-folders.ZenLiveFolder_sys.
Position
Below the diagonal: src.zen.live-folders.providers.GithubLiveFolder_sys uses a module listed above it, which is the healthy direction.
src.zen.live-folders.providers.RssLiveFolder_sys uses src.zen.live-folders.ZenLiveFolder_sys, so a change to src.zen.live-folders.ZenLiveFolder_sys can break src.zen.live-folders.providers.RssLiveFolder_sys, while a change to src.zen.live-folders.providers.RssLiveFolder_sys can't break src.zen.live-folders.ZenLiveFolder_sys.
Position
Below the diagonal: src.zen.live-folders.providers.RssLiveFolder_sys uses a module listed above it, which is the healthy direction.
src.zen.media.ZenMediaController_sys uses src.zen.common.sys.ui.ZenUIComponent_sys, so a change to src.zen.common.sys.ui.ZenUIComponent_sys can break src.zen.media.ZenMediaController_sys, while a change to src.zen.media.ZenMediaController_sys can't break src.zen.common.sys.ui.ZenUIComponent_sys.
Position
Below the diagonal: src.zen.media.ZenMediaController_sys uses a module listed above it, which is the healthy direction.
src.zen.mods.ZenMods uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.mods.ZenMods, while a change to src.zen.mods.ZenMods can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.mods.ZenMods uses a module listed above it, which is the healthy direction.
src.zen.share.ZenShareManager uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.share.ZenShareManager, while a change to src.zen.share.ZenShareManager can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.share.ZenShareManager uses a module listed above it, which is the healthy direction.
src.zen.space-routing.ZenSpaceRoutingNavigation_sys uses src.zen.common.sys.ui.ZenUIComponent_sys, so a change to src.zen.common.sys.ui.ZenUIComponent_sys can break src.zen.space-routing.ZenSpaceRoutingNavigation_sys, while a change to src.zen.space-routing.ZenSpaceRoutingNavigation_sys can't break src.zen.common.sys.ui.ZenUIComponent_sys.
Position
Below the diagonal: src.zen.space-routing.ZenSpaceRoutingNavigation_sys uses a module listed above it, which is the healthy direction.
src.zen.spaces.ZenGradientGenerator uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.spaces.ZenGradientGenerator, while a change to src.zen.spaces.ZenGradientGenerator can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.spaces.ZenGradientGenerator uses a module listed above it, which is the healthy direction.
src.zen.spaces.ZenSpace uses src.zen.folders.ZenFolder, so a change to src.zen.folders.ZenFolder can break src.zen.spaces.ZenSpace, while a change to src.zen.spaces.ZenSpace can't break src.zen.folders.ZenFolder.
Position
Below the diagonal: src.zen.spaces.ZenSpace uses a module listed above it, which is the healthy direction.
src.zen.split-view.ZenViewSplitter uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.split-view.ZenViewSplitter, while a change to src.zen.split-view.ZenViewSplitter can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.split-view.ZenViewSplitter uses a module listed above it, which is the healthy direction.
src.zen.tabs.ZenPinnedTabManager uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.tabs.ZenPinnedTabManager, while a change to src.zen.tabs.ZenPinnedTabManager can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.tabs.ZenPinnedTabManager uses a module listed above it, which is the healthy direction.
src.zen.tabs.ZenTabRenamer uses src.zen.common.modules.ZenCommonUtils, so a change to src.zen.common.modules.ZenCommonUtils can break src.zen.tabs.ZenTabRenamer, while a change to src.zen.tabs.ZenTabRenamer can't break src.zen.common.modules.ZenCommonUtils.
Position
Below the diagonal: src.zen.tabs.ZenTabRenamer uses a module listed above it, which is the healthy direction.
At a glance — Code Health · 32% · Weak · gated by R1, R3 ·
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
184
High / Critical
A03:2025 — Software Supply Chain Failures
21
High / Critical
Roadmap
Top priorities: Make custom controls keyboard-operable (role + tabindex + key handler), drop positive tabindex, and give anchors a real href; 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; 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.
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.
Adopt TypeScript for the frontend: add a typecheck step to the build, then either type-check the existing JavaScript in place (`checkJs`/JSDoc types) or convert the highest-traffic modules first — no file is typed today, so this is an adoption, not a clean-up.
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.
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 — 200
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 — 630
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 — 102
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 67 evaluated dimensions are computed by tools and static analysis; no language model sets or judges any of them. Overall confidence is 0.9, 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 — 67 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, 915 of 932 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.
D4 Code Duplication — 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. Most of this repository's production source (.cc, .cpp, .mm) was not read by duplication detection: no source of those file kinds was exposed to the token comparison by any language model this pass could load. Duplication in .js, .mjs is measured by R10 Code Duplication and is not part of this gap.
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: test source is present (.py) but the built-in coverage collector has no runner for this repository's ecosystem — so this suite was never executed by it. Not scored — this is a gap in the analyzer's language coverage, not a defect in the repo.
D11 Test Reliability — 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. Test source is present (.py) and this repository declares a Python test suite (repository root, 28 test files), but it was not re-run: no test result was produced. Not scored — this is a gap in the analyzer's language coverage, not a finding about this repository.
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 Python pyproject.toml/requirements.txt (pip/uv/Poetry), but the licence verdict published here was taken over its crate dependencies. Nothing was read about its Python 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 package.json, but the licence verdict published here was taken over its crate dependencies. Nothing was read about its npm dependencies' licensing in either direction, and a clean score on this card must not be read as covering 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. Each ecosystem's manifests (what makes a folder runnable or a published package) need their own proof before D19 judges its units. Until then those folders' READMEs are judged only as documents (boilerplate, structure), never counted as complete.
D21 Naming Consistency — 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. D21's naming rules read C# through Roslyn and every other language through its sidecar model; these languages are left out (PHP's reading is its own change, a Roslyn-loaded VB or F# project has no population builder yet). Their declarations carry no naming verdict this run — this says nothing about whether their names are consistent.
D21 Naming Consistency — 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. 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.
D22 Internal API Consistency — 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. D22 identifies the intentionally-exposed surface from `IsPackable` and `.Contracts` project names, MSBuild conventions read off the loaded project set. This target exposed no such projects, so the probe never ran; this says nothing about whether the repository has a public API. This repository commits no C#/VB source at all, so there was never an MSBuild project set to read these conventions off. That is OUR side and it is a COLLECTOR gap, not an environment fault: no published-package marker D22 reads admitted any project here, so this ecosystem's public API has no collector, and the remedy is to write one — no change to the scan image can close it.
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.
D26 Project Cohesion — 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. Project size and spread are measured over build units whose source a code model reads. This repository's .cpp, .cc source is a material share of its production lines and was read by none, so the score is a verdict about the units that were read. Not a finding that the unread source is cohesive — it is unmeasured.
D27 Navigability — 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. Tracing effort is measured over resolved call sites, and all 667 sampled here came from .js/.mjs files. This repository's .cpp, .cc source is a material share of its production lines and contributed none, so the score above is a verdict about the part that was read. Not a finding that the unread half navigates well — it is unmeasured.
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. `src/zen/@types/index.d.ts`, `src/zen/@types/lib.gecko.tweaks.d.ts` 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.
AC4 Keyboard semantics — 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. 10 further occurrence(s) are not listed individually; the score already reflects all 50.
AC6 Visual & motion safety — 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. 50 further occurrence(s) are not listed individually; the score already reflects all 90.
AX6 Interface segregation — 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 is computed over the public interfaces this run's compilations declare, and none was loaded, so it had nothing 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. The dev server exited, and its output does not match a cause we recognise. (rule: unrecognised-exit). The renderer reported: the dev server (`npm run start`) exited before it served a page. Likely cause (not identified): the dev server exited, and its output does not match a cause we recognise. Last output: "> zen-desktop@1.0.0 start / > cd engine && python3 ./mach run --noprofile / sh: 1: cd: can't cd to engine" 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 (start). the dev server (`npm run start`) exited before it served a page. Likely cause (not identified): the dev server exited, and its output does not match a cause we recognise. Last output: "> zen-desktop@1.0.0 start / > cd engine && python3 ./mach run --noprofile / sh: 1: cd: can't cd to engine" 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. 5 further occurrence(s) are not listed individually; the score already reflects all 45.
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. 116 further occurrence(s) are not listed individually; the score already reflects all 156.
R7 Dead Code — 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. 34 further occurrence(s) are not listed individually; the score already reflects all 74.
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.
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.
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.
X19 Unrestored process-global state — 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.
X2 Cancellation propagation — 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.
X28 Index access outside its own emptiness 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.
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. 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.
X30 Support guard that admits what it rejects — 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.
X5 Nullable reference types — 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 C# syntax and MSBuild project configuration, TypeScript source and its tsconfig files, Java source and its package and module declarations, PHP source and its PHPStan and Psalm configuration, Dart source and its pubspec language version, Ruby source and its Sorbet and Steep configuration, Scala source and its build's explicit-nulls, WartRemover and Scalafix settings, and Kotlin source only, and no C# was loaded, no TypeScript was found, and this repository's C, Cpp, Objectivec, Python, Rust, Swift is not read 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.
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.
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.
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.
D16 Bus Factor: Bus-factor is a time-decayed model of commit attribution (who has recently, repeatedly worked a file), not comprehension — pairing, review and reading-without-committing spread knowledge it can't see; bot commits and shared accounts still distort it.
D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
D19 Documentation Quality: Documentation quality publishes two things only: a runnable or packaged unit with no example, and a multi-project root README that maps none of its parts. It does not judge clarity, and its other checks (overview, licence, boilerplate, structure, empty sections, XML-doc coverage) are withheld after adjudication: their candidates are counted in the card's gaps, not shown as rows. A false statement in a document is M4's; units are .NET projects only.
D20 ADR Quality: ADR quality checks the structure of the decision records present: it cannot know about decisions made and never recorded, and it does not judge how well a record argues its case. Records in a language the section lexicon does not cover are not evaluated.
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.
D27 Navigability: Indirection/navigability is structural — it measures hops to follow a call, not whether that indirection buys real flexibility or just ceremony.
D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
D43 Malicious Dependencies: Only packages some vulnerability database has already NAMED as malicious are seen — a compromise published in the last hours, or never reported at all, is invisible here, and this dimension reading 10 is not evidence that a dependency is trustworthy. There is no typosquat or dependency-confusion analysis: a package nobody has reported is simply absent from the feeds. Coverage is the dependency scan's: an ecosystem that could not be scanned is disclosed as unmeasured, never as clean.
D44 Platform End-of-Life: The support table is FROZEN, so it goes out of date by losing RECALL: a release that ended support after the table was written is missed until the table is refreshed, and this dimension reading 10 is not evidence that a platform is current. Only platforms the repository DECLARES in a place this pass reads are seen — a runtime named only in a Dockerfile (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (go.mod, a Gemfile ruby directive) is invisible here, which is why a repository declaring none of them abstains rather than scoring. Only frameworks with a PUBLISHED support policy are tracked: React, Flask and Express publish none, so their age cannot be judged and their absence from a report is not a statement that they are supported.
AC1 Text alternatives: Alt-text is detected structurally — the scan sees that an alternative EXISTS, not whether it meaningfully describes the image, and decorative-vs-missing is judged by attribute shape; runtime-injected images and a non-role=img decorative svg are out of scope. This is accessibility readiness, never a WCAG conformance claim.
AC2 Forms & labels: Label association is read from static markup — a label wired up at runtime (JS-set aria-labelledby, framework-injected ids) reads as missing, a present label says nothing about whether its text is correct. A known UI-library field component (e.g. a JSX <TextField>) is now checked conservatively — flagged only when it carries NO label/aria-label/aria-labelledby/id/name — but wrapper/context-labelled libraries (Chakra/Radix FormControl+FormLabel) aren't statically visible (possible false positive) and non-JSX lowercased components are still skipped. A click handler on a plain element is now asked for a name too (it is a control the author declared), but the subtree test that answers it is deliberately generous: any DYNAMIC text expression in the subtree counts as a name, so an icon chosen by a ternary ({cond ? <IconA/> : <IconB/>}) reads as named, and a glyph component from a library the icon-import list does not know still names its parent. A clean result is "no unlabelled control found", not a labelling proof.
AC3 Page structure: Page structure is read from the static markup tree — landmarks, headings and lang injected at runtime aren't seen, heading ORDER is checked structurally (not against the rendered visual hierarchy), and lang/title/main fire only on full documents, never partials, and the data-table check sees header-cell presence (a <th> exists), not whether each header correctly associates with its cells. Static readiness, not conformance.
AC4 Keyboard semantics: Keyboard semantics are inferred from markup attributes — interactivity wired purely in script, focus managed at runtime, and component-level handlers are invisible. A clean result means "no static keyboard-trap shape", not a keyboard-operability proof.
AC5 ARIA correctness: ARIA correctness is checked against the static role/attribute shape — roles/attributes set dynamically aren't seen, a valid role says nothing about whether it matches the element's real behaviour, and required-state checks are suppressed when a JSX spread could supply them. The two-branch toggle check (a control whose state is conveyed only by which of two mutually exclusive branches renders) reads CONDITIONALS THAT ARE ATTRIBUTES — Vue v-if/v-else/v-show and Alpine x-if/x-show — so the same toggle written as a Svelte {#if} block or a JSX ternary is control flow the markup model never projects as a branch and is not seen at all.
AC6 Visual & motion safety: Contrast and motion safety are PARTIAL by construction — literal colours (hex/rgb/hsl/named) in inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS top-level declarations are read (same-rule/same-element colour+background pairs only); computed/runtime/theme colour, external-CDN stylesheets, CSS-in-JS dynamic (${…}) and nested-selector colours, cross-element pairs and image contrast stay out of reach, so a clean result is bounded by what the static CSS itself shows.
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.
AX9 CQS / query purity: Handlers are found by interface/name convention — a query handler using neither is not seen. Mutation is a resolved write/publish invocation (SaveChanges/repository/bus), so a write hidden behind a hand-rolled wrapper, reflection, or a string-keyed service locator resolves to a non-persistence type and isn't flagged; it detects that a query writes state, not whether the write is a legitimate read-side cache update. Clean means "no resolved write/publish in a query body", not a proof of CQS purity.
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.
152 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was _updateEvent at 82. A further 2 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 onUpdateStatus at 20 — they are counted neither in the figure above nor in this dimension's score. 2 files carry no cyclomatic complexity row at all for this reason — every one of their over-threshold methods was excluded, so the exclusion is disclosed nowhere in the file itself: src/zen/about/zen-about.js (onUpdateStatus at 20), src/zen/about/zen-about.js (nsZenAboutDialog.onUpdateStatus at 19). 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.
+ 77 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 Cyclomatic Complexity — start with _updateEvent (cyclomatic 82). — Refactoring it lifts Cyclomatic Complexity from 5.6 to about 6.1/10.
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.
+ 103 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Bring the 10 bodies over 60 down to 60 or less in Cognitive Complexity — start with _updateEvent (cognitive 102), _buildModsList (cognitive 93), animateSelect (cognitive 87). — 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 10 together lifts Cognitive Complexity from 4.5 to about 5.5/10, projected with the scoring formula itself and assuming each lands exactly at 60; a cleaner split scores higher.
Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D3 · God Classes7.1 / 10Strong✓ Tool-verified
What it measures: Over-large classes that try to do too much ("god classes").
Method: God-class detection by line and method-count thresholds per logical type (partial classes unified), filtered for generated code and registration/contract false positives. Deterministic.
Resolve the 21 FileTooLong finding(s) in God Classes — start with ZenSpaceManager.mjs, REDACTED, ZenViewSplitter.mjs. — One of this dimension's main actionable groups (21 warning-level).
Resolve the 21 TooManyMethods finding(s) in God Classes — start with ZenSpaceManager.mjs, ZenGlanceManager.mjs, REDACTED. — One of this dimension's main actionable groups (21 warning-level).
Resolve the 17 ClassTooLong finding(s) in God Classes — start with ZenSpaceManager.mjs, ZenViewSplitter.mjs, REDACTED. — One of this dimension's main actionable groups (17 warning-level).
Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D5 · Coupling8.7 / 10Strong✓ 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.
6 production modules (Cargo+source-import), 0 dependency cycle(s), 0 unstable depended-on module(s). Read from the build's own module declarations, and — for the source no manifest declares — its top-level source directories, with the imports between them as edges; 1 module(s) off the main sequence, with abstractness counted on 4 of the 6 (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).
Off the main sequence: src/zen
What to do
Resolve the 1 Off the main sequence finding(s) in Coupling. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d5_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
Resolve the 8 Low cohesion finding(s) in Cohesion (LCOM4) — start with ZenFolders.mjs, REDACTED, ZenUIManager.mjs. — One of this dimension's main actionable groups (8 warning-level).
Detailed fixes: d6_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
1 outdated, 0 yanked direct Cargo dependencies. Only DIRECT edges are graded: a transitive crate cannot be moved past what its parent's requirement admits, so reporting one would be advice its owner cannot take. A newer release is reported only where this repository's OWN requirement already admits it, so the remedy is `cargo update` and never a manifest edit — which means a release outside the declared range is deliberately NOT charged, because a written-down constraint is a decision rather than a defect. Note that a bare requirement is a CARET, and for a 0.x crate its ceiling is the minor. Whether any crate is UNMAINTAINED is not graded — crates.io publishes no maintenance status, and release age does not stand in for one. Known CVEs in this dependency graph are D30's question, read from REDACTED there.
Outdated: serde
✓ 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 13 shipped crate(s) use a banned license. Licences were resolved from crates.io over the crates a consumer compiles — this repository's REDACTED closed over its manifests' `[dependencies]` and `[build-dependencies]`. Crates it asks for ONLY under `[dev-dependencies]` are excluded: they are not compiled by anything that depends on this repository. ★ COVERAGE OF THIS VERDICT: it grades this repository's crate dependencies and nothing else. The repository also declares a Python pyproject.toml/requirements.txt (pip/uv/Poetry) and package.json, 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.
Resolve the 18 Hotspot finding(s) in Churn × Complexity Hotspots — start with ZenSpaceManager.mjs, REDACTED, ZenDragAndDrop.js. — One of this dimension's main actionable groups (18 warning-level).
Detailed fixes: d15_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D16 · Bus Factor8.3 / 10Strong✓ Tool-verified
What it measures: Whether knowledge is concentrated in too few people (the "bus factor").
Method: Living knowledge per author via time-decayed commit attribution (6-month half-life, focus weighting) across largest source files. Deterministic, avoids blame's mechanical-refactor false positives.
17 source file(s) have their living knowledge concentrated in one author (≥90% of recent, decayed contribution). The largest is src/zen/sync/ZenSpacesSyncApplier.sys.mjs. Counted over 99 of the 119 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.
Off-boarding risk: anonymized user #1
Further sole-owners (lower concentration)
What to do
Resolve the 1 Off-boarding risk finding(s) in Bus Factor. — One of this dimension's main actionable groups (1 recommendation-level).
Resolve the 1 Further sole-owners (lower concentration) finding(s) in Bus Factor. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d16_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
0 deducted task-comment markers across 1757 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.
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.
1 of 1 documentation facets pass in full. 24 document(s) read across 1 unit(s).
✓ On the Gold path — maintain.
Detailed fixes: d19_recommendation.md.
Do you agree with this assessment?
D20 · ADR Quality0.0 / 10Critical✓ Tool-verified
What it measures: Whether architecture decisions are recorded well (context, decision, consequences).
Method: Every ADR read by its section structure: nine located rules (a missing Decision, Context or Consequences section, a stale status, two records deciding the same question, a dangling supersede link, a number-only title, a single option, no named cost, no status where the log uses one, no enforcement field where the log adopted one), each a fixed deduction from 10; the score is the mean over evaluated records. Deterministic, no model. Advisory.
Resolve the 1 No ADRs found finding(s) in ADR Quality — start with package.json. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d20_recommendation.md · top locations in Appendix A, every location in findings.md.
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 namessrc/zen/boosts/ZenBoostsEditor.mjs:29
What to do
Resolve the 64 redundant comment finding(s) in Comment Value — start with browser_350525.js (3), ZenDownloadAnimation.mjs (2), test_remote_settings_poll.js (2). — One of this dimension's main actionable groups (64 recommendation-level).
Detailed fixes: d24_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D26 · Project Cohesion3.3 / 10Weak✓ Tool-verified
What it measures: Whether each project is a focused, coherent unit rather than an oversized grab-bag.
1 of 3 build units (Cargo, npm) flagged as possibly oversized/incoherent. This repository's .cpp, .cc source was read by no build unit, so this covers part of the tree, not all of it.
Projects may be oversized for their cohesion
What to do
Resolve the 1 Projects may be oversized for their cohesion finding(s) in Project Cohesion. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d26_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: How far you must trace to follow a call — low indirection and co-located slices read easier.
Method: Call indirection (interface hops, cross-namespace calls, slice-locality scaled) over a sampled set of method invocations, size-aware baseline. Sampled; confidence discounted by symbol-resolution gaps. C# also names each pass-through layer (a class whose every public method only forwards its own parameters to one collaborator) as a located finding; the score is not affected.
Coverage: Slice locality from the first namespace segments, SAMPLED (≤400 methods) — not exhaustive.
2 % of calls cross a namespace and 0 % go through an interface, but 100 % of collaborators are co-located — so a call's collaborators sit together and tracing stays easy. Baseline: small — navigation cost is tolerated. Measured over the .js/.mjs source only — this repository's .cpp, .cc was not sampled for call sites, so this score covers part of the tree, not all of it.
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).
184 finding(s): 0 critical, 177 high, 7 medium, 0 low. 120 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 5 file(s) — `src/browser/themes/shared/zen-icons/nucleo/nucleo-copyright-notice.html` (lines 1–3), `src/zen/@types/index.d.ts` (line 37), `src/zen/@types/lib.gecko.tweaks.d.ts` (line 90), `src/zen/@types/lib.gecko.xpcom.d.ts`, `src/zen/drag-and-drop/ZenDragAndDrop.js` — 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 8 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
+ 7 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 20 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (8), REDACTED (3), REDACTED (2). — One of this dimension's main actionable groups (20 issue-level).
Resolve the 14 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (4), REDACTED (2), REDACTED (2). — One of this dimension's main actionable groups (14 issue-level).
No action in Static Analysis (SAST) — all 120 REDACTED finding(s) are reported here at file:line but scored by D36 (supply-chain provenance), so none is charged to this dimension. — One of this dimension's main actionable groups (120 issue-level, 0 of them charged here).
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 2 High CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (2). — One of this dimension's main actionable groups (2 issue-level).
Resolve the 1 Medium advisory (unmaintained) finding(s) in Dependency Vulnerabilities — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 Medium CVE finding(s) in Dependency Vulnerabilities — start with REDACTED. — One of this dimension's main actionable groups (1 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.
4 of 99 significant source file(s) are orphaned — their living knowledge has decayed to nothing, so no one currently understands them. The largest is src/zen/live-folders/ZenLiveFolder.sys.mjs. Counted over 99 of the 119 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 3 Change coupling finding(s) in Change Coupling — start with ZenSpaceIcons.mjs, ZenSpaceBookmarksStorage.js, ZenActorsManager.sys.mjs. — One of this dimension's main actionable groups (3 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.
+ 5 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 5 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED (3), REDACTED, REDACTED. — One of this dimension's main actionable groups (5 warning-level).
Resolve the 2 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED (2). — One of this dimension's main actionable groups (2 warning-level).
Resolve the 2 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED, REDACTED. — One of this dimension's main actionable groups (2 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 7 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 rust-toolchain.toml. — 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 alternatives5.3 / 10Adequate✓ Tool-verified
Other · Accessibility — Whether non-text content carries a text alternative — img/area/input[type=image] have alt, a meaningful svg has a title or aria-label, video has a captions track, and object/embed/canvas have a name or fallback content. Static markup readiness, not a WCAG conformance claim.
Method: Static markup-model scan: every img/area/input[type=image] checked for alt, svg[role=img] for a title/aria-label, video for a captions <track>. Components skipped, spreads suppressed. Deterministic, hard fact per element.
Coverage: Population: image/media elements — img, area, input[type=image], svg, video, object, embed, canvas — across the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx); components, hidden subtrees and dynamic-attribute elements are skipped. Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is NOT read by any producer, so it contributes no element to this population; where such a frontend is present the card discloses it as an analyzer gap rather than scoring around it.
An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative. (×4) — src/zen/common/modules/ZenSidebarNotification.mjs:131, src/zen/common/modules/ZenSidebarNotification.mjs:99, src/zen/urlbar/ZenSiteDataPanel.sys.mjs:51, …
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 & labels3.5 / 10Weak✓ 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 <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id. (×5) — src/browser/components/preferences/zen-settings.js:298, src/zen/common/modules/ZenSidebarNotification.mjs:135, src/zen/common/modules/ZenSidebarNotification.mjs:90, …
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). (×7) — src/browser/components/preferences/zen-settings.js:305, src/zen/boosts/ZenZapBar.mjs:118, src/zen/library/sections/ZenLibraryMediaSection.mjs:476, …
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. — src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:388
This <div> carries a click handler, which makes it a control, but it has no text, aria-label or labelled child (the icon-only case), so assistive tech has no name to announce for it. Note that switching it to <button type="button"> — the right fix for its keyboard operability — does not give it a name either: an icon-only button still needs one. Add visible text or an aria-label. (×2) — src/zen/library/sections/ZenLibrarySpacesSection.mjs:759, src/zen/library/sections/ZenLibrarySpacesSection.mjs:1121
This control has no associated label. Add a <label for> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it. — src/zen/library/sections/ZenLibrarySpacesSection.mjs:993
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.
Other · Accessibility — Whether pages declare a language (well-formed BCP-47) and a non-empty title, expose exactly one main landmark and a sane heading order with non-empty headings, keep zoom enabled, title their iframes, give data tables header cells, and avoid meta-refresh. Static markup readiness, not a WCAG conformance claim.
Method: Static markup-model scan: html lang, document <title>, a main landmark and heading order on full documents only, plus zoom-disabling viewports, untitled iframes and meta-refresh anywhere. Deterministic, per structural checkpoint.
Coverage: Population: the PARSED MARKUP documents (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx). The page-level checks — lang, title, single main landmark — fire ONCE PER FULL DOCUMENT (an <html> root) and never on a partial or component fragment, so a repo of fragments is assessed only on the per-element checks (heading order, table headers, iframe titles, meta-refresh, zoom). Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.
The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en"). — src/browser/themes/shared/zen-icons/nucleo/nucleo-copyright-notice.html:5
No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>. — src/browser/themes/shared/zen-icons/nucleo/nucleo-copyright-notice.html:5
An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative. (×8) — src/zen/library/sections/ZenLibraryHistorySection.mjs:742, src/zen/library/sections/ZenLibraryMediaSection.mjs:474, src/zen/library/sections/ZenLibrarySearchSection.mjs:242, …
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".
An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action. (×40) — locales/ar/browser/browser/zen-about.ftl:58, locales/bg/browser/browser/zen-about.ftl:58, locales/bs/browser/browser/zen-about.ftl:58, …
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.
`.tab-reset-button` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/tabs/zen-tabs/vertical-tabs.css:972
`#tab-label-input` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/tabs/zen-tabs/vertical-tabs.css:1453
`zen-workspace-creation .zen-workspace-creation form .zen-workspace-creation-name-wrapper .zen-workspace-creation-name` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/spaces/create-workspace-form.css:116
`.zen-library-search-box input` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/library/zen-library.css:633
`.zen-library-routing-reference` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/library/zen-library.css:732
`.zen-library-space-name-input` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/library/zen-library.css:1484
`#zen-folder-tabs-popup #zen-folder-tabs-list-search` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/folders/zen-folders.css:239
`.urlbar-background` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/common/styles/zen-omnibox.css:71
`#urlbar[focused="true"]:not([suppress-focus-border]) > .urlbar-background` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/common/styles/zen-omnibox.css:83
`#identity-icon-box` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/common/styles/zen-omnibox.css:115
`.zbs-info-text input:focus` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/boosts/zen-boosts-share.css:141
`.zbs-info-text input` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/boosts/zen-boosts-share.css:135
`#zen-boost-head-wrapper #zen-boost-name` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible. — src/zen/boosts/zen-boosts.css:232
`#zen-welcome-start #zen-welcome-start-button` moves (`transition: scale 0.15s ease-out`) 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. — src/zen/welcome/zen-welcome.css:69
`#zen-welcome-pages .zen-welcome-option` moves (`transition: scale 0.25s cubic-bezier(0.34, 1.56, 0.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. — src/zen/welcome/zen-welcome.css:438
`#zen-welcome-pages .zen-welcome-mock-browser .zen-welcome-essential` moves (`transition: scale 0.25s cubic-bezier(0.34, 1.56, 0.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. — src/zen/welcome/zen-welcome.css:549
`#tabbrowser-tabs[movingtab] .pinned-tabs-container-separator` moves (`transition: height 0.08s ease-in-out,
padding 0.08s ease-in-out,
opacity 0.06s ease-in-out,
transform 0.1s ease-in-out`) 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. — src/zen/tabs/zen-tabs/vertical-tabs.css:177
`.pinned-tabs-container-separator toolbarbutton .toolbarbutton-icon` moves (`transition: transform 0.15s ease-in-out,
opacity 0.15s`) 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. — src/zen/tabs/zen-tabs/vertical-tabs.css:234
`.tab-label` moves (`transition: transform 0.1s ease-in-out`) 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. — src/zen/tabs/zen-tabs/vertical-tabs.css:524
`.zen-tab-sublabel` moves (`transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out`) 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. — src/zen/tabs/zen-tabs/vertical-tabs.css:529
`#tabbrowser-tabs[movingtab] #tabs-newtab-button` moves (`transition: transform 0.1s ease`) 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. — src/zen/tabs/zen-tabs/vertical-tabs.css:1165
`#tabs-newtab-button .toolbarbutton-text` moves (`transition: transform 0.1s ease-in-out`) 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. — src/zen/tabs/zen-tabs/vertical-tabs.css:1185
`#tabs-newtab-button` moves (`transition: scale 0.1s ease`) 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. — src/zen/tabs/zen-tabs/vertical-tabs.css:1163
`.zen-essentials-container` moves (`transition: max-height 0.3s ease-out,
grid-template-columns 0.3s ease-out`) 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. — src/zen/tabs/zen-tabs/vertical-tabs.css:1246
`tab-group[split-view-group] .tab-group-container` moves (`transition: scale 0.1s ease`) 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. — src/zen/split-view/zen-split-group.inc.css:46
`#zen-splitview-dropzone` moves (`transition: inset ease-out 0.08s`) 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. — src/zen/split-view/zen-split-view.css:24
`#tabbrowser-tabpanels[zen-split-view="true"]:not(.zen-split-view-no-transition):not([zen-split-resizing]) > [zen-split="true"]` moves (`transition: inset 0.09s ease-out`) 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. — src/zen/split-view/zen-split-view.css:74
`& .zen-workspace-icon` moves (`transition: opacity 150ms ease-in-out, transform 150ms ease-in-out`) 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. — src/zen/spaces/overflow-icons.inc.css:27
`#PanelUI-zen-gradient-generator-color-pages > hbox > box` moves (`transition: transform 0.1s`) 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. — src/zen/spaces/zen-gradient-generator.css:118
`#PanelUI-zen-gradient-generator-opacity::-moz-range-thumb` moves (`transition: transform 0.5s`) 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. — src/zen/spaces/zen-gradient-generator.css:236
`.zen-theme-picker-gradient .zen-theme-picker-dot:first-of-type` moves (`transition: transform 0.2s`) 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. — src/zen/spaces/zen-gradient-generator.css:286
`#PanelUI-zen-gradient-generator-texture-wrapper #PanelUI-zen-gradient-generator-texture-handler` moves (`transition: height 0.1s`) 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. — src/zen/spaces/zen-gradient-generator.css:435
`#zen-workspaces-button toolbarbutton` moves (`transition: filter 0.2s,
opacity 0.2s,
width 0.1s,
transform 0.2s`) 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. — src/zen/spaces/zen-workspaces.css:78
`.zen-workspace-scroll-to-tab` moves (`transition: scale 0.15s ease-in-out`) 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. — src/zen/spaces/zen-workspaces.css:345
`:root[zen-sidebar-expanded] .zen-current-workspace-indicator-stack` moves (`transition: margin-inline-end 0.1s`) 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. — src/zen/spaces/zen-workspaces.css:499
`:root[zen-sidebar-expanded] .zen-current-workspace-indicator-chevron` moves (`transition: transform 0.1s, opacity 0.15s`) 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. — src/zen/spaces/zen-workspaces.css:509
`.zen-share-overlay-card` moves (`animation: zen-share-overlay-enter 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) 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. — src/zen/share/zen-share.css:31
`.zen-share-overlay-add` moves (`animation: zen-share-overlay-enter 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) 0.06s
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. — src/zen/share/zen-share.css:41
`#zen-media-controls-toolbar .zen-media-progress-bar::-moz-range-thumb` moves (`transition: transform 0.15s ease-out`) 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. — src/zen/media/zen-media-controls.css:70
`#zen-media-controls-toolbar .zen-media-progress-bar` moves (`transition: height 0.15s ease-out`) 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. — src/zen/media/zen-media-controls.css:48
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 dependencies point inward (Domain ← Application ← Infrastructure/Web) — the clean-architecture dependency rule, checked across the project graph.
Method: Layer violations by name-segment inference (Domain/Core to Application to Infrastructure/Web) over the project-reference graph. Exhaustive over all projects, deterministic.
Other · Architecture — Whether read (query) handlers stay side-effect-free — a query that writes persistent state or raises events breaks CQS and makes reads unsafe to retry, cache, or route to a read replica.
Method: Roslyn scan: CQRS handlers classified query-vs-command by interface (IQueryHandler/ICommandHandler/IRequestHandler<TQuery,TResult>) and name convention (*Query/Get*/Find* vs *Command); each query handler's body checked for persistent-state writes (SaveChanges/repository Add-Update) or event publishes by resolved invocation. Deterministic, type-level, exhaustive over the detected handlers.
Coverage: Population: CQRS handlers identified by IQueryHandler/ICommandHandler/IRequestHandler interface + *Query/Get*/Find*/*Command NAME convention; query purity then checked exhaustively within that set — a query handler using neither convention is invisible, and mutation is a resolved persistence/publish CALL, not full dataflow.
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.
`onZapButtonPressed` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/boosts/ZenBoostsEditor.mjs:598
`onFocusButtonPressed` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/boosts/ZenBoostsEditor.mjs:604
`onPickerButtonPressed` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/boosts/ZenBoostsEditor.mjs:611
`initialize` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. (×2) — src/zen/boosts/ZenSelectorComponent.sys.mjs:73, src/zen/boosts/ZenZapOverlayChild.sys.mjs:58
`#onPopupShowing` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/common/emojis/ZenEmojiPicker.mjs:176
`addCustomColor` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — REDACTED:825
`#clearAnyZombieTabs` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/spaces/ZenSpaceManager.mjs:1210
`reorderWorkspace` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/spaces/ZenSpaceManager.mjs:1618
`#fixCtrlTabBehavior` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/spaces/ZenSpaceManager.mjs:2795
`contextChangeContainerTab` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/spaces/ZenSpaceManager.mjs:3225
`closeAllUnpinnedTabs` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/spaces/ZenSpaceManager.mjs:3239
`handleTabBrowserDiscarded` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — src/zen/split-view/ZenViewSplitter.mjs:172
What to do
Remove the dead code that looks live: delete dead if(false) branches, which read as logic that runs, and either do the real async work or drop the async keyword from fake-async functions, which promise work they never wait for.
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.
What to do
Add a build/run (quick start) section to the root README — the first thing a newcomer needs.
Explain in the README how to run the tests. Add a section called Testing to the README in the repository's top folder, saying how to run the test suite.
Maturity · Maturity — Whether key decisions (ADRs) and the high-level shape (C4/diagrams) are written down.
Method: Filesystem scan: ADR folder/naming conventions or content, plus Mermaid/PlantUML/C4/architecture.md discovery. Exhaustive, deterministic.
No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
What to do
Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them.
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.
No logging or diagnostics emission found. This repository ships a binary its users launch rather than a service you operate, so there is no operator to page — but when a run fails on a user's machine, neither they nor you have anything to read.
What to do
Write a diagnostic trail the user can hand back with a bug report: a log file under the platform's per-user data directory, switchable with a `--verbose`/`--debug` flag. Start with the error paths that emit nothing — a discarded error is the failure the user cannot describe and you cannot reproduce.
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.
No static application security testing detected. For this repository's stack, add CodeQL's Swift pack (Swift/Xcode) (or `semgrep --config=auto`, which runs on any language) as a CI step. What was searched, so you can tell an absence from a miss: the 16 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner. — REDACTED:7
`package.json` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`. — package.json:51
What to do
Add a SAST step to CI running what this repository's stack ships: CodeQL's Swift pack (Swift/Xcode) — or `semgrep --config=auto`, which runs on any language — so a security regression fails the build instead of landing.
Enable Dependabot/Renovate or a dependency-review gate.
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.
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.
Do you agree with this assessment?
R1 · Type Safety0.0 / 10Critical✓ 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.
0 typed · 859 plain JS — the untyped files are scripts/build_tokens.mjs, scripts/tokens_studio.mjs, src/browser/components/preferences/zen-settings.js, src/zen/about/zen-about.js, src/zen/boosts/ZenBoostReceiveDialog.mjs, src/zen/boosts/ZenBoostShareDialog.mjs (+853 more).
What to do
Adopt TypeScript for the frontend: add a typecheck step to the build, then either type-check the existing JavaScript in place (`checkJs`/JSDoc types) or convert the highest-traffic modules first — no file is typed today, so this is an adoption, not a clean-up.
React / JS · Code Health — Near-exact copy-pasted blocks of substantial extent across the frontend (the D4 clone algorithm over JS/TS tokens, D-386): a block is reported only where its copies still agree on most of their own identifiers and literals, or were renamed as they were pasted but kept most of their constants, and where the copies carry enough code to stand on their own or the copied extent reaches 30 lines — so a re-implementation sharing neither names nor values, and a small pasted declaration, are both found and deliberately not reported, and a clean R10 is not a claim that nothing was copied.
Method: Near-exact copy-pasted blocks of substantial extent across the frontend (the D4 clone algorithm run over JS/TS tokens). Masking finds the candidates; a block is reported when its copies still agree on most of their own identifiers and literals, or when a renamed copy still agrees on most of its constants, AND the copies carry enough code to stand on their own — or when the copied extent reaches 30 lines. So a re-implementation sharing neither names nor values, and a small pasted declaration, are deliberately not counted. Deterministic.
9 duplicated blocks under src/zen/ have copies in at least two of the sibling directories about, boosts, common, downloads, glance, library (+6 more sibling(s) not listed) — 4 of them are reported below, and 5 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 9 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 9 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 9 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. — src/zen/library/ZenLibrary.mjs:698
src/zen/library/ZenLibraryWidget.sys.mjs:467 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:159 — the two spans are one implementation copied and then locally edited — 408 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. — src/zen/library/ZenLibraryWidget.sys.mjs:467
src/zen/library/ZenLibrary.mjs:698 · src/zen/spaces/ZenSpaceAddSwipe.mjs:144 — the two spans are one implementation copied and then locally edited — 153 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. — src/zen/library/ZenLibrary.mjs:698
src/zen/boosts/ZenSelectorComponent.sys.mjs:162 · src/zen/boosts/ZenZapDissolve.sys.mjs:524 — the two spans are one implementation copied and then locally edited — 141 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. — src/zen/boosts/ZenSelectorComponent.sys.mjs:162
src/zen/boosts/ZenBoostsEditor.mjs:684 · REDACTED:567 — the two spans are one implementation copied and then locally edited — 202 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. — src/zen/boosts/ZenBoostsEditor.mjs:684
src/zen/boosts/ZenBoostReceiveDialog.mjs:37 · src/zen/boosts/ZenBoostShareDialog.mjs:49 — 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. — src/zen/boosts/ZenBoostReceiveDialog.mjs:37
src/zen/library/ZenLibraryWidget.sys.mjs:294 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:382 — 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. — src/zen/library/ZenLibraryWidget.sys.mjs:294
src/zen/library/ZenLibraryWidget.sys.mjs:444 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:139 — 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. — src/zen/library/ZenLibraryWidget.sys.mjs:444
src/zen/split-view/ZenViewSplitter.mjs:468 · src/zen/split-view/ZenViewSplitter.mjs:486 — 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. — src/zen/split-view/ZenViewSplitter.mjs:468
src/zen/split-view/ZenViewSplitter.mjs:579 · src/zen/split-view/ZenViewSplitter.mjs:596 — 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. — src/zen/split-view/ZenViewSplitter.mjs:579
src/zen/tabs/ZenPinnedTabManager.mjs:1139 · src/zen/tabs/ZenPinnedTabManager.mjs:1163 — 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. — src/zen/tabs/ZenPinnedTabManager.mjs:1139
src/zen/urlbar/ZenSiteDataPanel.sys.mjs:298 · src/zen/urlbar/ZenSiteDataPanel.sys.mjs:646 — the two spans are one implementation copied and then locally edited — 126 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. — src/zen/urlbar/ZenSiteDataPanel.sys.mjs:298
src/zen/folders/ZenFolders.mjs:1970 · src/zen/folders/ZenFolders.mjs:2030 — 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. — src/zen/folders/ZenFolders.mjs:1970
src/zen/library/sections/ZenLibraryBoostsSection.mjs:206 · src/zen/library/sections/ZenLibraryHistorySection.mjs:200 — 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. — src/zen/library/sections/ZenLibraryBoostsSection.mjs:206
src/zen/library/sections/ZenLibrarySpacesSection.mjs:160 · src/zen/library/sections/ZenLibrarySpacesSection.mjs:177 — 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. — src/zen/library/sections/ZenLibrarySpacesSection.mjs:160
src/zen/split-view/ZenViewSplitter.mjs:501 · src/zen/split-view/ZenViewSplitter.mjs:610 — 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. — src/zen/split-view/ZenViewSplitter.mjs:501
src/zen/library/ZenLibraryMediaPreview.mjs:500 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:436 — the two spans are one implementation copied and then locally edited — 60 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. — src/zen/library/ZenLibraryMediaPreview.mjs:500
src/zen/library/sections/ZenLibraryDownloadsSection.mjs:558 · src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:154 — the two spans are one implementation copied and then locally edited — 82 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. — src/zen/library/sections/ZenLibraryDownloadsSection.mjs:558
src/zen/spaces/ZenSpaceCreation.mjs:110 · src/zen/spaces/ZenSpaceCreation.mjs:131 — 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. — src/zen/spaces/ZenSpaceCreation.mjs:110
src/zen/library/ZenLibrary.mjs:540 · src/zen/library/ZenLibrary.mjs:645 — the two spans are one implementation copied and then locally edited — 75 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. — src/zen/library/ZenLibrary.mjs:540
src/zen/library/ZenLibraryWidget.sys.mjs:343 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:541 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — src/zen/library/ZenLibraryWidget.sys.mjs:343
REDACTED:1154 · REDACTED:1306 — 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. — REDACTED:1154
src/zen/boosts/ZenBoostsEditor.mjs:508 · src/zen/boosts/ZenBoostsEditor.mjs:559 — 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. — src/zen/boosts/ZenBoostsEditor.mjs:508
src/zen/boosts/zen-boost-receive.js:7 · src/zen/boosts/zen-boost-share.js:7 — 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. — src/zen/boosts/zen-boost-receive.js:7
src/zen/common/modules/ZenCommonUtils.mjs:170 · src/zen/urlbar/ZenSiteDataPanel.sys.mjs:754 — the two spans are one implementation copied and then locally edited — 55 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. — src/zen/common/modules/ZenCommonUtils.mjs:170
src/zen/downloads/ZenDownloadAnimation.mjs:212 · src/zen/glance/ZenGlanceManager.mjs:960 — 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. — src/zen/downloads/ZenDownloadAnimation.mjs:212
src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:42 · src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:115 — the two spans are one implementation copied and then locally edited — 63 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. — src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:42
src/zen/sessionstore/ZenWindowSync.sys.mjs:1493 · src/zen/sessionstore/ZenWindowSync.sys.mjs:1507 — 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. — src/zen/sessionstore/ZenWindowSync.sys.mjs:1493
src/browser/components/preferences/zen-settings.js:520 · src/browser/components/preferences/zen-settings.js:615 — all 2 copies are in the same file, and the CITED SPAN is a run of DECLARATIONS inside a construct — the members of a type, or the entries of an object or array literal — with no statement anywhere in it. Do not read this as an extract-a-helper row: nothing here executes, so there is no call site, and a call expression cannot stand where a member declaration or a literal's entry was. What repeats is a SHAPE, and which shape decides the move. Where the copies declare the same members, the repetition is a missing common ancestor: give it a base type, an interface both extend, a generic instantiated twice, or — where the copies are a literal's entries rather than a type's members — one shared constant each site spreads or refers to, so the set is written once. Where they declare DIFFERENT members and only the form is shared — a decorator and its options, an annotation, a registration table's keys — the form is prescribed by a framework or a schema rather than copied, and the only collapse available is to generate the declarations from that schema; where you do not own the generator, this is the cost of the framework and there is nothing to extract. Check which of the two it is before acting: these copies still drift apart the first time only one of them is edited, which is why the repetition is reported, but the sentence to act on is not the same in both cases. — src/browser/components/preferences/zen-settings.js:520
src/zen/boosts/ZenZapDissolve.sys.mjs:562 · src/zen/boosts/ZenZapDissolve.sys.mjs:594 — 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. — src/zen/boosts/ZenZapDissolve.sys.mjs:562
src/zen/boosts/ZenBoostsEditor.mjs:980 · src/zen/boosts/ZenBoostsEditor.mjs:1063 — 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. — src/zen/boosts/ZenBoostsEditor.mjs:980
src/zen/folders/ZenFolders.mjs:1741 · src/zen/folders/ZenFolders.mjs:1860 — 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. — src/zen/folders/ZenFolders.mjs:1741
src/zen/boosts/ZenSelectorComponent.sys.mjs:693 · src/zen/boosts/ZenSelectorComponent.sys.mjs:707 — 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. — src/zen/boosts/ZenSelectorComponent.sys.mjs:693
src/zen/boosts/actors/ZenBoostsChild.sys.mjs:383 · src/zen/boosts/actors/ZenBoostsChild.sys.mjs:421 — 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. — src/zen/boosts/actors/ZenBoostsChild.sys.mjs:383
src/zen/library/sections/ZenLibraryHistorySection.mjs:602 · src/zen/library/sections/ZenLibraryHistorySection.mjs:616 — 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. — src/zen/library/sections/ZenLibraryHistorySection.mjs:602
REDACTED:1231 · REDACTED:1356 — 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. — REDACTED:1231
src/zen/boosts/ZenBoostsEditor.mjs:100 · src/zen/boosts/ZenBoostsEditor.mjs:110 · src/zen/boosts/ZenBoostsEditor.mjs:128 · src/zen/boosts/ZenBoostsEditor.mjs:140 — all 4 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. — src/zen/boosts/ZenBoostsEditor.mjs:100
src/zen/boosts/ZenBoostsEditor.mjs:887 · src/zen/boosts/ZenBoostsEditor.mjs:1023 — 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. — src/zen/boosts/ZenBoostsEditor.mjs:887
src/zen/boosts/ZenBoostsManager.sys.mjs:347 · src/zen/boosts/ZenBoostsManager.sys.mjs:369 — 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. — src/zen/boosts/ZenBoostsManager.sys.mjs:347
src/zen/migration/ZenMigrationUtils.sys.mjs:524 · src/zen/migration/ZenMigrationUtils.sys.mjs:538 — the two spans are one implementation copied and then locally edited — 80 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. — src/zen/migration/ZenMigrationUtils.sys.mjs:524
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 · 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.
_updateEvent has cyclomatic complexity 82 and cognitive complexity 102; 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. — src/zen/common/modules/ZenVerticalTabsManager.mjs:399
#applyDragoverIndicator has cyclomatic complexity 55 and cognitive complexity 57; 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. — src/zen/drag-and-drop/ZenDragAndDrop.js:1598
(anonymous) has cyclomatic complexity 47 and cognitive complexity 69; 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:1919
#animateVerticalPinnedGridDragOver has cyclomatic complexity 46 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. — src/zen/drag-and-drop/ZenDragAndDrop.js:1813
#animateTabs has cyclomatic complexity 44 and cognitive complexity 84; 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. — src/zen/spaces/ZenSpaceManager.mjs:2365
moveTabToSplitView has cyclomatic complexity 43 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. — src/zen/split-view/ZenViewSplitter.mjs:2154
(anonymous) has cyclomatic complexity 39 and cognitive complexity 84; 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. — src/zen/tests/performance/browser_startup_content_mainthreadio.js:244
moveToAnotherTabContainerIfNecessary has cyclomatic complexity 39 and cognitive complexity 74; 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. — src/zen/tabs/ZenPinnedTabManager.mjs:756
_animateTabMove has cyclomatic complexity 36 and cognitive complexity 45; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — src/zen/drag-and-drop/ZenDragAndDrop.js:284
handle_drop_transition has cyclomatic complexity 36 and cognitive complexity 32; 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. — src/zen/drag-and-drop/ZenDragAndDrop.js:1319
(anonymous) has cyclomatic complexity 35 and cognitive complexity 71; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — src/zen/tests/performance/browser_startup_mainthreadio.js:589
onCloseTabShortcut has cyclomatic complexity 32 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. — src/zen/tabs/ZenPinnedTabManager.mjs:315
#applySpaces has cyclomatic complexity 29 and cognitive complexity 36; 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. — src/zen/sync/ZenSpacesSyncApplier.sys.mjs:313
onBrowserDragOverToSplit has cyclomatic complexity 29 and cognitive complexity 24; 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. — src/zen/split-view/ZenViewSplitter.mjs:325
selectStartPage has cyclomatic complexity 28 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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. — src/zen/spaces/ZenSpaceManager.mjs:980
animateSelect has cyclomatic complexity 27 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. — src/zen/folders/ZenFolders.mjs:2113
_buildModsList has cyclomatic complexity 27 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. — src/browser/components/preferences/zen-settings.js:277
handleStorage has cyclomatic complexity 27 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. — src/zen/tests/mochitests/sync/head_http_server.js:1055
#applyFolders has cyclomatic complexity 27 and cognitive complexity 42; 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. — src/zen/sync/ZenSpacesSyncApplier.sys.mjs:425
#updateTabIdentity has cyclomatic complexity 27 and cognitive complexity 27; 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. — src/zen/sync/ZenSpacesSyncApplier.sys.mjs:608
applyDragoverClass has cyclomatic complexity 26 and cognitive complexity 36; 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. — src/zen/tabs/ZenPinnedTabManager.mjs:1055
(anonymous) has cyclomatic complexity 25 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. — src/zen/tests/performance/browser_startup.js:144
restoreDataFromSessionStore has cyclomatic complexity 25 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. — src/zen/folders/ZenFolders.mjs:1326
#childSequence has cyclomatic complexity 25 and cognitive complexity 43; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — src/zen/sync/ZenSpacesSyncModel.sys.mjs:358
onPinnedTabsResize has cyclomatic complexity 25 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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. — src/zen/spaces/ZenSpaceManager.mjs:3044
receiveMessage has cyclomatic complexity 25 and cognitive complexity 33; 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. — src/zen/boosts/actors/ZenBoostsParent.sys.mjs:108
setFolderIndentation has cyclomatic complexity 25 and cognitive complexity 25; 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. — src/zen/folders/ZenFolders.mjs:1112
(anonymous) has cyclomatic complexity 24 and cognitive complexity 39; 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. — src/zen/tests/performance/browser_startup_syncIPC.js:338
#updateDropTarget has cyclomatic complexity 24 and cognitive complexity 26; 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. — src/zen/library/ZenLibraryDragAndDrop.mjs:261
_handle_tabDragOverToSplit has cyclomatic complexity 24 and cognitive complexity 16; 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. — src/zen/drag-and-drop/ZenDragAndDrop.js:913
_organizeWorkspaceStripLocations has cyclomatic complexity 23 and cognitive complexity 37; 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. — src/zen/spaces/ZenSpaceManager.mjs:2140
animateExpand has cyclomatic complexity 22 and cognitive complexity 50; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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. — src/zen/folders/ZenFolders.mjs:1824
applyBatch has cyclomatic complexity 22 and cognitive complexity 29; 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. — src/zen/sync/ZenSpacesSyncApplier.sys.mjs:73
onStateChange has cyclomatic complexity 22 and cognitive complexity 16; 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. — src/zen/space-routing/ZenSpaceRoutingNavigation.sys.mjs:27
(anonymous) has cyclomatic complexity 21 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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. — src/zen/split-view/ZenViewSplitter.mjs:1438
importStudioTokens has cyclomatic complexity 21 and cognitive complexity 33; 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/tokens_studio.mjs:428
#runStateMigration has cyclomatic complexity 21 and cognitive complexity 32; 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:488
fetchItems has cyclomatic complexity 21 and cognitive complexity 31; 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. — src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:24
start has cyclomatic complexity 21 and cognitive complexity 17; 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. — src/zen/tabs/ZenTabRenamer.mjs:31
#setSitePermissions has cyclomatic complexity 20 and cognitive complexity 36; 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. — src/zen/urlbar/ZenSiteDataPanel.sys.mjs:488
Do you agree with this assessment?
R3 · Large Files0.0 / 10Critical✓ 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.
src/zen/spaces/ZenSpaceManager.mjs has 3449 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/spaces/ZenSpaceManager.mjs:1
src/zen/split-view/ZenViewSplitter.mjs has 2456 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/split-view/ZenViewSplitter.mjs:1
REDACTED has 2295 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
src/zen/folders/ZenFolders.mjs has 2197 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/folders/ZenFolders.mjs:1
src/zen/drag-and-drop/ZenDragAndDrop.js has 2107 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/drag-and-drop/ZenDragAndDrop.js:1
src/zen/glance/ZenGlanceManager.mjs has 1924 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/glance/ZenGlanceManager.mjs:1
src/zen/sessionstore/ZenWindowSync.sys.mjs has 1694 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/sessionstore/ZenWindowSync.sys.mjs:1
src/zen/boosts/ZenBoostsEditor.mjs has 1595 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/boosts/ZenBoostsEditor.mjs:1
src/zen/tabs/ZenPinnedTabManager.mjs has 1112 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/tabs/ZenPinnedTabManager.mjs:1
src/zen/library/sections/ZenLibrarySpacesSection.mjs has 1079 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/library/sections/ZenLibrarySpacesSection.mjs:1
src/zen/library/ZenLibrary.mjs has 1070 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/library/ZenLibrary.mjs:1
REDACTED has 1021 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
src/zen/compact-mode/ZenCompactMode.mjs has 980 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/compact-mode/ZenCompactMode.mjs:1
src/zen/welcome/ZenWelcome.mjs has 975 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/welcome/ZenWelcome.mjs:1
src/zen/sync/ZenSpacesSyncApplier.sys.mjs has 916 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/sync/ZenSpacesSyncApplier.sys.mjs:1
src/zen/boosts/ZenBoostsManager.sys.mjs has 893 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/boosts/ZenBoostsManager.sys.mjs:1
src/zen/urlbar/ZenSiteDataPanel.sys.mjs has 880 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/urlbar/ZenSiteDataPanel.sys.mjs:1
src/zen/share/ZenShareManager.mjs has 824 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/share/ZenShareManager.mjs:1
src/zen/sync/ZenSpacesSyncModel.sys.mjs has 821 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/sync/ZenSpacesSyncModel.sys.mjs:1
src/zen/library/sections/ZenLibraryDownloadsSection.mjs has 746 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/library/sections/ZenLibraryDownloadsSection.mjs:1
src/zen/library/sections/ZenLibraryHistorySection.mjs has 728 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/library/sections/ZenLibraryHistorySection.mjs:1
src/browser/components/preferences/zen-settings.js has 726 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/browser/components/preferences/zen-settings.js:1
src/zen/media/ZenMediaController.sys.mjs has 716 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/media/ZenMediaController.sys.mjs:1
src/zen/common/modules/ZenVerticalTabsManager.mjs has 706 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/common/modules/ZenVerticalTabsManager.mjs:1
src/zen/library/ZenLibraryWidget.sys.mjs has 704 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/library/ZenLibraryWidget.sys.mjs:1
src/zen/boosts/ZenSelectorComponent.sys.mjs has 689 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/boosts/ZenSelectorComponent.sys.mjs:1
src/zen/migration/ZenMigrationUtils.sys.mjs has 683 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/migration/ZenMigrationUtils.sys.mjs:1
src/zen/spaces/ZenSpace.mjs has 669 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/spaces/ZenSpace.mjs:1
REDACTED has 659 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
src/zen/mods/ZenMods.mjs has 630 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/mods/ZenMods.mjs:1
src/zen/live-folders/ZenLiveFoldersManager.sys.mjs has 629 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/live-folders/ZenLiveFoldersManager.sys.mjs:1
src/zen/common/modules/ZenUIManager.mjs has 627 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/common/modules/ZenUIManager.mjs:1
src/zen/urlbar/ZenUBActionsProvider.sys.mjs has 564 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/urlbar/ZenUBActionsProvider.sys.mjs:1
src/zen/library/ZenLibraryMediaPreview.mjs has 541 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/library/ZenLibraryMediaPreview.mjs:1
src/zen/boosts/ZenZapDissolve.sys.mjs has 534 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/boosts/ZenZapDissolve.sys.mjs:1
src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs has 533 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:1
src/zen/boosts/ZenBoostShareDialog.mjs has 504 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/boosts/ZenBoostShareDialog.mjs:1
src/zen/common/sys/ZenPGOTraining.sys.mjs has 494 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/common/sys/ZenPGOTraining.sys.mjs:1
src/zen/downloads/ZenDownloadAnimation.mjs has 475 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/downloads/ZenDownloadAnimation.mjs:1
src/zen/library/sections/ZenLibraryMediaSection.mjs has 447 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module. — src/zen/library/sections/ZenLibraryMediaSection.mjs:1
What to do
Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.
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 · Tooling6.7 / 10Adequate✓ 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.
test ✓ · lint ✓ · typecheck ✗ — read from this repository's package.json scripts and corroborated against its CI workflows. A script counts when its name or command matches the step: `test` for the suite, `lint` or `prettier` for linting, `typecheck`/`type-check`/`tsc` for type checking. ✗ therefore means no script or CI step under those names was found, NOT that the step is absent from your pipeline — a task invoked by a runner this check does not read, or named something else entirely, is not seen and is worth confirming before acting on a cross. A ✓ means the wiring is DECLARED — a script or CI step under those names exists. It is not a statement that the step passes, or that it runs at all: nothing here installs a dependency or executes a suite.
What to do
Add type checking (adopt TypeScript, or type-check the existing JavaScript with `checkJs`) as package.json scripts and run them in CI.
Do you agree with this assessment?
R7 · Dead Code5.1 / 10Adequate✓ 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 32 application, 7 tooling and 755 test entry point(s) detected in this repo. Gate removals on `npm run build` — an undetected custom entry would make these reachable.
no import path from any entry point (32 application, 7 tooling, 755 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 (×39) — src/zen/spaces/ZenSpaceManager.mjs, src/zen/split-view/ZenViewSplitter.mjs, REDACTED, …
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.
Declared in the root package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
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.
The function passed to `new Promise(…)` is `async`. The constructor ignores what its executor returns, so anything this executor throws — every throw inside an `async` function, including after an `await` — rejects a Promise nobody holds instead of the one being constructed: the outer Promise never settles, whoever awaits it hangs, and the error is reported nowhere. If the body needs `await`, it does not need `new Promise` at all: make the enclosing function `async` and `return` the value (or `throw`) directly. If it wraps a callback API, keep the executor synchronous — call the API and `resolve`/`reject` from its callback — and do the awaiting outside it. (×2) — src/zen/sessionstore/ZenWindowSync.sys.mjs:1022, src/zen/glance/ZenGlanceManager.mjs:607
`forEach` ignores what its callback returns, so the Promise each `async` call returns is dropped: nothing can await it, the code after this loop runs before any of the awaited work has finished (a function that `await`s around this loop still returns early), and a rejection is never handled — in Node.js an unhandled rejection terminates the process by default, and in a browser it is lost. Iterate with `for (const item of items) { await … }` when the work must run in order, or `await Promise.all(items.map(async (item) => { … }))` when it may run concurrently, so the enclosing function finishes only when the work does and its failures reach the caller. Where firing and forgetting is genuinely intended, make the callback's whole body a `try { … } catch (e) { … }` that handles the failure, so it cannot escape. — src/zen/boosts/ZenZapOverlayChild.sys.mjs:125
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.
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 method that temporarily changes state belonging to the whole process — the working directory, an environment variable — puts it back on EVERY path: a restore reached only when nothing throws leaks the change to the rest of the process.
Method: Roslyn syntax + semantics: method bodies that write the process working directory or an environment variable and write it back in the same body, checked for whether that restore sits in a `finally`/`catch` or only on the straight-line path. On a repository with no .NET source the same rule reads production JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not): `process.chdir`, `process.env.NAME =`/`["NAME"] =` and `delete process.env.NAME`, and Deno’s `Deno.chdir`/`Deno.env.set`/`Deno.env.delete`, paired per function body (a nested function or arrow is its own body, and module top-level code is none), where the last write puts back a local the body captured from the same global or deletes a variable the first write set, with at least one statement between them; a write in a `catch`/`finally` of that body silences it. Deterministic, provable per finding. Advisory.
Other · Code Health — Whether async functions that make a cancellable request accept or pass on an AbortSignal (adoption curve).
Method: Roslyn scan: every async method (excluding framework-fixed overrides/Blazor handlers) checked for CancellationToken parameter presence. Deterministic, adoption percentage. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same question: every named async function that itself makes a request an AbortSignal can cancel (global `fetch`, axios and its file-local instances, ky, ofetch) counts, and it is compliant when its parameters or body name a signal or it hands one of its own parameters to the request as options; signatures a framework fixes (JSX event handlers, route and lifecycle exports, request-first handlers, `override`, `'use server'` modules, TanStack `mutationFn`) are exempt unless they take a signal. Deterministic, adoption percentage.
Only 1/5 async functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, an unmounted component, a timed-out job. Take a `signal` (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
`getIconData` 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 })`. — src/zen/welcome/ZenWelcome.mjs:113
`downloadUrlToFile` 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 })`. — src/zen/mods/ZenMods.mjs:326
`requestMod` 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 })`. — src/zen/mods/ZenMods.mjs:734
`getMetadata` 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 })`. — src/zen/live-folders/providers/RssLiveFolder.sys.mjs:186
What to do
Thread an AbortSignal through async 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 unescaped10.0 / 10Exemplary○ Nothing flagged
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.
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.
`.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it. (×8) — src/zen/welcome/ZenWelcome.mjs:105, REDACTED:609, src/zen/library/ZenLibraryUtils.sys.mjs:233, …
An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it. (×26) — src/zen/welcome/ZenWelcome.mjs:573, src/zen/urlbar/ZenUBActionsProvider.sys.mjs:104, src/zen/urlbar/ZenUBResultsLearner.sys.mjs:18, …
`catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, or keep only the failure you expect and rethrow the rest (`catch (e) { if (!(e instanceof SyntaxError)) throw e; … }`, or test `e.name`), because a JavaScript catch takes every exception, programming errors included. — src/zen/urlbar/ZenUBGlobalActions.sys.mjs:171
`catch (e)` 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, or keep only the failure you expect and rethrow the rest (`catch (e) { if (!(e instanceof SyntaxError)) throw e; … }`, or test `e.name`), because a JavaScript catch takes every exception, programming errors included. (×3) — src/zen/space-routing/ZenSpaceRoutingNavigation.sys.mjs:41, src/zen/space-routing/ZenSpaceRoutingNavigation.sys.mjs:123, src/zen/drag-and-drop/ZenDragAndDrop.js:1342
`.then(…, () => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it. — src/zen/common/modules/ZenSidebarNotification.mjs:74
`except BaseException` 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. — src/browser/themes/shared/zen-icons/check_unused_icons.py:39
What to do
Swallowed exception (empty catch)
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.
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 — 3 check(s) recorded observations but carry no score
These checks ran and found something, but they do not carry a score — either by design (an advisory check reports evidence rather than grading it) or because they could not be scored here. They are excluded from the score for that reason, not because there was nothing to see.
X10 Duplicated predicate — 7 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
X7 Silent fallback defaults — 9 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 — 55 check(s) not relevant to this codebase
These checks had nothing to measure here (no tests, no git history, the codebase is small, or the architecture style doesn't apply), so they're omitted above rather than scored low.
AX1 Captive dependencies — Not applicable: this repository's JavaScript imports no dependency-injection container and defines no container of its own — nothing that both registers and resolves bindings, and nothing that names two lifetimes — so nothing holds one lifetime's instance while handing out another's; this repository's Python imports no dependency-injection container and defines no container of its own — nothing that both registers and resolves bindings, and nothing that names two lifetimes — so nothing holds one lifetime's instance while handing out another's; Rust with no dependency-injection crate has no container to hand one lifetime's instance to another — every value is owned by the code that builds it, and the borrow checker rejects a longer-lived value keeping a borrow of a shorter-lived one; this repository's Swift imports no dependency-injection container and defines no container of its own — nothing that both registers and resolves bindings, and nothing that names two lifetimes — so nothing holds one lifetime's instance while handing out another's.
AX2 Stateful singletons — No container singleton was found, so there is no shared instance for concurrent requests to race on. No function in this Python code is served by a threaded web framework (a Flask, Bottle or FastAPI route, a Django or Pyramid view), so no module is shared between request threads. No Swift request handler (a Vapor, Hummingbird, Kitura, Swifter or Perfect route handler, as a method or a registered closure) is declared, so no state is shared between request threads. 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).
AX5 Architecture & structure — not assessed — architecture style/structure is computed from a project graph (projects, types, module namespaces) that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
AX6 Interface segregation — not assessed — interface segregation is computed over a type surface that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
AX7 Slice cohesion — not applicable — not a vertical-slice architecture
AX8 Test isolation — no test/production split to check
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 start`) exited before it served a page. Likely cause (not identified): the dev server exited, and its output does not match a cause we recognise. Last output: "> zen-desktop@1.0.0 start / > cd engine && python3 ./mach run --noprofile / sh: 1: cd: can't cd to engine" 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.
D10 Test Quality — ~5052 lines of test source are present (.py) but no test cases reached the test census for this repository — no test root we could resolve declared them, or the files we read declare no cases in a test framework we recognise — so skipped/assertion-free tests couldn't be counted. Not scored — this is a gap in the analyzer, not a finding about this repository.
D11 Test Reliability — Test reliability not included — the .py suite was found but not re-run
D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
D21 Naming Consistency — Naming consistency does not read html yet; not measured.
D22 Internal API Consistency — The exposed public-API surface could not be collected — no C#/VB projects loaded.
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 — no ADRs to check
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) — 2 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
D4 Code Duplication — Duplication not measured — .cc, .cpp, .mm not exposed to the token comparison
D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
D8 Code Coverage — Coverage not included — suite not readable by the collector
DM1 Domain Modelling — not scored — this repository shows none of the 3 signals this lens looks for
ED2 Event/command shape — not scored — deciding whether a command has more than one competing handler requires resolving the call graph, and this analysis resolves a call's owner only where the receiver's type is written down in the source. Reported as guidance rather than measured
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
P12 CI test-gate honesty — Reported, not scored — and nothing was matched here. The coverage check applies to any stack, and the automatic-re-run check to any GitHub-Actions workflow, but the checks for excluded tests, skipped tests and sleep-based synchronisation currently recognise only some ecosystems' test-runner idioms, so on a repository built with another stack the zeros below mean 'not checked', not 'clean'.
P7 Outbound HTTP resilience — not applicable — no HTTP server, API framework or worker entry point was found in the JavaScript/TypeScript, Python, Rust, Swift source, so there is no service whose uptime a failing dependency could take down
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 not measured: this check compares the coverage of the analyzer's own test run across the domain and web layers, and that run measured none here — Test coverage (D8) says why
PF1 Benchmark discipline — Not applicable: no benchmark suite was found. This check searched for tinybench, mitata, benchmark.js, benny or vitest `bench(...)` calls in files that import them (or `*.bench.*` files), or one of those in a package.json, and for a `*benchmark*` script that this repository's CI runs. Benchmarks are credited as a bonus, so their absence is neither scored nor deducted.
PF2 Allocation hygiene — Not 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.
R11 Import Boundaries — No recognizable feature-sliced/layered src layout — boundary rules not applicable.
R4 Test Coverage — 755 test file(s) reach none of 100 production file(s) via imports — exercised outside the JS import graph (integration/bundled), not import-reachable
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.
SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
X13 Undrained process stream — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
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
X18 Disposal-pattern correctness — 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 — This check asks whether an argument guard reports an EMPTY value as a NULL one, which needs a language that throws a null-specific argument exception — .NET's ArgumentNullException, the JVM's NullPointerException, Dart's ArgumentError.notNull. This repository contains none of those languages: the ones it is written in have a single exception for a bad argument, so there is no pair of exceptions to confuse and nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
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
X25 Inert configuration knob — 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 — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X27 Collection changed while being enumerated — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
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 Rust was read, and it logs through none: the `log` crate's macros take one finished message (as log4net does in C#; its `kv` values are an opt-in its backends mostly drop), `println!`/`eprintln!` are not loggers, or it makes no log call outside its tests and examples at all. Calls through `tracing` (`tracing::info!`, or `info!` imported from it) would be judged.
X5 Nullable reference types — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X6 Hand-rolled structured-format parsing — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
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.
AC2 · Forms & labels· <button> with no accessible text · ×7
<button> with no accessible text src/browser/components/preferences/zen-settings.js:305— A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
<button> with no accessible text src/zen/boosts/ZenZapBar.mjs:118— A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
<button> with no accessible text src/zen/library/sections/ZenLibraryMediaSection.mjs:476— A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
<button> with no accessible text src/zen/library/sections/ZenLibrarySearchSection.mjs:229— A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
<button> with no accessible text src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:377— A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
<button> with no accessible text src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:415— A button with no text and no aria-label has no accessible name. Add visible text or an aria-label (an icon-only button still needs one).
<button> with no accessible text src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:420— 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).
AC2 · Forms & labels· <label> that labels no control · ×5
<label> that labels no control src/browser/components/preferences/zen-settings.js:298— This <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id.
<label> that labels no control src/zen/common/modules/ZenSidebarNotification.mjs:135— This <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id.
<label> that labels no control src/zen/common/modules/ZenSidebarNotification.mjs:90— This <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id.
<label> that labels no control src/zen/library/ZenLibrary.mjs:1143— This <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id.
<label> that labels no control REDACTED:805— This <label> has no for and wraps no form control, so it names nothing: assistive tech never announces it, and clicking the caption focuses no field. Note that an id on the label is not an association — it is the TARGET of one, so a control still has to point at it. Give the label for="<the control's id>", move the control inside the label, or point the control's aria-labelledby at this label's id.
AC1 · Text alternatives· <img> without a text alternative · ×4
<img> without a text alternative src/zen/common/modules/ZenSidebarNotification.mjs:131— An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative.
<img> without a text alternative src/zen/common/modules/ZenSidebarNotification.mjs:99— An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative.
<img> without a text alternative src/zen/urlbar/ZenSiteDataPanel.sys.mjs:51— An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative.
<img> without a text alternative src/zen/urlbar/ZenSiteDataPanel.sys.mjs:159— An image with no alt (and no aria-label/aria-labelledby) is unreadable to assistive tech. Add alt — alt="" if it's purely decorative.
AC2 · Forms & labels· <input> without a programmatic label · ×2
<input> without a programmatic label src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:388— 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 src/zen/library/sections/ZenLibrarySpacesSection.mjs:993— 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· Custom control with no accessible name on <div> · ×2
Custom control with no accessible name on <div> src/zen/library/sections/ZenLibrarySpacesSection.mjs:759— This <div> carries a click handler, which makes it a control, but it has no text, aria-label or labelled child (the icon-only case), so assistive tech has no name to announce for it. Note that switching it to <button type="button"> — the right fix for its keyboard operability — does not give it a name either: an icon-only button still needs one. Add visible text or an aria-label.
Custom control with no accessible name on <div> src/zen/library/sections/ZenLibrarySpacesSection.mjs:1121— This <div> carries a click handler, which makes it a control, but it has no text, aria-label or labelled child (the icon-only case), so assistive tech has no name to announce for it. Note that switching it to <button type="button"> — the right fix for its keyboard operability — does not give it a name either: an icon-only button still needs one. Add visible text or an aria-label.
<html> without a lang src/browser/themes/shared/zen-icons/nucleo/nucleo-copyright-notice.html:5— The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en").
AC4 · Keyboard semantics· Anchor without href · ×40
Anchor without href locales/ar/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/bg/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/bs/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/ca/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/cs/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/cy/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/da/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/de/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/el/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/en-GB/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/en-US/browser/browser/zen-about.ftl:61— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/es-ES/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/et/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/eu/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/fa/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/fi/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/fr/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/ga-IE/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/he/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/hu/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/id/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/is/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/it/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/ja/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Anchor without href locales/ko/browser/browser/zen-about.ftl:58— An <a> with no href, role or tabindex isn't focusable or keyboard-activatable. Give it a real href, or use a <button> for an action.
Swallowed exception (empty catch) src/zen/welcome/ZenWelcome.mjs:105— `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
Swallowed exception (empty catch) src/zen/welcome/ZenWelcome.mjs:573— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/urlbar/ZenUBActionsProvider.sys.mjs:104— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/urlbar/ZenUBResultsLearner.sys.mjs:18— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/tabs/ZenPinnedTabManager.mjs:278— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/tabs/ZenPinnedTabManager.mjs:468— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/share/ZenShareClient.sys.mjs:135— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) REDACTED:148— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) REDACTED:229— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) REDACTED:243— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) REDACTED:609— `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
Swallowed exception (empty catch) src/zen/sessionstore/ZenWindowSync.sys.mjs:541— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/sessionstore/ZenWindowSync.sys.mjs:845— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/migration/ZenMigrationUtils.sys.mjs:134— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/live-folders/ZenLiveFolder.sys.mjs:81— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/live-folders/ZenLiveFolder.sys.mjs:191— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/live-folders/ZenLiveFolder.sys.mjs:212— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/live-folders/ZenLiveFolder.sys.mjs:309— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/live-folders/ZenLiveFolder.sys.mjs:339— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/live-folders/providers/RssLiveFolder.sys.mjs:97— An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
Swallowed exception (empty catch) src/zen/library/ZenLibraryUtils.sys.mjs:233— `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
Swallowed exception (empty catch) src/zen/library/ZenLibraryWidget.sys.mjs:290— `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
Swallowed exception (empty catch) src/zen/library/ZenLibraryWidget.sys.mjs:624— `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
Swallowed exception (empty catch) src/zen/library/ZenLibraryWidget.sys.mjs:629— `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
Swallowed exception (empty catch) src/zen/library/sections/ZenLibraryDownloadsSection.mjs:421— `.catch(() => {})` handles the rejection by doing nothing — the failure is discarded with no log and no rethrow, and the chain carries on as if the work succeeded. Log it through whatever this codebase already uses to report problems, hand it to a caller that can (`next(error)`, a returned rejection), or don't catch it.
+ 10 more in this group — see findings.md.
AC6 · Visual & motion safety· Animation without a prefers-reduced-motion guard · ×27
Animation without a prefers-reduced-motion guard src/zen/welcome/zen-welcome.css:69— `#zen-welcome-start #zen-welcome-start-button` moves (`transition: scale 0.15s ease-out`) 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 src/zen/welcome/zen-welcome.css:438— `#zen-welcome-pages .zen-welcome-option` moves (`transition: scale 0.25s cubic-bezier(0.34, 1.56, 0.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 src/zen/welcome/zen-welcome.css:549— `#zen-welcome-pages .zen-welcome-mock-browser .zen-welcome-essential` moves (`transition: scale 0.25s cubic-bezier(0.34, 1.56, 0.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 src/zen/tabs/zen-tabs/vertical-tabs.css:177— `#tabbrowser-tabs[movingtab] .pinned-tabs-container-separator` moves (`transition: height 0.08s ease-in-out,
padding 0.08s ease-in-out,
opacity 0.06s ease-in-out,
transform 0.1s ease-in-out`) 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 src/zen/tabs/zen-tabs/vertical-tabs.css:234— `.pinned-tabs-container-separator toolbarbutton .toolbarbutton-icon` moves (`transition: transform 0.15s ease-in-out,
opacity 0.15s`) 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 src/zen/tabs/zen-tabs/vertical-tabs.css:524— `.tab-label` moves (`transition: transform 0.1s ease-in-out`) 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 src/zen/tabs/zen-tabs/vertical-tabs.css:529— `.zen-tab-sublabel` moves (`transition: opacity 0.1s ease-in-out, transform 0.1s ease-in-out`) 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 src/zen/tabs/zen-tabs/vertical-tabs.css:1165— `#tabbrowser-tabs[movingtab] #tabs-newtab-button` moves (`transition: transform 0.1s ease`) 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 src/zen/tabs/zen-tabs/vertical-tabs.css:1185— `#tabs-newtab-button .toolbarbutton-text` moves (`transition: transform 0.1s ease-in-out`) 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 src/zen/tabs/zen-tabs/vertical-tabs.css:1163— `#tabs-newtab-button` moves (`transition: scale 0.1s ease`) 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 src/zen/tabs/zen-tabs/vertical-tabs.css:1246— `.zen-essentials-container` moves (`transition: max-height 0.3s ease-out,
grid-template-columns 0.3s ease-out`) 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 src/zen/split-view/zen-split-group.inc.css:46— `tab-group[split-view-group] .tab-group-container` moves (`transition: scale 0.1s ease`) 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 src/zen/split-view/zen-split-view.css:24— `#zen-splitview-dropzone` moves (`transition: inset ease-out 0.08s`) 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 src/zen/split-view/zen-split-view.css:74— `#tabbrowser-tabpanels[zen-split-view="true"]:not(.zen-split-view-no-transition):not([zen-split-resizing]) > [zen-split="true"]` moves (`transition: inset 0.09s ease-out`) 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 src/zen/spaces/overflow-icons.inc.css:27— `& .zen-workspace-icon` moves (`transition: opacity 150ms ease-in-out, transform 150ms ease-in-out`) 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 src/zen/spaces/zen-gradient-generator.css:118— `#PanelUI-zen-gradient-generator-color-pages > hbox > box` moves (`transition: transform 0.1s`) 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 src/zen/spaces/zen-gradient-generator.css:236— `#PanelUI-zen-gradient-generator-opacity::-moz-range-thumb` moves (`transition: transform 0.5s`) 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 src/zen/spaces/zen-gradient-generator.css:286— `.zen-theme-picker-gradient .zen-theme-picker-dot:first-of-type` moves (`transition: transform 0.2s`) 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 src/zen/spaces/zen-gradient-generator.css:435— `#PanelUI-zen-gradient-generator-texture-wrapper #PanelUI-zen-gradient-generator-texture-handler` moves (`transition: height 0.1s`) 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 src/zen/spaces/zen-workspaces.css:78— `#zen-workspaces-button toolbarbutton` moves (`transition: filter 0.2s,
opacity 0.2s,
width 0.1s,
transform 0.2s`) 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 src/zen/spaces/zen-workspaces.css:345— `.zen-workspace-scroll-to-tab` moves (`transition: scale 0.15s ease-in-out`) 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 src/zen/spaces/zen-workspaces.css:499— `:root[zen-sidebar-expanded] .zen-current-workspace-indicator-stack` moves (`transition: margin-inline-end 0.1s`) 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 src/zen/spaces/zen-workspaces.css:509— `:root[zen-sidebar-expanded] .zen-current-workspace-indicator-chevron` moves (`transition: transform 0.1s, opacity 0.15s`) 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 src/zen/share/zen-share.css:31— `.zen-share-overlay-card` moves (`animation: zen-share-overlay-enter 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) 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 src/zen/share/zen-share.css:41— `.zen-share-overlay-add` moves (`animation: zen-share-overlay-enter 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) 0.06s
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.
FileTooLong: spaces/ZenSpaceManager.mjs src/zen/spaces/ZenSpaceManager.mjs— FileTooLong — 2395 significant lines (blank, comment-only and punctuation-only lines excluded; the length bar is tripled for a single-responsibility module of 4 or fewer top-level units), about 97% of them inside a single declaration: nsZenWorkspaces (45-3748). The bar is 1500 significant lines; this is 895 over it, 1.60× 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: REDACTED REDACTED— FileTooLong — 1703 significant lines (blank, comment-only and punctuation-only lines excluded; the length bar is tripled for a single-responsibility module of 4 or fewer top-level units), about 92% of them inside a single declaration: nsZenThemePicker (156-2527). The bar is 500 significant lines; this is 1203 over it, 3.41× 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: split-view/ZenViewSplitter.mjs src/zen/split-view/ZenViewSplitter.mjs— FileTooLong — 1636 significant lines (blank, comment-only and punctuation-only lines excluded; the length bar is tripled for a single-responsibility module of 4 or fewer top-level units), about 98% of them inside a single declaration: nsZenViewSplitter (73-2657). The bar is 1500 significant lines; this is 136 over it, 1.09× 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: folders/ZenFolders.mjs src/zen/folders/ZenFolders.mjs— FileTooLong — 1536 significant lines (blank, comment-only and punctuation-only lines excluded; the length bar is tripled for a single-responsibility module of 4 or fewer top-level units), about 96% of them inside a single declaration: nsZenFolders (38-2432). The bar is 1500 significant lines; this is 36 over it, 1.02× 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: drag-and-drop/ZenDragAndDrop.js src/zen/drag-and-drop/ZenDragAndDrop.js— FileTooLong — 1411 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 911 over it, 2.82× 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: boosts/ZenBoostsEditor.mjs src/zen/boosts/ZenBoostsEditor.mjs— FileTooLong — 1075 significant lines (blank, comment-only and punctuation-only lines excluded), about 100% of them inside a single declaration: nsZenBoostEditor (9-1823). The bar is 500 significant lines; this is 575 over it, 2.15× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
FileTooLong: glance/ZenGlanceManager.mjs src/zen/glance/ZenGlanceManager.mjs— FileTooLong — 982 significant lines (blank, comment-only and punctuation-only lines excluded), about 100% of them inside a single declaration: nsZenGlanceManager (16-2161). The bar is 500 significant lines; this is 482 over it, 1.96× 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: sessionstore/ZenWindowSync.sys.mjs src/zen/sessionstore/ZenWindowSync.sys.mjs— FileTooLong — 929 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: nsZenWindowSync (85-1798). The bar is 500 significant lines; this is 429 over it, 1.86× 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: tabs/ZenPinnedTabManager.mjs src/zen/tabs/ZenPinnedTabManager.mjs— FileTooLong — 798 significant lines (blank, comment-only and punctuation-only lines excluded), about 95% of them inside a single declaration: nsZenPinnedTabManager (66-1191). The bar is 500 significant lines; this is 298 over it, 1.60× 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: welcome/ZenWelcome.mjs src/zen/welcome/ZenWelcome.mjs— FileTooLong — 722 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 222 over it, 1.44× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: sections/ZenLibrarySpacesSection.mjs src/zen/library/sections/ZenLibrarySpacesSection.mjs— FileTooLong — 698 significant lines (blank, comment-only and punctuation-only lines excluded), about 93% of them inside a single declaration: ZenLibrarySpacesSection (74-1153). The bar is 500 significant lines; this is 198 over it, 1.40× 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: compact-mode/ZenCompactMode.mjs src/zen/compact-mode/ZenCompactMode.mjs— FileTooLong — 695 significant lines (blank, comment-only and punctuation-only lines excluded), about 99% of them inside a single declaration: lazy (7-1067). The bar is 500 significant lines; this is 195 over it, 1.39× 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: library/ZenLibrary.mjs src/zen/library/ZenLibrary.mjs— FileTooLong — 671 significant lines (blank, comment-only and punctuation-only lines excluded), about 95% of them inside a single declaration: ZenLibrary (50-1198). The bar is 500 significant lines; this is 171 over it, 1.34× 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: urlbar/ZenSiteDataPanel.sys.mjs src/zen/urlbar/ZenSiteDataPanel.sys.mjs— FileTooLong — 628 significant lines (blank, comment-only and punctuation-only lines excluded), about 99% of them inside a single declaration: nsZenSiteDataPanel (19-983). The bar is 500 significant lines; this is 128 over it, 1.26× 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: sf/generate-icons.swift src/browser/themes/shared/zen-icons/sf/generate-icons.swift— FileTooLong — 600 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 100 over it, 1.20× 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: sync/ZenSpacesSyncApplier.sys.mjs src/zen/sync/ZenSpacesSyncApplier.sys.mjs— FileTooLong — 597 significant lines (blank, comment-only and punctuation-only lines excluded), about 95% of them inside a single declaration: nsZenSpacesSyncApplier (45-964). The bar is 500 significant lines; this is 97 over it, 1.19× 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: share/ZenShareManager.mjs src/zen/share/ZenShareManager.mjs— FileTooLong — 596 significant lines (blank, comment-only and punctuation-only lines excluded), about 98% of them inside a single declaration: nsZenShareManager (28-870). The bar is 500 significant lines; this is 96 over it, 1.19× 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: REDACTED REDACTED— FileTooLong — 543 significant lines (blank, comment-only and punctuation-only lines excluded), about 91% of them inside a single declaration: nsZenSessionManager (83-1075). The bar is 500 significant lines; this is 43 over it, 1.09× 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: sections/ZenLibraryDownloadsSection.mjs src/zen/library/sections/ZenLibraryDownloadsSection.mjs— FileTooLong — 513 significant lines (blank, comment-only and punctuation-only lines excluded), about 92% of them inside a single declaration: ZenLibraryDownloadsSection (51-813). The bar is 500 significant lines; this is 13 over it, 1.03× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
FileTooLong: sync/ZenSpacesSyncModel.sys.mjs src/zen/sync/ZenSpacesSyncModel.sys.mjs— FileTooLong — 505 significant lines (blank, comment-only and punctuation-only lines excluded; the length bar is tripled for a single-responsibility module of 4 or fewer top-level units), about 82% of them inside a single declaration: nsZenSpacesSyncModel (145-878). The bar is 500 significant lines; this is 5 over it, 1.01× 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: sections/ZenLibraryHistorySection.mjs src/zen/library/sections/ZenLibraryHistorySection.mjs— FileTooLong — 502 significant lines (blank, comment-only and punctuation-only lines excluded), about 84% of them inside a single declaration: ZenLibraryHistorySection (115-783). The bar is 500 significant lines; this is 2 over it, 1.00× 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.
TooManyMethods: nsZenWorkspaces src/zen/spaces/ZenSpaceManager.mjs:45— TooManyMethods — 123 methods. The bar is 30 methods; this is 93 over it, 4.10× 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: nsZenGlanceManager src/zen/glance/ZenGlanceManager.mjs:16— TooManyMethods — 86 methods. The bar is 30 methods; this is 56 over it, 2.87× 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: nsZenThemePicker REDACTED:156— TooManyMethods — 85 methods. The bar is 30 methods; this is 55 over it, 2.83× 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: nsZenViewSplitter src/zen/split-view/ZenViewSplitter.mjs:73— TooManyMethods — 75 methods. The bar is 30 methods; this is 45 over it, 2.50× 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: nsZenBoostEditor src/zen/boosts/ZenBoostsEditor.mjs:9— TooManyMethods — 67 methods. The bar is 30 methods; this is 37 over it, 2.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: nsZenWindowSync src/zen/sessionstore/ZenWindowSync.sys.mjs:85— TooManyMethods — 66 methods. The bar is 30 methods; this is 36 over it, 2.20× 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: nsZenFolders src/zen/folders/ZenFolders.mjs:38— TooManyMethods — 62 methods. The bar is 30 methods; this is 32 over it, 2.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: ZenLibrarySpacesSection src/zen/library/sections/ZenLibrarySpacesSection.mjs:74— TooManyMethods — 58 methods. The bar is 30 methods; this is 28 over it, 1.93× 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: ZenLibraryDownloadsSection src/zen/library/sections/ZenLibraryDownloadsSection.mjs:51— TooManyMethods — 52 methods. The bar is 30 methods; this is 22 over it, 1.73× 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: ZenDragAndDrop src/zen/drag-and-drop/ZenDragAndDrop.js:63— TooManyMethods — 50 methods. The bar is 30 methods; this is 20 over it, 1.67× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
TooManyMethods: ZenLibrary src/zen/library/ZenLibrary.mjs:50— TooManyMethods — 45 methods. The bar is 30 methods; this is 15 over it, 1.50× 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: nsZenBoostsManager src/zen/boosts/ZenBoostsManager.sys.mjs:15— TooManyMethods — 44 methods. The bar is 30 methods; this is 14 over it, 1.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: ZenLibraryDownloadStack src/zen/library/ZenLibraryWidget.sys.mjs:39— TooManyMethods — 36 methods. The bar is 30 methods; this is 6 over it, 1.20× 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: nsZenUIManager src/zen/common/modules/ZenUIManager.mjs:26— TooManyMethods — 34 methods. The bar is 30 methods; this is 4 over it, 1.13× 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: nsZenShareManager src/zen/share/ZenShareManager.mjs:28— TooManyMethods — 34 methods. The bar is 30 methods; this is 4 over it, 1.13× 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: nsZenSpaceRoutingManager REDACTED:14— TooManyMethods — 34 methods. The bar is 30 methods; this is 4 over it, 1.13× 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: ZenMediaCard src/zen/media/ZenMediaController.sys.mjs:23— TooManyMethods — 33 methods. The bar is 30 methods; this is 3 over it, 1.10× 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: nsZenSpacesSyncModel src/zen/sync/ZenSpacesSyncModel.sys.mjs:145— 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: nsZenPinnedTabManager src/zen/tabs/ZenPinnedTabManager.mjs:66— 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: ZenLibraryHistorySection src/zen/library/sections/ZenLibraryHistorySection.mjs:115— 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.
TooManyMethods: nsZenSiteDataPanel src/zen/urlbar/ZenSiteDataPanel.sys.mjs:19— 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.
Hotspot: src/zen/spaces/ZenSpaceManager.mjs src/zen/spaces/ZenSpaceManager.mjs:2365— src/zen/spaces/ZenSpaceManager.mjs changed 49 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 43 in nsZenWorkspaces.#animateTabs at line 2365. 13 of those changes were fix/bug commits, and the other 36 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/spaces/ZenSpaceManager.mjs`: 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:1913— REDACTED changed 28 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 44 in nsZenThemePicker.onWorkspaceChange at line 1913. 8 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- REDACTED`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: src/zen/drag-and-drop/ZenDragAndDrop.js src/zen/drag-and-drop/ZenDragAndDrop.js:1813— src/zen/drag-and-drop/ZenDragAndDrop.js changed 19 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 57 in ZenDragAndDrop.#animateVerticalPinnedGridDragOver at line 1813. 6 of those changes were fix/bug commits, and the other 13 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/drag-and-drop/ZenDragAndDrop.js`: 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: src/zen/folders/ZenFolders.mjs src/zen/folders/ZenFolders.mjs:2113— src/zen/folders/ZenFolders.mjs changed 19 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 39 in nsZenFolders.animateSelect at line 2113. 6 of those changes were fix/bug commits, and the other 13 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/folders/ZenFolders.mjs`: 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: src/zen/sync/ZenSpacesSyncApplier.sys.mjs src/zen/sync/ZenSpacesSyncApplier.sys.mjs:425— src/zen/sync/ZenSpacesSyncApplier.sys.mjs changed 20 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 31 in nsZenSpacesSyncApplier.#applyFolders at line 425. 9 of those changes were fix/bug commits, and the other 11 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/sync/ZenSpacesSyncApplier.sys.mjs`: 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: src/zen/common/modules/ZenUIManager.mjs src/zen/common/modules/ZenUIManager.mjs:121— src/zen/common/modules/ZenUIManager.mjs changed 24 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 20 in nsZenUIManager.elementAnimate at line 121. 10 of those changes were fix/bug commits, and the other 14 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/common/modules/ZenUIManager.mjs`: 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: src/zen/tabs/ZenPinnedTabManager.mjs src/zen/tabs/ZenPinnedTabManager.mjs:315— src/zen/tabs/ZenPinnedTabManager.mjs changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 35 in nsZenPinnedTabManager.onCloseTabShortcut at line 315. 5 of those changes were fix/bug commits, and the other 7 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/tabs/ZenPinnedTabManager.mjs`: 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: src/zen/sessionstore/ZenWindowSync.sys.mjs src/zen/sessionstore/ZenWindowSync.sys.mjs:656— src/zen/sessionstore/ZenWindowSync.sys.mjs changed 20 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in nsZenWindowSync.#moveItemToMatchOriginal at line 656. 7 of those changes were fix/bug commits, and the other 13 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/sessionstore/ZenWindowSync.sys.mjs`: 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: src/zen/split-view/ZenViewSplitter.mjs src/zen/split-view/ZenViewSplitter.mjs:325— src/zen/split-view/ZenViewSplitter.mjs changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 29 in nsZenViewSplitter.onBrowserDragOverToSplit at line 325. 8 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/split-view/ZenViewSplitter.mjs`: 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: src/zen/library/sections/ZenLibrarySpacesSection.mjs src/zen/library/sections/ZenLibrarySpacesSection.mjs:417— src/zen/library/sections/ZenLibrarySpacesSection.mjs changed 17 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in ZenLibrarySpacesSection.#fillStrips at line 417. 10 of those changes were fix/bug commits, so the churn is repair rather than feature work. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/library/sections/ZenLibrarySpacesSection.mjs`: 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: src/zen/spaces/ZenSpace.mjs src/zen/spaces/ZenSpace.mjs:142— src/zen/spaces/ZenSpace.mjs changed 11 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 21 in nsZenWorkspace.connectedCallback at line 142. 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/spaces/ZenSpace.mjs`: 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: src/zen/sync/ZenSpacesSyncModel.sys.mjs src/zen/sync/ZenSpacesSyncModel.sys.mjs:315— src/zen/sync/ZenSpacesSyncModel.sys.mjs changed 12 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 17 in nsZenSpacesSyncModel.#tabIdentity at line 315. 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/sync/ZenSpacesSyncModel.sys.mjs`: 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: src/zen/migration/ZenMigrationUtils.sys.mjs src/zen/migration/ZenMigrationUtils.sys.mjs:296— src/zen/migration/ZenMigrationUtils.sys.mjs changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 29 in ZenMigrationUtilsClass.parseArcSidebar at line 296. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/migration/ZenMigrationUtils.sys.mjs`: 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: src/zen/live-folders/providers/GithubLiveFolder.sys.mjs src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:24— src/zen/live-folders/providers/GithubLiveFolder.sys.mjs changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in nsGithubLiveFolderProvider.fetchItems at line 24. 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/live-folders/providers/GithubLiveFolder.sys.mjs`: 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: src/zen/boosts/actors/ZenBoostsChild.sys.mjs src/zen/boosts/actors/ZenBoostsChild.sys.mjs:127— src/zen/boosts/actors/ZenBoostsChild.sys.mjs changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 19 in ZenBoostsChild.receiveMessage at line 127. 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/boosts/actors/ZenBoostsChild.sys.mjs`: 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: src/zen/urlbar/ZenUBActionsProvider.sys.mjs src/zen/urlbar/ZenUBActionsProvider.sys.mjs:352— src/zen/urlbar/ZenUBActionsProvider.sys.mjs changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in ZenUrlbarProviderGlobalActions.startQuery at line 352. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/urlbar/ZenUBActionsProvider.sys.mjs`: 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: src/zen/boosts/actors/ZenBoostsParent.sys.mjs src/zen/boosts/actors/ZenBoostsParent.sys.mjs:108— src/zen/boosts/actors/ZenBoostsParent.sys.mjs changed 3 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 22 in ZenBoostsParent.receiveMessage at line 108. 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/boosts/actors/ZenBoostsParent.sys.mjs`: 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: src/zen/library/ZenLibraryDragAndDrop.mjs src/zen/library/ZenLibraryDragAndDrop.mjs:134— src/zen/library/ZenLibraryDragAndDrop.mjs changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in ZenLibraryDragAndDrop.handle_drop at line 134. 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-08-15..2026-11-13, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-08-15 12:57:03 +01:00' --until='2026-11-13 12:57:03 +01:00' --full-history --no-merges -- src/zen/library/ZenLibraryDragAndDrop.mjs`: 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.
ClassTooLong: nsZenWorkspaces src/zen/spaces/ZenSpaceManager.mjs:45— ClassTooLong — 2334 significant lines (blank, comment-only and punctuation-only lines excluded), 123 methods. The bar is 400 significant lines; this is 1934 over it, 5.84× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenViewSplitter src/zen/split-view/ZenViewSplitter.mjs:73— ClassTooLong — 1598 significant lines (blank, comment-only and punctuation-only lines excluded), 75 methods. The bar is 400 significant lines; this is 1198 over it, 4.00× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenThemePicker REDACTED:156— ClassTooLong — 1572 significant lines (blank, comment-only and punctuation-only lines excluded), 85 methods. The bar is 400 significant lines; this is 1172 over it, 3.93× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenFolders src/zen/folders/ZenFolders.mjs:38— ClassTooLong — 1482 significant lines (blank, comment-only and punctuation-only lines excluded), 62 methods. The bar is 400 significant lines; this is 1082 over it, 3.71× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenBoostEditor src/zen/boosts/ZenBoostsEditor.mjs:9— ClassTooLong — 1073 significant lines (blank, comment-only and punctuation-only lines excluded), 67 methods. The bar is 400 significant lines; this is 673 over it, 2.68× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenGlanceManager src/zen/glance/ZenGlanceManager.mjs:16— ClassTooLong — 978 significant lines (blank, comment-only and punctuation-only lines excluded), 86 methods. The bar is 400 significant lines; this is 578 over it, 2.45× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenWindowSync src/zen/sessionstore/ZenWindowSync.sys.mjs:85— ClassTooLong — 868 significant lines (blank, comment-only and punctuation-only lines excluded), 66 methods. The bar is 400 significant lines; this is 468 over it, 2.17× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenPinnedTabManager src/zen/tabs/ZenPinnedTabManager.mjs:66— ClassTooLong — 762 significant lines (blank, comment-only and punctuation-only lines excluded), 32 methods. The bar is 400 significant lines; this is 362 over it, 1.91× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenSiteDataPanel src/zen/urlbar/ZenSiteDataPanel.sys.mjs:19— ClassTooLong — 620 significant lines (blank, comment-only and punctuation-only lines excluded), 31 methods. The bar is 400 significant lines; this is 220 over it, 1.55× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenShareManager src/zen/share/ZenShareManager.mjs:28— ClassTooLong — 582 significant lines (blank, comment-only and punctuation-only lines excluded), 34 methods. The bar is 400 significant lines; this is 182 over it, 1.46× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenSpacesSyncApplier src/zen/sync/ZenSpacesSyncApplier.sys.mjs:45— ClassTooLong — 567 significant lines (blank, comment-only and punctuation-only lines excluded), 23 methods. The bar is 400 significant lines; this is 167 over it, 1.42× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenSessionManager REDACTED:83— ClassTooLong — 495 significant lines (blank, comment-only and punctuation-only lines excluded), 28 methods. The bar is 400 significant lines; this is 95 over it, 1.24× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenWorkspace src/zen/spaces/ZenSpace.mjs:52— ClassTooLong — 426 significant lines (blank, comment-only and punctuation-only lines excluded), 24 methods. The bar is 400 significant lines; this is 26 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.
ClassTooLong: ZenLibraryDownloadStack src/zen/library/ZenLibraryWidget.sys.mjs:39— ClassTooLong — 421 significant lines (blank, comment-only and punctuation-only lines excluded), 36 methods. The bar is 400 significant lines; this is 21 over it, 1.05× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: SelectorComponent src/zen/boosts/ZenSelectorComponent.sys.mjs:11— ClassTooLong — 418 significant lines (blank, comment-only and punctuation-only lines excluded), 25 methods. The bar is 400 significant lines; this is 18 over it, 1.05× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: nsZenSpacesSyncModel src/zen/sync/ZenSpacesSyncModel.sys.mjs:145— ClassTooLong — 413 significant lines (blank, comment-only and punctuation-only lines excluded), 32 methods. The bar is 400 significant lines; this is 13 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.
ClassTooLong: nsZenLiveFoldersManager src/zen/live-folders/ZenLiveFoldersManager.sys.mjs:33— ClassTooLong — 402 significant lines (blank, comment-only and punctuation-only lines excluded), 25 methods. The bar is 400 significant lines; this is 2 over it, 1.01× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
MethodTooLong: ZenDragAndDrop.#animateVerticalPinnedGridDragOver src/zen/drag-and-drop/ZenDragAndDrop.js:1813— MethodTooLong — #animateVerticalPinnedGridDragOver runs 205 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 105 over it, 2.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.
MethodTooLong: ZenDragAndDrop._animateTabMove src/zen/drag-and-drop/ZenDragAndDrop.js:284— MethodTooLong — _animateTabMove runs 195 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 95 over it, 1.95× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenThemePicker.onWorkspaceChange REDACTED:1913— MethodTooLong — onWorkspaceChange runs 191 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 91 over it, 1.91× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenFolders.animateSelect src/zen/folders/ZenFolders.mjs:2113— MethodTooLong — animateSelect runs 139 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 39 over it, 1.39× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: SelectorComponent.getSelectionPath src/zen/boosts/ZenSelectorComponent.sys.mjs:598— MethodTooLong — getSelectionPath runs 132 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 32 over it, 1.32× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: ZenDragAndDrop.#applyDragoverIndicator src/zen/drag-and-drop/ZenDragAndDrop.js:1598— MethodTooLong — #applyDragoverIndicator runs 129 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 29 over it, 1.29× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenPinnedTabManager.moveToAnotherTabContainerIfNecessary src/zen/tabs/ZenPinnedTabManager.mjs:756— MethodTooLong — moveToAnotherTabContainerIfNecessary runs 125 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 25 over it, 1.25× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenViewSplitter.moveTabToSplitView src/zen/split-view/ZenViewSplitter.mjs:2154— MethodTooLong — moveTabToSplitView 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.
MethodTooLong: ZenDragAndDrop.handle_drop_transition src/zen/drag-and-drop/ZenDragAndDrop.js:1319— MethodTooLong — handle_drop_transition runs 113 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 13 over it, 1.13× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenWorkspace.connectedCallback src/zen/spaces/ZenSpace.mjs:142— MethodTooLong — connectedCallback runs 113 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 13 over it, 1.13× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenWorkspaces.selectStartPage src/zen/spaces/ZenSpaceManager.mjs:980— MethodTooLong — selectStartPage runs 113 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 13 over it, 1.13× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenThemePicker.onThemePickerClick REDACTED:1125— MethodTooLong — onThemePickerClick runs 103 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 3 over it, 1.03× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenFolders.#initContextMenu src/zen/folders/ZenFolders.mjs:68— MethodTooLong — #initContextMenu runs 101 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 1 over it, 1.01× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: nsZenShareManager.#showImportOverlay src/zen/share/ZenShareManager.mjs:486— MethodTooLong — #showImportOverlay runs 101 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 1 over it, 1.01× 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.
AC6 · Visual & motion safety· Focus outline removed in CSS without a · ×13
Focus outline removed in CSS without a :focus replacement src/zen/tabs/zen-tabs/vertical-tabs.css:972— `.tab-reset-button` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/tabs/zen-tabs/vertical-tabs.css:1453— `#tab-label-input` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/spaces/create-workspace-form.css:116— `zen-workspace-creation .zen-workspace-creation form .zen-workspace-creation-name-wrapper .zen-workspace-creation-name` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/library/zen-library.css:633— `.zen-library-search-box input` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/library/zen-library.css:732— `.zen-library-routing-reference` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/library/zen-library.css:1484— `.zen-library-space-name-input` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/folders/zen-folders.css:239— `#zen-folder-tabs-popup #zen-folder-tabs-list-search` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/common/styles/zen-omnibox.css:71— `.urlbar-background` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/common/styles/zen-omnibox.css:83— `#urlbar[focused="true"]:not([suppress-focus-border]) > .urlbar-background` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/common/styles/zen-omnibox.css:115— `#identity-icon-box` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/boosts/zen-boosts-share.css:141— `.zbs-info-text input:focus` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/boosts/zen-boosts-share.css:135— `.zbs-info-text input` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Focus outline removed in CSS without a :focus replacement src/zen/boosts/zen-boosts.css:232— `#zen-boost-head-wrapper #zen-boost-name` sets the outline to none/0 and no visible :focus / :focus-visible style for that element replaces it in this stylesheet, so a keyboard user cannot see where focus is. Draw a focus ring (outline, box-shadow or border) under :focus-visible.
Fake-async — async method never awaits src/zen/boosts/ZenBoostsEditor.mjs:598— `onZapButtonPressed` 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 src/zen/boosts/ZenBoostsEditor.mjs:604— `onFocusButtonPressed` 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 src/zen/boosts/ZenBoostsEditor.mjs:611— `onPickerButtonPressed` 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 src/zen/boosts/ZenSelectorComponent.sys.mjs:73— `initialize` 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 src/zen/boosts/ZenZapOverlayChild.sys.mjs:58— `initialize` 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 src/zen/common/emojis/ZenEmojiPicker.mjs:176— `#onPopupShowing` 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 REDACTED:825— `addCustomColor` 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 src/zen/spaces/ZenSpaceManager.mjs:1210— `#clearAnyZombieTabs` 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 src/zen/spaces/ZenSpaceManager.mjs:1618— `reorderWorkspace` 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 src/zen/spaces/ZenSpaceManager.mjs:2795— `#fixCtrlTabBehavior` 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 src/zen/spaces/ZenSpaceManager.mjs:3225— `contextChangeContainerTab` 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 src/zen/spaces/ZenSpaceManager.mjs:3239— `closeAllUnpinnedTabs` 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 src/zen/split-view/ZenViewSplitter.mjs:172— `handleTabBrowserDiscarded` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work.
Low cohesion: nsZenFolders (LCOM4 10) src/zen/folders/ZenFolders.mjs:38— nsZenFolders's methods fall into 10 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 10 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.
Low cohesion: nsZenThemePicker (LCOM4 8) REDACTED:156— nsZenThemePicker's methods fall into 8 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 8 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.
Low cohesion: nsZenUIManager (LCOM4 6) src/zen/common/modules/ZenUIManager.mjs:26— nsZenUIManager's methods fall into 6 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 6 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.
Low cohesion: nsZenUrlbarController (LCOM4 6) src/zen/urlbar/ZenUrlbarController.mjs:12— nsZenUrlbarController's methods fall into 6 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 6 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.
Low cohesion: nsZenUIMigration (LCOM4 5) src/zen/common/sys/ZenUIMigration.sys.mjs:16— nsZenUIMigration's methods fall into 5 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 5 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.
Low cohesion: nsZenBoostsManager (LCOM4 4) src/zen/boosts/ZenBoostsManager.sys.mjs:15— nsZenBoostsManager's methods fall into 4 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 4 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.
Low cohesion: ZenMigrationUtilsClass (LCOM4 4) src/zen/migration/ZenMigrationUtils.sys.mjs:261— ZenMigrationUtilsClass's methods fall into 4 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 4 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.
Low cohesion: nsZenSpaceRoutingManager (LCOM4 4) REDACTED:14— nsZenSpaceRoutingManager's methods fall into 4 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 4 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.
Empty <h3> heading src/zen/library/sections/ZenLibraryHistorySection.mjs:742— An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
Empty <h3> heading src/zen/library/sections/ZenLibraryMediaSection.mjs:474— An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
Empty <h3> heading src/zen/library/sections/ZenLibrarySearchSection.mjs:242— An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
Empty <h3> heading src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:373— An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
Empty <h3> heading src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:409— An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
Empty <h3> heading src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:565— An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
Duplicated block (17 lines × 2 locations) src/zen/library/ZenLibraryWidget.sys.mjs:294— src/zen/library/ZenLibraryWidget.sys.mjs:294 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:382 — 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 (17 lines × 2 locations) src/zen/library/ZenLibraryWidget.sys.mjs:444— src/zen/library/ZenLibraryWidget.sys.mjs:444 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:139 — 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 (17 lines × 2 locations) src/zen/split-view/ZenViewSplitter.mjs:468— src/zen/split-view/ZenViewSplitter.mjs:468 · src/zen/split-view/ZenViewSplitter.mjs:486 — 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 (17 lines × 2 locations) src/zen/split-view/ZenViewSplitter.mjs:579— src/zen/split-view/ZenViewSplitter.mjs:579 · src/zen/split-view/ZenViewSplitter.mjs:596 — 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 (17 lines × 2 locations) src/zen/tabs/ZenPinnedTabManager.mjs:1139— src/zen/tabs/ZenPinnedTabManager.mjs:1139 · src/zen/tabs/ZenPinnedTabManager.mjs:1163 — 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.
Swallowed exception (caught, then discarded) src/zen/urlbar/ZenUBGlobalActions.sys.mjs:171— `catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, or keep only the failure you expect and rethrow the rest (`catch (e) { if (!(e instanceof SyntaxError)) throw e; … }`, or test `e.name`), because a JavaScript catch takes every exception, programming errors included.
Swallowed exception (caught, then discarded) src/zen/space-routing/ZenSpaceRoutingNavigation.sys.mjs:41— `catch (e)` 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, or keep only the failure you expect and rethrow the rest (`catch (e) { if (!(e instanceof SyntaxError)) throw e; … }`, or test `e.name`), because a JavaScript catch takes every exception, programming errors included.
Swallowed exception (caught, then discarded) src/zen/space-routing/ZenSpaceRoutingNavigation.sys.mjs:123— `catch (e)` 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, or keep only the failure you expect and rethrow the rest (`catch (e) { if (!(e instanceof SyntaxError)) throw e; … }`, or test `e.name`), because a JavaScript catch takes every exception, programming errors included.
Swallowed exception (caught, then discarded) src/zen/drag-and-drop/ZenDragAndDrop.js:1342— `catch (e)` 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, or keep only the failure you expect and rethrow the rest (`catch (e) { if (!(e instanceof SyntaxError)) throw e; … }`, or test `e.name`), because a JavaScript catch takes every exception, programming errors included.
Swallowed exception (caught, then discarded) src/browser/themes/shared/zen-icons/check_unused_icons.py:39— `except BaseException` 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.
Duplicated block (16 lines × 2 locations) src/zen/folders/ZenFolders.mjs:1970— src/zen/folders/ZenFolders.mjs:1970 · src/zen/folders/ZenFolders.mjs:2030 — 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 (16 lines × 2 locations) src/zen/library/sections/ZenLibraryBoostsSection.mjs:206— src/zen/library/sections/ZenLibraryBoostsSection.mjs:206 · src/zen/library/sections/ZenLibraryHistorySection.mjs:200 — 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 (16 lines × 2 locations) src/zen/library/sections/ZenLibrarySpacesSection.mjs:160— src/zen/library/sections/ZenLibrarySpacesSection.mjs:160 · src/zen/library/sections/ZenLibrarySpacesSection.mjs:177 — 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 (16 lines × 2 locations) src/zen/split-view/ZenViewSplitter.mjs:501— src/zen/split-view/ZenViewSplitter.mjs:501 · src/zen/split-view/ZenViewSplitter.mjs:610 — 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 (13 lines × 2 locations) src/zen/boosts/ZenBoostsEditor.mjs:508— src/zen/boosts/ZenBoostsEditor.mjs:508 · src/zen/boosts/ZenBoostsEditor.mjs:559 — 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 (13 lines × 2 locations) src/zen/boosts/zen-boost-receive.js:7— src/zen/boosts/zen-boost-receive.js:7 · src/zen/boosts/zen-boost-share.js:7 — 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 (13 lines × 2 locations) src/zen/downloads/ZenDownloadAnimation.mjs:212— src/zen/downloads/ZenDownloadAnimation.mjs:212 · src/zen/glance/ZenGlanceManager.mjs:960 — 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 (13 lines × 2 locations) src/zen/sessionstore/ZenWindowSync.sys.mjs:1493— src/zen/sessionstore/ZenWindowSync.sys.mjs:1493 · src/zen/sessionstore/ZenWindowSync.sys.mjs:1507 — 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 locations) src/zen/boosts/ZenSelectorComponent.sys.mjs:693— src/zen/boosts/ZenSelectorComponent.sys.mjs:693 · src/zen/boosts/ZenSelectorComponent.sys.mjs:707 — 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 (10 lines × 2 locations) src/zen/boosts/actors/ZenBoostsChild.sys.mjs:383— src/zen/boosts/actors/ZenBoostsChild.sys.mjs:383 · src/zen/boosts/actors/ZenBoostsChild.sys.mjs:421 — 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 (10 lines × 2 locations) src/zen/library/sections/ZenLibraryHistorySection.mjs:602— src/zen/library/sections/ZenLibraryHistorySection.mjs:602 · src/zen/library/sections/ZenLibraryHistorySection.mjs:616 — 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 locations) REDACTED:1231— REDACTED:1231 · REDACTED:1356 — 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· Async function without AbortSignal · ×4
Async function without AbortSignal: getIconData src/zen/welcome/ZenWelcome.mjs:113— `getIconData` 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: downloadUrlToFile src/zen/mods/ZenMods.mjs:326— `downloadUrlToFile` 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: requestMod src/zen/mods/ZenMods.mjs:734— `requestMod` 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: getMetadata src/zen/live-folders/providers/RssLiveFolder.sys.mjs:186— `getMetadata` 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 })`.
Change coupling: ZenSpaceIcons.mjs ↔ ZenSpaceManager.mjs src/zen/spaces/ZenSpaceIcons.mjs:1— `src/zen/spaces/ZenSpaceIcons.mjs` and `src/zen/spaces/ZenSpaceManager.mjs` change together 73% of the time (11 of the 15 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 `7dfcd34f` gh-15522: Fixed toggling folder animations really fast freezing (gh-1…; `9dbd4cdd` chore: [part 2] Continue on motion to native animations migration, p=… (at that commit the files were still `src/zen/workspaces/ZenWorkspaceIcons.mjs` and `src/zen/workspaces/ZenWorkspaces.mjs`); `e3409236` feat: Increased the width and height of toolbar buttons, b=no-bug, c=… (at that commit the files were still `src/zen/workspaces/ZenWorkspaceIcons.mjs` and `src/zen/workspaces/ZenWorkspaces.mjs`) — run `git show` on any of them.
Change coupling: ZenSpaceBookmarksStorage.js ↔ ZenSpaceManager.mjs src/zen/spaces/ZenSpaceBookmarksStorage.js:1— `src/zen/spaces/ZenSpaceBookmarksStorage.js` and `src/zen/spaces/ZenSpaceManager.mjs` 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 `e80c16a7` gh-12740: remove deleted workspace tabs from switch-to-tab (gh-12794); `768bb2b5` feat: Improved UI for dialog buttons and fixed workspace specific boo… (at that commit the files were still `src/zen/workspaces/ZenWorkspaceBookmarksStorage.js` and `src/zen/workspaces/ZenWorkspaces.mjs`); `cf6a3467` no-bug - Improved initial startup performance and loading speeds, c=c… (at that commit the files were still `src/zen/workspaces/ZenWorkspacesStorage.mjs` and `src/zen/workspaces/ZenWorkspaces.mjs`) — run `git show` on any of them.
Change coupling: ZenActorsManager.sys.mjs ↔ ZenGlanceChild.sys.mjs src/zen/common/sys/ZenActorsManager.sys.mjs:1— `src/zen/common/sys/ZenActorsManager.sys.mjs` and `src/zen/glance/actors/ZenGlanceChild.sys.mjs` 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 — 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 `64d73ab3` gh-14956: Check if the closing tab exists on the tab list before swit…; `833caf2f` fix: Fixed crash on macos when quiting and glance opening a new windo…; `8d12ade0` fix: prevent new window when shift-clicking links in split view glanc… — run `git show` on any of them.
Empty <h2> heading src/zen/library/sections/ZenLibrarySearchSection.mjs:228— An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
Empty <h2> heading src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:349— An empty heading appears in the document outline announced with no text. Give the heading text, or remove it if it's decorative.
ffprefs::expand_pref_values (cognitive 26) tools/ffprefs/src/main.rs:338— ffprefs::expand_pref_values has cognitive complexity 26 (threshold 15). Drivers by points: if/else 7 (20 pts), loops 3 (6 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.
ffprefs::get_prefs_files_recursively (cognitive 17) tools/ffprefs/src/main.rs:139— ffprefs::get_prefs_files_recursively has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (14 pts), loops 1 (2 pts), boolean chains 1 (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.
R10 · Code Duplication· Duplicated block with local edits (15 matched lines × 2 locations) · ×2
Duplicated block with local edits (15 matched lines × 2 locations) src/zen/library/ZenLibraryMediaPreview.mjs:500— src/zen/library/ZenLibraryMediaPreview.mjs:500 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:436 — the two spans are one implementation copied and then locally edited — 60 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 (15 matched lines × 2 locations) src/zen/library/sections/ZenLibraryDownloadsSection.mjs:558— src/zen/library/sections/ZenLibraryDownloadsSection.mjs:558 · src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:154 — the two spans are one implementation copied and then locally edited — 82 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 (14 lines × 2 locations) src/zen/library/ZenLibraryWidget.sys.mjs:343— src/zen/library/ZenLibraryWidget.sys.mjs:343 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:541 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another.
Duplicated block (14 lines × 2 locations) REDACTED:1154— REDACTED:1154 · REDACTED:1306 — 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.
R10 · Code Duplication· Duplicated block with local edits (13 matched lines × 2 locations) · ×2
Duplicated block with local edits (13 matched lines × 2 locations) src/zen/common/modules/ZenCommonUtils.mjs:170— src/zen/common/modules/ZenCommonUtils.mjs:170 · src/zen/urlbar/ZenSiteDataPanel.sys.mjs:754 — the two spans are one implementation copied and then locally edited — 55 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 (13 matched lines × 2 locations) src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:42— src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:42 · src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:115 — the two spans are one implementation copied and then locally edited — 63 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 (12 lines × 2 locations) src/browser/components/preferences/zen-settings.js:520— src/browser/components/preferences/zen-settings.js:520 · src/browser/components/preferences/zen-settings.js:615 — all 2 copies are in the same file, and the CITED SPAN is a run of DECLARATIONS inside a construct — the members of a type, or the entries of an object or array literal — with no statement anywhere in it. Do not read this as an extract-a-helper row: nothing here executes, so there is no call site, and a call expression cannot stand where a member declaration or a literal's entry was. What repeats is a SHAPE, and which shape decides the move. Where the copies declare the same members, the repetition is a missing common ancestor: give it a base type, an interface both extend, a generic instantiated twice, or — where the copies are a literal's entries rather than a type's members — one shared constant each site spreads or refers to, so the set is written once. Where they declare DIFFERENT members and only the form is shared — a decorator and its options, an annotation, a registration table's keys — the form is prescribed by a framework or a schema rather than copied, and the only collapse available is to generate the declarations from that schema; where you do not own the generator, this is the cost of the framework and there is nothing to extract. Check which of the two it is before acting: these copies still drift apart the first time only one of them is edited, which is why the repetition is reported, but the sentence to act on is not the same in both cases.
Duplicated block (12 lines × 2 locations) src/zen/boosts/ZenZapDissolve.sys.mjs:562— src/zen/boosts/ZenZapDissolve.sys.mjs:562 · src/zen/boosts/ZenZapDissolve.sys.mjs:594 — 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 (11 lines × 2 locations) src/zen/boosts/ZenBoostsEditor.mjs:980— src/zen/boosts/ZenBoostsEditor.mjs:980 · src/zen/boosts/ZenBoostsEditor.mjs:1063 — 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 locations) src/zen/folders/ZenFolders.mjs:1741— src/zen/folders/ZenFolders.mjs:1741 · src/zen/folders/ZenFolders.mjs:1860 — 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 (9 lines × 2 locations) src/zen/boosts/ZenBoostsEditor.mjs:887— src/zen/boosts/ZenBoostsEditor.mjs:887 · src/zen/boosts/ZenBoostsEditor.mjs:1023 — 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 (9 lines × 2 locations) src/zen/boosts/ZenBoostsManager.sys.mjs:347— src/zen/boosts/ZenBoostsManager.sys.mjs:347 · src/zen/boosts/ZenBoostsManager.sys.mjs:369 — 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.
`async` Promise executor src/zen/sessionstore/ZenWindowSync.sys.mjs:1022— The function passed to `new Promise(…)` is `async`. The constructor ignores what its executor returns, so anything this executor throws — every throw inside an `async` function, including after an `await` — rejects a Promise nobody holds instead of the one being constructed: the outer Promise never settles, whoever awaits it hangs, and the error is reported nowhere. If the body needs `await`, it does not need `new Promise` at all: make the enclosing function `async` and `return` the value (or `throw`) directly. If it wraps a callback API, keep the executor synchronous — call the API and `resolve`/`reject` from its callback — and do the awaiting outside it.
`async` Promise executor src/zen/glance/ZenGlanceManager.mjs:607— The function passed to `new Promise(…)` is `async`. The constructor ignores what its executor returns, so anything this executor throws — every throw inside an `async` function, including after an `await` — rejects a Promise nobody holds instead of the one being constructed: the outer Promise never settles, whoever awaits it hangs, and the error is reported nowhere. If the body needs `await`, it does not need `new Promise` at all: make the enclosing function `async` and `return` the value (or `throw`) directly. If it wraps a callback API, keep the executor synchronous — call the API and `resolve`/`reject` from its callback — and do the awaiting outside it.
AC3 · Page structure· Page without a main landmark · ×1
Page without a main landmark src/browser/themes/shared/zen-icons/nucleo/nucleo-copyright-notice.html:5— No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>.
_updateEvent (cyclomatic 82) src/zen/common/modules/ZenVerticalTabsManager.mjs:399— _updateEvent has cyclomatic complexity 82 (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.
#animateVerticalPinnedGridDragOver (cyclomatic 59) src/zen/drag-and-drop/ZenDragAndDrop.js:1813— #animateVerticalPinnedGridDragOver has cyclomatic complexity 59 (threshold 15). Of this number, 46 points are the body's own statements and 13 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
ZenDragAndDrop.#applyDragoverIndicator (cyclomatic 55) src/zen/drag-and-drop/ZenDragAndDrop.js:1598— ZenDragAndDrop.#applyDragoverIndicator has cyclomatic complexity 55 (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.
_animateTabMove (cyclomatic 51) src/zen/drag-and-drop/ZenDragAndDrop.js:284— _animateTabMove has cyclomatic complexity 51 (threshold 15). Of this number, 36 points are the body's own statements and 15 belong to 7 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenPinnedTabManager.moveToAnotherTabContainerIfNecessary (cyclomatic 49) src/zen/tabs/ZenPinnedTabManager.mjs:756— nsZenPinnedTabManager.moveToAnotherTabContainerIfNecessary has cyclomatic complexity 49 (threshold 15). Of this number, 41 points are the body's own statements and 8 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
onWorkspaceChange (cyclomatic 49) REDACTED:1913— onWorkspaceChange has cyclomatic complexity 49 (threshold 15). Most of this is not in the body itself: 3 of the 49 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 1919, 1978). 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.
#animateTabs (cyclomatic 44) src/zen/spaces/ZenSpaceManager.mjs:2365— #animateTabs has cyclomatic complexity 44 (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.
moveTabToSplitView (cyclomatic 43) src/zen/split-view/ZenViewSplitter.mjs:2154— moveTabToSplitView has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
SelectorComponent.getSelectionPath (cyclomatic 42) src/zen/boosts/ZenSelectorComponent.sys.mjs:598— SelectorComponent.getSelectionPath has cyclomatic complexity 42 (threshold 15). Most of this is not in the body itself: 15 of the 42 points are its own statements and the rest belongs to 6 function items inside it that branch (findBestExactSelector, getIdentification, traverse, …). 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.
animateSelect (cyclomatic 42) src/zen/folders/ZenFolders.mjs:2113— animateSelect has cyclomatic complexity 42 (threshold 15). Of this number, 27 points are the body's own statements and 15 belong to 11 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
addMouseActions (cyclomatic 41) src/zen/compact-mode/ZenCompactMode.mjs:729— addMouseActions has cyclomatic complexity 41 (threshold 15). Most of this is not in the body itself: 3 of the 41 points are its own statements and the rest belongs to 13 function items inside it that branch (a function literal at line 799, a function literal at line 863, a function literal at line 756, …). 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.
ZenDragAndDrop.handle_drop_transition (cyclomatic 37) src/zen/drag-and-drop/ZenDragAndDrop.js:1319— ZenDragAndDrop.handle_drop_transition has cyclomatic complexity 37 (threshold 15). Of this number, 36 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
nsZenWorkspaces.selectStartPage (cyclomatic 37) src/zen/spaces/ZenSpaceManager.mjs:980— nsZenWorkspaces.selectStartPage has cyclomatic complexity 37 (threshold 15). Of this number, 28 points are the body's own statements and 9 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.
nsZenPinnedTabManager.onCloseTabShortcut (cyclomatic 35) src/zen/tabs/ZenPinnedTabManager.mjs:315— nsZenPinnedTabManager.onCloseTabShortcut has cyclomatic complexity 35 (threshold 15). Of this number, 32 points are the body's own statements and 3 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.
_buildModsList (cyclomatic 35) src/browser/components/preferences/zen-settings.js:277— _buildModsList has cyclomatic complexity 35 (threshold 15). Of this number, 27 points are the body's own statements and 8 belong to 10 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.
generate-icons.swift.top-level code (cyclomatic 34) src/browser/themes/shared/zen-icons/sf/generate-icons.swift:20— generate-icons.swift.top-level code has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenSpacesSyncApplier.#applyFolders (cyclomatic 31) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:425— nsZenSpacesSyncApplier.#applyFolders has cyclomatic complexity 31 (threshold 15). Of this number, 27 points are the body's own statements and 4 belong to 2 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
parseArcSidebar (cyclomatic 30) src/zen/migration/ZenMigrationUtils.sys.mjs:296— parseArcSidebar has cyclomatic complexity 30 (threshold 15). Of this number, 18 points are the body's own statements and 12 belong to 5 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenViewSplitter.onBrowserDragOverToSplit (cyclomatic 29) src/zen/split-view/ZenViewSplitter.mjs:325— nsZenViewSplitter.onBrowserDragOverToSplit has cyclomatic complexity 29 (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.
#applySpaces (cyclomatic 29) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:313— #applySpaces has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
onStateChange (cyclomatic 28) src/zen/space-routing/ZenSpaceRoutingNavigation.sys.mjs:27— onStateChange has cyclomatic complexity 28 (threshold 15). Of this number, 22 points are the body's own statements and 6 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenWorkspaces.onPinnedTabsResize (cyclomatic 27) src/zen/spaces/ZenSpaceManager.mjs:3044— nsZenWorkspaces.onPinnedTabsResize has cyclomatic complexity 27 (threshold 15). Of this number, 25 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, 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.
#updateTabIdentity (cyclomatic 27) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:608— #updateTabIdentity has cyclomatic complexity 27 (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.
nsZenPinnedTabManager.applyDragoverClass (cyclomatic 26) src/zen/tabs/ZenPinnedTabManager.mjs:1055— nsZenPinnedTabManager.applyDragoverClass has cyclomatic complexity 26 (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.
#childSequence (cyclomatic 26) src/zen/sync/ZenSpacesSyncModel.sys.mjs:358— #childSequence has cyclomatic complexity 26 (threshold 15). Of this number, 25 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.
receiveMessage (cyclomatic 26) src/zen/boosts/actors/ZenBoostsParent.sys.mjs:108— receiveMessage has cyclomatic complexity 26 (threshold 15). Of this number, 25 points are the body's own statements and 1 belongs 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.
nsZenFolders.setFolderIndentation (cyclomatic 25) src/zen/folders/ZenFolders.mjs:1112— nsZenFolders.setFolderIndentation has cyclomatic complexity 25 (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.
nsZenFolders.restoreDataFromSessionStore (cyclomatic 25) src/zen/folders/ZenFolders.mjs:1326— nsZenFolders.restoreDataFromSessionStore has cyclomatic complexity 25 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsRssLiveFolderProvider.fetchItems (cyclomatic 25) src/zen/live-folders/providers/RssLiveFolder.sys.mjs:29— nsRssLiveFolderProvider.fetchItems has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 10 of the 25 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 49, 68). 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.
#updateDropTarget (cyclomatic 25) src/zen/library/ZenLibraryDragAndDrop.mjs:261— #updateDropTarget has cyclomatic complexity 25 (threshold 15). Of this number, 24 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.
ZenDragAndDrop._handle_tabDragOverToSplit (cyclomatic 24) src/zen/drag-and-drop/ZenDragAndDrop.js:913— ZenDragAndDrop._handle_tabDragOverToSplit has cyclomatic complexity 24 (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.
nsZenSiteDataPanel.#setSitePermissions (cyclomatic 24) src/zen/urlbar/ZenSiteDataPanel.sys.mjs:488— nsZenSiteDataPanel.#setSitePermissions has cyclomatic complexity 24 (threshold 15). Of this number, 20 points are the body's own statements and 4 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.
nsZenSessionManager.#runStateMigration (cyclomatic 23) REDACTED:488— nsZenSessionManager.#runStateMigration has cyclomatic complexity 23 (threshold 15). Of this number, 21 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, 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.
nsZenWorkspaces._organizeWorkspaceStripLocations (cyclomatic 23) src/zen/spaces/ZenSpaceManager.mjs:2140— nsZenWorkspaces._organizeWorkspaceStripLocations 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.
nsZenUrlbarController.handleUrlbarClose (cyclomatic 23) src/zen/urlbar/ZenUrlbarController.mjs:193— nsZenUrlbarController.handleUrlbarClose has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 2 of the 23 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 199, 247). 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.
nsZenFolders.animateExpand (cyclomatic 22) src/zen/folders/ZenFolders.mjs:1824— nsZenFolders.animateExpand has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenThemePicker.calculateCompliments (cyclomatic 22) REDACTED:935— nsZenThemePicker.calculateCompliments has cyclomatic complexity 22 (threshold 15). Of this number, 11 points are the body's own statements and 11 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenSpacesSyncApplier.applyBatch (cyclomatic 22) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:73— nsZenSpacesSyncApplier.applyBatch has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenSpacesSyncModel.#projectionContext (cyclomatic 22) src/zen/sync/ZenSpacesSyncModel.sys.mjs:448— nsZenSpacesSyncModel.#projectionContext has cyclomatic complexity 22 (threshold 15). Of this number, 15 points are the body's own statements and 7 belong to 3 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
splitTabs (cyclomatic 22) src/zen/split-view/ZenViewSplitter.mjs:1431— splitTabs has cyclomatic complexity 22 (threshold 15). Most of this is not in the body itself: 1 of the 22 points is its own statement and the rest belongs to 7 function literals inside it that branch (lines 1438, 1441, 1443, …). 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.
arcSpaceTheme (cyclomatic 22) src/zen/migration/ZenMigrationUtils.sys.mjs:168— arcSpaceTheme has cyclomatic complexity 22 (threshold 15). Of this number, 14 points are the body's own statements and 8 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
fetchItems (cyclomatic 22) src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:24— fetchItems has cyclomatic complexity 22 (threshold 15). Of this number, 21 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenLiveFolderProvider.fetch (cyclomatic 21) src/zen/live-folders/ZenLiveFolder.sys.mjs:125— nsZenLiveFolderProvider.fetch has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 5 of the 21 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 180, 214, 172). 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.
nsZenWindowSync.#moveItemToMatchOriginal (cyclomatic 21) src/zen/sessionstore/ZenWindowSync.sys.mjs:656— nsZenWindowSync.#moveItemToMatchOriginal has cyclomatic complexity 21 (threshold 15). Of this number, 11 points are the body's own statements and 10 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.
nsZenWorkspace.connectedCallback (cyclomatic 21) src/zen/spaces/ZenSpace.mjs:142— nsZenWorkspace.connectedCallback has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 9 of the 21 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 235, 212, 266, …). 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.
nsZenTabRenamer.start (cyclomatic 21) src/zen/tabs/ZenTabRenamer.mjs:31— nsZenTabRenamer.start has cyclomatic complexity 21 (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.
#initSidebarResizer (cyclomatic 21) src/zen/common/sys/ZenCustomizableUI.sys.mjs:136— #initSidebarResizer has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 1 of the 21 points is its own statement and the rest belongs to 10 function items inside it that branch (endDrag, applyDrag, a function literal at line 207, …). 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.
nsZenUIManager.elementAnimate (cyclomatic 20) src/zen/common/modules/ZenUIManager.mjs:121— nsZenUIManager.elementAnimate 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.
nsZenViewSplitter.onBrowserDragEndToSplit (cyclomatic 20) src/zen/split-view/ZenViewSplitter.mjs:533— nsZenViewSplitter.onBrowserDragEndToSplit has cyclomatic complexity 20 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
#initContextMenu (cyclomatic 20) src/zen/folders/ZenFolders.mjs:68— #initContextMenu 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 4 function literals inside it that branch (lines 164, 102, 141, …). 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.
#applyOrdering (cyclomatic 20) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:907— #applyOrdering 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.
#onMouseDown (cyclomatic 20) src/zen/window-drag/actors/ZenWindowDragChild.sys.mjs:100— #onMouseDown has cyclomatic complexity 20 (threshold 15). Of this number, 18 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
ZenBoostsChild.receiveMessage (cyclomatic 19) src/zen/boosts/actors/ZenBoostsChild.sys.mjs:127— ZenBoostsChild.receiveMessage has cyclomatic complexity 19 (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.
nsZenLiveFoldersManager.onLiveFolderFetch (cyclomatic 19) src/zen/live-folders/ZenLiveFoldersManager.sys.mjs:432— nsZenLiveFoldersManager.onLiveFolderFetch has cyclomatic complexity 19 (threshold 15). Of this number, 13 points are the body's own statements and 6 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenThemePicker.onThemePickerClick (cyclomatic 19) REDACTED:1125— nsZenThemePicker.onThemePickerClick has cyclomatic complexity 19 (threshold 15). Of this number, 18 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
nsZenWorkspaceIcons.initDragAndDrop (cyclomatic 19) src/zen/spaces/ZenSpaceIcons.mjs:28— nsZenWorkspaceIcons.initDragAndDrop has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 49, 32). 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.
ZenUBActionsProvider.sys.payloadAndSimpleHighlights (cyclomatic 19) src/zen/urlbar/ZenUBActionsProvider.sys.mjs:77— ZenUBActionsProvider.sys.payloadAndSimpleHighlights 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.
nsZenUrlbarController.handleNewTab (cyclomatic 19) src/zen/urlbar/ZenUrlbarController.mjs:84— nsZenUrlbarController.handleNewTab has cyclomatic complexity 19 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
generate-icons.swift.interpret (cyclomatic 19) src/browser/themes/shared/zen-icons/sf/generate-icons.swift:532— generate-icons.swift.interpret has cyclomatic complexity 19 (threshold 15). Of this number, 16 points are the body's own statements and 3 belong to one function item inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
nsZenFolders.animateCollapse (cyclomatic 18) src/zen/folders/ZenFolders.mjs:1718— nsZenFolders.animateCollapse 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.
ZenGlanceChild.on_click (cyclomatic 18) src/zen/glance/actors/ZenGlanceChild.sys.mjs:135— ZenGlanceChild.on_click has cyclomatic complexity 18 (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.
nsZenWorkspaces.restoreWorkspacesFromSessionStore (cyclomatic 18) src/zen/spaces/ZenSpaceManager.mjs:854— nsZenWorkspaces.restoreWorkspacesFromSessionStore 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.
ZenUrlbarProviderGlobalActions.startQuery (cyclomatic 18) src/zen/urlbar/ZenUBActionsProvider.sys.mjs:352— ZenUrlbarProviderGlobalActions.startQuery has cyclomatic complexity 18 (threshold 15). 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, 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.
ZenUrlbarProviderSidebar.#addTabs (cyclomatic 18) src/zen/urlbar/ZenUBSidebarProvider.sys.mjs:63— ZenUrlbarProviderSidebar.#addTabs 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.
#refreshRestoredTabsState (cyclomatic 18) REDACTED:986— #refreshRestoredTabsState has cyclomatic complexity 18 (threshold 15). Of this number, 14 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, 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.
nsZenLiveFolderProvider.sniffCharset (cyclomatic 17) src/zen/live-folders/ZenLiveFolder.sys.mjs:266— nsZenLiveFolderProvider.sniffCharset 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.
nsZenWorkspaces._handleTabSelection (cyclomatic 17) src/zen/spaces/ZenSpaceManager.mjs:2648— nsZenWorkspaces._handleTabSelection 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.
nsZenSpacesSyncModel.#tabIdentity (cyclomatic 17) src/zen/sync/ZenSpacesSyncModel.sys.mjs:315— nsZenSpacesSyncModel.#tabIdentity 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.
#animateItem (cyclomatic 17) src/zen/folders/ZenFolders.mjs:1585— #animateItem has cyclomatic complexity 17 (threshold 15). Of this number, 13 points are the body's own statements and 4 belong to 3 function items inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
animateCompactMode (cyclomatic 17) src/zen/compact-mode/ZenCompactMode.mjs:427— animateCompactMode 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 7 function literals inside it that branch (lines 428, 488, 460, …). 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.
_setElementExpandAttribute (cyclomatic 17) src/zen/compact-mode/ZenCompactMode.mjs:662— _setElementExpandAttribute has cyclomatic complexity 17 (threshold 15). Of this number, 16 points are the body's own statements and 1 belongs 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.
#contextMenuItems (cyclomatic 17) src/zen/library/ZenLibraryWidget.sys.mjs:610— #contextMenuItems has cyclomatic complexity 17 (threshold 15). Of this number, 13 points are the body's own statements and 4 belong to 11 function items inside it that branch. To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
nsZenBoostsManager.boostDataFromShared (cyclomatic 16) src/zen/boosts/ZenBoostsManager.sys.mjs:860— nsZenBoostsManager.boostDataFromShared has cyclomatic complexity 16 (threshold 15). Of this number, 14 points are the body's own statements and 2 belong to one function item inside it that branches. To reduce it, 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.
nsZenFolders.openTabsPopup (cyclomatic 16) src/zen/folders/ZenFolders.mjs:884— nsZenFolders.openTabsPopup has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 4 of the 16 points are its own statements and the rest belongs to 3 function items inside it that branch (onKeyDown, onSearchInput, handlePopupHidden). 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.
ZenLibraryDragAndDrop.handle_drop (cyclomatic 16) src/zen/library/ZenLibraryDragAndDrop.mjs:134— ZenLibraryDragAndDrop.handle_drop 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.
ZenLibrarySpacesSection.#fillStrips (cyclomatic 16) src/zen/library/sections/ZenLibrarySpacesSection.mjs:417— ZenLibrarySpacesSection.#fillStrips 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.
nsZenSessionManager.onFileRead (cyclomatic 16) REDACTED:359— nsZenSessionManager.onFileRead 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, 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.
nsZenWindowSync.#syncItemWithOriginal (cyclomatic 16) src/zen/sessionstore/ZenWindowSync.sys.mjs:527— nsZenWindowSync.#syncItemWithOriginal 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.
nsZenSpacesSyncApplier.#retargetUnloadedTab (cyclomatic 16) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:679— nsZenSpacesSyncApplier.#retargetUnloadedTab 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.
generate-icons.swift.layerStructure (cyclomatic 16) src/browser/themes/shared/zen-icons/sf/generate-icons.swift:179— generate-icons.swift.layerStructure 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.
getGradientForWorkspace (cyclomatic 16) REDACTED:2470— getGradientForWorkspace 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.
#buildSearchOptions (cyclomatic 16) src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:252— #buildSearchOptions 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.
_updateEvent (cognitive 102) src/zen/common/modules/ZenVerticalTabsManager.mjs:399— _updateEvent has cognitive complexity 102 (threshold 15). Drivers by points: if/else 43 (58 pts), boolean chains 32, loops 4 (8 pts), ternaries 3, error handling 1 (nesting depth added 19). 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.
_buildModsList (cognitive 93) src/browser/components/preferences/zen-settings.js:277— _buildModsList has cognitive complexity 93 (threshold 15). Drivers by points: if/else 22 (62 pts), ternaries 4 (11 pts), loops 3 (9 pts), match/switch 1 (4 pts), other 4, boolean chains 3 (nesting depth added 56). Of this number, 60 points are the body's own statements and 33 belong to 10 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.
animateSelect (cognitive 87) src/zen/folders/ZenFolders.mjs:2113— animateSelect has cognitive complexity 87 (threshold 15). Drivers by points: if/else 17 (47 pts), loops 6 (18 pts), boolean chains 10, ternaries 4 (9 pts), other 3 (nesting depth added 47). Of this number, 70 points are the body's own statements and 17 belong to 11 function items inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
moveToAnotherTabContainerIfNecessary (cognitive 86) src/zen/tabs/ZenPinnedTabManager.mjs:756— moveToAnotherTabContainerIfNecessary has cognitive complexity 86 (threshold 15). Drivers by points: if/else 31 (68 pts), boolean chains 14, loops 2, error handling 1, ternaries 1 (nesting depth added 37). Of this number, 74 points are the body's own statements and 12 belong to 2 function literals inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
#animateTabs (cognitive 84) src/zen/spaces/ZenSpaceManager.mjs:2365— #animateTabs has cognitive complexity 84 (threshold 15). Drivers by points: if/else 23 (45 pts), ternaries 5 (18 pts), boolean chains 11, loops 5 (9 pts), error handling 1 (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
moveTabToSplitView (cognitive 78) src/zen/split-view/ZenViewSplitter.mjs:2154— moveTabToSplitView has cognitive complexity 78 (threshold 15). Drivers by points: if/else 19 (40 pts), ternaries 4 (14 pts), boolean chains 13, error handling 1 (6 pts), loops 1 (3 pts), match/switch 1, other 1 (nesting depth added 38). 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.
onWorkspaceChange (cognitive 71) REDACTED:1913— onWorkspaceChange has cognitive complexity 71 (threshold 15). Drivers by points: if/else 27 (38 pts), ternaries 7 (11 pts), loops 5 (9 pts), boolean chains 8, other 5 (nesting depth added 19). Most of this is not in the body itself: 2 of the 71 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 1919, 1978). 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.
#animateVerticalPinnedGridDragOver (cognitive 70) src/zen/drag-and-drop/ZenDragAndDrop.js:1813— #animateVerticalPinnedGridDragOver has cognitive complexity 70 (threshold 15). Drivers by points: if/else 28 (42 pts), ternaries 15 (30 pts), boolean chains 10, loops 4 (6 pts), other 2, match/switch 1 (nesting depth added 31). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
_animateTabMove (cognitive 66) src/zen/drag-and-drop/ZenDragAndDrop.js:284— _animateTabMove has cognitive complexity 66 (threshold 15). Drivers by points: if/else 26 (36 pts), ternaries 14 (18 pts), boolean chains 9, other 2, loops 1 (nesting depth added 14). Of this number, 45 points are the body's own statements and 21 belong to 7 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
onCloseTabShortcut (cognitive 62) src/zen/tabs/ZenPinnedTabManager.mjs:315— onCloseTabShortcut has cognitive complexity 62 (threshold 15). Drivers by points: if/else 13 (32 pts), loops 6 (16 pts), ternaries 3 (7 pts), boolean chains 5, error handling 1, match/switch 1 (nesting depth added 33). Of this number, 55 points are the body's own statements and 7 belong to 8 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
addMouseActions (cognitive 58) src/zen/compact-mode/ZenCompactMode.mjs:729— addMouseActions has cognitive complexity 58 (threshold 15). Drivers by points: if/else 21 (40 pts), boolean chains 14, loops 2, ternaries 1 (2 pts) (nesting depth added 20). Most of this is not in the body itself: 3 of the 58 points are its own statements and the rest belongs to 13 function items inside it that branch (a function literal at line 799, a function literal at line 863, a function literal at line 756, …). 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.
#applyDragoverIndicator (cognitive 57) src/zen/drag-and-drop/ZenDragAndDrop.js:1598— #applyDragoverIndicator has cognitive complexity 57 (threshold 15). Drivers by points: boolean chains 26, if/else 20 (26 pts), ternaries 2 (5 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.
generate-icons.swift.top-level code (cognitive 56) src/browser/themes/shared/zen-icons/sf/generate-icons.swift:20— generate-icons.swift.top-level code has cognitive complexity 56 (threshold 15). Drivers by points: if/else 19 (40 pts), loops 4 (6 pts), boolean chains 3, ternaries 1 (3 pts), error handling 1 (2 pts), match/switch 1 (2 pts) (nesting depth added 27). 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.
parseArcSidebar (cognitive 53) src/zen/migration/ZenMigrationUtils.sys.mjs:296— parseArcSidebar has cognitive complexity 53 (threshold 15). Drivers by points: if/else 12 (29 pts), loops 6 (13 pts), boolean chains 7, ternaries 1 (3 pts), other 1 (nesting depth added 26). Of this number, 31 points are the body's own statements and 22 belong to 5 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenFolders.restoreDataFromSessionStore (cognitive 51) src/zen/folders/ZenFolders.mjs:1326— nsZenFolders.restoreDataFromSessionStore has cognitive complexity 51 (threshold 15). Drivers by points: if/else 12 (33 pts), loops 5 (7 pts), boolean chains 5, match/switch 1 (4 pts), error handling 1 (2 pts) (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenFolders.animateExpand (cognitive 50) src/zen/folders/ZenFolders.mjs:1824— nsZenFolders.animateExpand has cognitive complexity 50 (threshold 15). Drivers by points: if/else 13 (36 pts), loops 3 (6 pts), boolean chains 5, ternaries 1 (3 pts) (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenSpacesSyncApplier.#applyFolders (cognitive 49) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:425— nsZenSpacesSyncApplier.#applyFolders has cognitive complexity 49 (threshold 15). Drivers by points: if/else 14 (30 pts), boolean chains 13, error handling 1 (2 pts), loops 2, ternaries 1 (2 pts) (nesting depth added 18). Of this number, 42 points are the body's own statements and 7 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
#childSequence (cognitive 44) src/zen/sync/ZenSpacesSyncModel.sys.mjs:358— #childSequence has cognitive complexity 44 (threshold 15). Drivers by points: if/else 12 (30 pts), boolean chains 8, ternaries 1 (3 pts), other 2, loops 1 (nesting depth added 20). Of this number, 43 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.
selectStartPage (cognitive 42) src/zen/spaces/ZenSpaceManager.mjs:980— selectStartPage has cognitive complexity 42 (threshold 15). Drivers by points: if/else 15 (21 pts), boolean chains 19, loops 1 (2 pts) (nesting depth added 7). Of this number, 34 points are the body's own statements and 8 belong to 6 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
#setSitePermissions (cognitive 40) src/zen/urlbar/ZenSiteDataPanel.sys.mjs:488— #setSitePermissions has cognitive complexity 40 (threshold 15). Drivers by points: if/else 13 (26 pts), loops 3 (7 pts), boolean chains 4, ternaries 1 (2 pts), error handling 1 (nesting depth added 18). Of this number, 36 points are the body's own statements and 4 belong to 5 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
SelectorComponent.getSelectionPath (cognitive 39) src/zen/boosts/ZenSelectorComponent.sys.mjs:598— SelectorComponent.getSelectionPath has cognitive complexity 39 (threshold 15). Drivers by points: if/else 21 (26 pts), ternaries 6, boolean chains 4, loops 1 (2 pts), match/switch 1 (nesting depth added 6). Most of this is not in the body itself: 12 of the 39 points are its own statements and the rest belongs to 6 function items inside it that branch (findBestExactSelector, getIdentification, traverse, …). 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.
onPinnedTabsResize (cognitive 38) src/zen/spaces/ZenSpaceManager.mjs:3044— onPinnedTabsResize has cognitive complexity 38 (threshold 15). Drivers by points: if/else 13 (25 pts), boolean chains 10, loops 2 (3 pts) (nesting depth added 13). Of this number, 34 points are the body's own statements and 4 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.
initDragAndDrop::(anonymous)::mouseMoveHandler (cognitive 38) src/zen/spaces/ZenSpaceIcons.mjs:49— initDragAndDrop::(anonymous)::mouseMoveHandler has cognitive complexity 38 (threshold 15). Drivers by points: ternaries 4 (18 pts), if/else 7 (17 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 25). 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.
_organizeWorkspaceStripLocations (cognitive 37) src/zen/spaces/ZenSpaceManager.mjs:2140— _organizeWorkspaceStripLocations has cognitive complexity 37 (threshold 15). Drivers by points: if/else 15 (24 pts), ternaries 2 (6 pts), boolean chains 5, loops 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.
generate-icons.swift.interpret (cognitive 36) src/browser/themes/shared/zen-icons/sf/generate-icons.swift:532— generate-icons.swift.interpret has cognitive complexity 36 (threshold 15). Drivers by points: if/else 8 (20 pts), loops 5 (11 pts), boolean chains 5 (nesting depth added 18). Of this number, 32 points are the body's own statements and 4 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
applyDragoverClass (cognitive 36) src/zen/tabs/ZenPinnedTabManager.mjs:1055— applyDragoverClass has cognitive complexity 36 (threshold 15). Drivers by points: if/else 21 (28 pts), boolean chains 7, ternaries 1 (nesting depth added 7). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
#applySpaces (cognitive 36) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:313— #applySpaces has cognitive complexity 36 (threshold 15). Drivers by points: if/else 8 (14 pts), other 10, boolean chains 5, loops 2 (3 pts), error handling 1 (2 pts), ternaries 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.
splitTabs (cognitive 35) src/zen/split-view/ZenViewSplitter.mjs:1431— splitTabs has cognitive complexity 35 (threshold 15). Drivers by points: if/else 11 (19 pts), boolean chains 8, loops 3 (7 pts), other 1 (nesting depth added 12). None of this is in the body itself: all 35 points belong to 7 function literals inside it that branch (lines 1438, 1441, 1443, …). 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.
receiveMessage (cognitive 35) src/zen/boosts/actors/ZenBoostsParent.sys.mjs:108— receiveMessage has cognitive complexity 35 (threshold 15). Drivers by points: if/else 11 (19 pts), ternaries 4 (10 pts), other 4, boolean chains 1, match/switch 1 (nesting depth added 14). Of this number, 33 points are the body's own statements and 2 belong to 3 function literals inside it that branch. 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.
allStoredTabs (cognitive 33) src/zen/spaces/ZenSpaceManager.mjs:3449— allStoredTabs has cognitive complexity 33 (threshold 15). Drivers by points: if/else 8 (19 pts), loops 4 (9 pts), ternaries 2 (4 pts), boolean chains 1 (nesting depth added 18). Of this number, 29 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.
handle_drop_transition (cognitive 33) src/zen/drag-and-drop/ZenDragAndDrop.js:1319— handle_drop_transition has cognitive complexity 33 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 6, loops 4 (5 pts), ternaries 5, error handling 2 (3 pts) (nesting depth added 6). Of this number, 32 points are the body's own statements and 1 belongs to 8 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.
#moveItemToMatchOriginal (cognitive 33) src/zen/sessionstore/ZenWindowSync.sys.mjs:656— #moveItemToMatchOriginal has cognitive complexity 33 (threshold 15). Drivers by points: if/else 13 (22 pts), boolean chains 5, ternaries 2 (4 pts), error handling 1 (2 pts) (nesting depth added 12). Most of this is not in the body itself: 10 of the 33 points are its own statements and the rest belongs to one function literal inside it that branches (line 695). 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.
#runStateMigration (cognitive 33) REDACTED:488— #runStateMigration has cognitive complexity 33 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 9, ternaries 2 (7 pts), loops 2 (4 pts) (nesting depth added 12). Of this number, 32 points are the body's own statements and 1 belongs 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.
fetchItems (cognitive 32) src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:24— fetchItems has cognitive complexity 32 (threshold 15). Drivers by points: if/else 9 (15 pts), loops 3 (7 pts), boolean chains 4, error handling 2 (3 pts), other 3 (nesting depth added 11). Of this number, 31 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.
#applyOrdering (cognitive 30) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:907— #applyOrdering has cognitive complexity 30 (threshold 15). Drivers by points: if/else 6 (11 pts), ternaries 2 (6 pts), boolean chains 5, loops 3 (4 pts), error handling 2 (3 pts), other 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.
nsZenShareManager.#serializeItems (cognitive 29) src/zen/share/ZenShareManager.mjs:190— nsZenShareManager.#serializeItems has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (21 pts), loops 2 (4 pts), ternaries 1 (3 pts), boolean chains 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.
nsZenSpacesSyncApplier.applyBatch (cognitive 29) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:73— nsZenSpacesSyncApplier.applyBatch has cognitive complexity 29 (threshold 15). Drivers by points: if/else 8 (15 pts), ternaries 2 (5 pts), loops 3 (4 pts), boolean chains 3, match/switch 1 (2 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ZenUBActionsProvider.sys.payloadAndSimpleHighlights (cognitive 29) src/zen/urlbar/ZenUBActionsProvider.sys.mjs:77— ZenUBActionsProvider.sys.payloadAndSimpleHighlights has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (18 pts), loops 3 (4 pts), ternaries 1 (3 pts), boolean chains 2, error handling 1 (2 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenUrlbarController.handleUrlbarClose (cognitive 29) src/zen/urlbar/ZenUrlbarController.mjs:193— nsZenUrlbarController.handleUrlbarClose has cognitive complexity 29 (threshold 15). Drivers by points: if/else 13 (23 pts), boolean chains 4, loops 1 (2 pts) (nesting depth added 11). Most of this is not in the body itself: 1 of the 29 points is its own statement and the rest belongs to 2 function literals inside it that branch (lines 199, 247). 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.
generate-icons.swift.classify (cognitive 29) src/browser/themes/shared/zen-icons/sf/generate-icons.swift:472— generate-icons.swift.classify has cognitive complexity 29 (threshold 15). Drivers by points: if/else 6 (20 pts), loops 3 (6 pts), boolean chains 3 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
animateCollapse (cognitive 29) src/zen/folders/ZenFolders.mjs:1718— animateCollapse has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (20 pts), boolean chains 5, loops 1 (2 pts), ternaries 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.
_setElementExpandAttribute (cognitive 29) src/zen/compact-mode/ZenCompactMode.mjs:662— _setElementExpandAttribute has cognitive complexity 29 (threshold 15). Drivers by points: if/else 11 (25 pts), boolean chains 4 (nesting depth added 14). Of this number, 25 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
nsZenUIManager.elementAnimate (cognitive 27) src/zen/common/modules/ZenUIManager.mjs:121— nsZenUIManager.elementAnimate has cognitive complexity 27 (threshold 15). Drivers by points: ternaries 4 (12 pts), boolean chains 7, loops 3 (5 pts), if/else 2 (3 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.
ZenLibraryDragAndDrop.handle_drop (cognitive 27) src/zen/library/ZenLibraryDragAndDrop.mjs:134— ZenLibraryDragAndDrop.handle_drop has cognitive complexity 27 (threshold 15). Drivers by points: if/else 11 (19 pts), boolean chains 4, loops 1 (3 pts), ternaries 1 (nesting depth added 10). Of this number, 26 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ZenSpaceRoutingNavigation.onStateChange (cognitive 27) src/zen/space-routing/ZenSpaceRoutingNavigation.sys.mjs:27— ZenSpaceRoutingNavigation.onStateChange has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 8, error handling 3, ternaries 1 (nesting depth added 5). Of this number, 16 points are the body's own statements and 11 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.
#updateTabIdentity (cognitive 27) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:608— #updateTabIdentity has cognitive complexity 27 (threshold 15). Drivers by points: boolean chains 11, if/else 7 (8 pts), ternaries 4 (5 pts), error handling 1 (2 pts), other 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.
connectedCallback (cognitive 27) src/zen/spaces/ZenSpace.mjs:142— connectedCallback has cognitive complexity 27 (threshold 15). Drivers by points: if/else 15 (22 pts), boolean chains 4, error handling 1 (nesting depth added 7). Most of this is not in the body itself: 7 of the 27 points are its own statements and the rest belongs to 13 function items inside it that branch (_getScrollableElements, _canScrollToElement, a function literal at line 212, …). 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.
arcSpaceTheme (cognitive 27) src/zen/migration/ZenMigrationUtils.sys.mjs:168— arcSpaceTheme has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (13 pts), boolean chains 6, loops 2 (3 pts), ternaries 1 (3 pts), other 2 (nesting depth added 6). Of this number, 14 points are the body's own statements and 13 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
#updateDropTarget (cognitive 27) src/zen/library/ZenLibraryDragAndDrop.mjs:261— #updateDropTarget has cognitive complexity 27 (threshold 15). Drivers by points: if/else 16 (18 pts), boolean chains 6, ternaries 2, other 1 (nesting depth added 2). Of this number, 26 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, 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.
nsZenFolders.setFolderIndentation (cognitive 26) src/zen/folders/ZenFolders.mjs:1112— nsZenFolders.setFolderIndentation has cognitive complexity 26 (threshold 15). Drivers by points: if/else 11 (12 pts), boolean chains 9, loops 3 (5 pts) (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
nsRssLiveFolderProvider.fetchItems (cognitive 26) src/zen/live-folders/providers/RssLiveFolder.sys.mjs:29— nsRssLiveFolderProvider.fetchItems has cognitive complexity 26 (threshold 15). Drivers by points: boolean chains 9, if/else 5 (6 pts), error handling 3 (5 pts), ternaries 5, loops 1 (nesting depth added 3). Most of this is not in the body itself: 11 of the 26 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 49, 68). 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.
nsZenWorkspaces.updateWorkspacesChangeContextMenu (cognitive 26) src/zen/spaces/ZenSpaceManager.mjs:2811— nsZenWorkspaces.updateWorkspacesChangeContextMenu has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (17 pts), loops 3 (5 pts), ternaries 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.
moveTabsToWorkspace (cognitive 25) src/zen/spaces/ZenSpaceManager.mjs:1837— moveTabsToWorkspace has cognitive complexity 25 (threshold 15). Drivers by points: if/else 6 (14 pts), ternaries 3 (6 pts), loops 2 (5 pts) (nesting depth added 14). Of this number, 21 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
boostDataFromShared (cognitive 25) src/zen/boosts/ZenBoostsManager.sys.mjs:860— boostDataFromShared has cognitive complexity 25 (threshold 15). Drivers by points: if/else 7 (12 pts), ternaries 3 (5 pts), boolean chains 4, loops 2 (4 pts) (nesting depth added 9). Of this number, 23 points are the body's own statements and 2 belong to 2 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenLiveFoldersManager.onLiveFolderFetch (cognitive 24) src/zen/live-folders/ZenLiveFoldersManager.sys.mjs:432— nsZenLiveFoldersManager.onLiveFolderFetch has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (16 pts), boolean chains 3, loops 2 (3 pts), error handling 1, ternaries 1 (nesting depth added 6). Of this number, 17 points are the body's own statements and 7 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
onBrowserDragOverToSplit (cognitive 24) src/zen/split-view/ZenViewSplitter.mjs:325— onBrowserDragOverToSplit has cognitive complexity 24 (threshold 15). Drivers by points: if/else 12 (13 pts), boolean chains 11 (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.
animateCompactMode (cognitive 24) src/zen/compact-mode/ZenCompactMode.mjs:427— animateCompactMode has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (13 pts), ternaries 4 (7 pts), boolean chains 4 (nesting depth added 5). None of this is in the body itself: all 24 points belong to 7 function literals inside it that branch (lines 428, 488, 460, …). 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.
nsZenLiveFolderProvider.fetch (cognitive 23) src/zen/live-folders/ZenLiveFolder.sys.mjs:125— nsZenLiveFolderProvider.fetch has cognitive complexity 23 (threshold 15). Drivers by points: if/else 11 (13 pts), error handling 4, boolean chains 3, loops 2, ternaries 1 (nesting depth added 2). Most of this is not in the body itself: 5 of the 23 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 180, 214, 172). 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.
nsZenWorkspaceIcons.initDragAndDrop (cognitive 23) src/zen/spaces/ZenSpaceIcons.mjs:28— nsZenWorkspaceIcons.initDragAndDrop has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (18 pts), boolean chains 2, loops 1 (2 pts), ternaries 1 (nesting depth added 11). None of this is in the body itself: all 23 points belong to 2 function literals inside it that branch (lines 49, 32). 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.
onBrowserDragStart (cognitive 23) src/zen/split-view/ZenViewSplitter.mjs:790— onBrowserDragStart has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13 (17 pts), error handling 2 (4 pts), boolean chains 2 (nesting depth added 6). 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.
onThemePickerClick (cognitive 23) REDACTED:1125— onThemePickerClick has cognitive complexity 23 (threshold 15). Drivers by points: if/else 14 (17 pts), boolean chains 4, ternaries 1 (2 pts) (nesting depth added 4). Of this number, 20 points are the body's own statements and 3 belong to 6 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, 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.
#animateItem (cognitive 23) src/zen/folders/ZenFolders.mjs:1585— #animateItem has cognitive complexity 23 (threshold 15). Drivers by points: ternaries 5 (8 pts), if/else 5 (7 pts), boolean chains 3, loops 3, error handling 1, other 1 (nesting depth added 5). Of this number, 19 points are the body's own statements and 4 belong to 3 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ZenLibrarySpacesSection.#fillStrips (cognitive 22) src/zen/library/sections/ZenLibrarySpacesSection.mjs:417— ZenLibrarySpacesSection.#fillStrips has cognitive complexity 22 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 5, loops 2 (3 pts), ternaries 1 (2 pts) (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenThemePicker.calculateCompliments::getColorHarmonyType (cognitive 22) REDACTED:943— nsZenThemePicker.calculateCompliments::getColorHarmonyType has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (21 pts), boolean chains 1 (nesting depth added 11). 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.
ZenUrlbarProviderGlobalActions.#calculateFuzzyScore (cognitive 22) src/zen/urlbar/ZenUBActionsProvider.sys.mjs:293— ZenUrlbarProviderGlobalActions.#calculateFuzzyScore has cognitive complexity 22 (threshold 15). Drivers by points: if/else 10 (17 pts), boolean chains 3, loops 1, ternaries 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ZenUrlbarProviderSidebar.#addTabs (cognitive 22) src/zen/urlbar/ZenUBSidebarProvider.sys.mjs:63— ZenUrlbarProviderSidebar.#addTabs has cognitive complexity 22 (threshold 15). Drivers by points: if/else 5 (10 pts), boolean chains 9, ternaries 1 (2 pts), loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
#migrateLegacyShortcuts (cognitive 22) src/zen/kbs/ZenKeyboardShortcuts.sys.mjs:276— #migrateLegacyShortcuts has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 2, loops 2, error handling 1, other 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.
tokens.loadZenTokens (cognitive 21) src/zen/tokens/tokens.mjs:34— tokens.loadZenTokens has cognitive complexity 21 (threshold 15). Drivers by points: if/else 4 (15 pts), loops 3 (6 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.
nsZenViewSplitter.restoreDataFromSessionStore (cognitive 21) src/zen/split-view/ZenViewSplitter.mjs:2447— nsZenViewSplitter.restoreDataFromSessionStore has cognitive complexity 21 (threshold 15). Drivers by points: if/else 8 (16 pts), loops 2 (3 pts), error handling 1 (2 pts) (nesting depth added 10). Of this number, 11 points are the body's own statements and 10 belong to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenSpacesSyncModel.#projectionContext (cognitive 21) src/zen/sync/ZenSpacesSyncModel.sys.mjs:448— nsZenSpacesSyncModel.#projectionContext has cognitive complexity 21 (threshold 15). Drivers by points: boolean chains 12, if/else 4 (6 pts), loops 2, ternaries 1 (nesting depth added 2). Of this number, 15 points are the body's own statements and 6 belong to 3 function items inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
nsZenPinnedTabManager.addToEssentials (cognitive 21) src/zen/tabs/ZenPinnedTabManager.mjs:511— nsZenPinnedTabManager.addToEssentials has cognitive complexity 21 (threshold 15). Drivers by points: if/else 7 (14 pts), ternaries 3 (5 pts), boolean chains 1, loops 1 (nesting depth added 9). 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.
ZenUrlbarProviderGlobalActions.startQuery (cognitive 21) src/zen/urlbar/ZenUBActionsProvider.sys.mjs:352— ZenUrlbarProviderGlobalActions.startQuery has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 4 (9 pts), if/else 5 (6 pts), boolean chains 5, loops 1 (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.
getGradient (cognitive 21) REDACTED:1691— getGradient has cognitive complexity 21 (threshold 15). Drivers by points: if/else 6 (9 pts), ternaries 5 (9 pts), other 2, loops 1 (nesting depth added 7). Most of this is not in the body itself: 9 of the 21 points are its own statements and the rest belongs to 5 function items inside it that branch (getBrowserBg, a function literal at line 1724, a function literal at line 1716, …). 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.
ZenDragAndDrop.#animateVerticalPinnedGridDragOver::getTabShift (cognitive 20) src/zen/drag-and-drop/ZenDragAndDrop.js:2002— ZenDragAndDrop.#animateVerticalPinnedGridDragOver::getTabShift has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 4 (10 pts), if/else 4 (6 pts), boolean chains 4 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenWindowSync.#syncItemWithOriginal (cognitive 20) src/zen/sessionstore/ZenWindowSync.sys.mjs:527— nsZenWindowSync.#syncItemWithOriginal has cognitive complexity 20 (threshold 15). Drivers by points: if/else 11 (14 pts), boolean chains 3, error handling 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.
nsZenWorkspaces.propagateWorkspaces (cognitive 20) src/zen/spaces/ZenSpaceManager.mjs:1553— nsZenWorkspaces.propagateWorkspaces has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 3, loops 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.
nsZenWorkspaces.#updateWorkspaceState (cognitive 20) src/zen/spaces/ZenSpaceManager.mjs:2702— nsZenWorkspaces.#updateWorkspaceState has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (10 pts), loops 3 (6 pts), boolean chains 4 (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.
nsZenViewSplitter.removeTabFromGroup (cognitive 20) src/zen/split-view/ZenViewSplitter.mjs:211— nsZenViewSplitter.removeTabFromGroup has cognitive complexity 20 (threshold 15). Drivers by points: if/else 10 (16 pts), loops 1 (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.
#contextMenuItems (cognitive 20) src/zen/library/ZenLibraryWidget.sys.mjs:610— #contextMenuItems has cognitive complexity 20 (threshold 15). Drivers by points: error handling 4 (8 pts), if/else 8, boolean chains 4 (nesting depth added 4). Of this number, 12 points are the body's own statements and 8 belong to 11 function items inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
#initSidebarResizer (cognitive 20) src/zen/common/sys/ZenCustomizableUI.sys.mjs:136— #initSidebarResizer has cognitive complexity 20 (threshold 15). Drivers by points: if/else 13 (14 pts), boolean chains 3, ternaries 3 (nesting depth added 1). None of this is in the body itself: all 20 points belong to 10 function items inside it that branch (applyDrag, endDrag, a function literal at line 207, …). 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.
nsZenFolders.openTabsPopup (cognitive 19) src/zen/folders/ZenFolders.mjs:884— nsZenFolders.openTabsPopup has cognitive complexity 19 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 4, loops 1 (nesting depth added 4). Most of this is not in the body itself: 3 of the 19 points are its own statements and the rest belongs to 3 function items inside it that branch (onKeyDown, onSearchInput, handlePopupHidden). 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.
ZenMigrationUtilsClass.#ensureSpace (cognitive 19) src/zen/migration/ZenMigrationUtils.sys.mjs:597— ZenMigrationUtilsClass.#ensureSpace has cognitive complexity 19 (threshold 15). Drivers by points: if/else 8 (15 pts), boolean chains 4 (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.
nsZenWindowSync.#onTabSwitchOrWindowFocus (cognitive 19) src/zen/sessionstore/ZenWindowSync.sys.mjs:1184— nsZenWindowSync.#onTabSwitchOrWindowFocus has cognitive complexity 19 (threshold 15). Drivers by points: if/else 5 (9 pts), ternaries 2 (5 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 8). 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.
nsZenSpacesSyncApplier.#applySplits (cognitive 19) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:830— nsZenSpacesSyncApplier.#applySplits has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (10 pts), loops 2 (4 pts), boolean chains 3, error handling 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.
generate-icons.swift.layerStructure (cognitive 19) src/browser/themes/shared/zen-icons/sf/generate-icons.swift:179— generate-icons.swift.layerStructure has cognitive complexity 19 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 6, loops 3 (4 pts) (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ZenLibrary.openProgress (cognitive 18) src/zen/library/ZenLibrary.mjs:237— ZenLibrary.openProgress has cognitive complexity 18 (threshold 15). Drivers by points: if/else 7 (10 pts), ternaries 3 (6 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.
nsZenLiveFolderProvider.sniffCharset (cognitive 18) src/zen/live-folders/ZenLiveFolder.sys.mjs:266— nsZenLiveFolderProvider.sniffCharset has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (13 pts), boolean chains 4, error handling 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ZenMigrationUtilsClass.#bookmarkChildrenToItems (cognitive 18) src/zen/migration/ZenMigrationUtils.sys.mjs:538— ZenMigrationUtilsClass.#bookmarkChildrenToItems has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (12 pts), boolean chains 3, ternaries 1 (2 pts), 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.
nsZenWorkspaces._handleTabSelection (cognitive 18) src/zen/spaces/ZenSpaceManager.mjs:2648— nsZenWorkspaces._handleTabSelection has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (10 pts), boolean chains 8 (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.
nsZenWorkspaces.onWindowResize (cognitive 18) src/zen/spaces/ZenSpaceManager.mjs:3656— nsZenWorkspaces.onWindowResize has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 3, loops 2 (3 pts), ternaries 1 (nesting depth added 4). 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 into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
nsZenSpacesSyncModel.#tabIdentity (cognitive 18) src/zen/sync/ZenSpacesSyncModel.sys.mjs:315— nsZenSpacesSyncModel.#tabIdentity has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 10, if/else 4 (7 pts), ternaries 1 (nesting depth added 3). 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.
nsZenTabRenamer.start (cognitive 18) src/zen/tabs/ZenTabRenamer.mjs:31— nsZenTabRenamer.start has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 9, if/else 7, ternaries 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.
nsZenUrlbarController.handleNewTab (cognitive 18) src/zen/urlbar/ZenUrlbarController.mjs:84— nsZenUrlbarController.handleNewTab has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (10 pts), boolean chains 6, error handling 1, 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.
check_unused_icons.find_icon_usage (cognitive 18) src/browser/themes/shared/zen-icons/check_unused_icons.py:24— check_unused_icons.find_icon_usage has cognitive complexity 18 (threshold 15). Drivers by points: if/else 3 (9 pts), loops 3 (6 pts), error handling 1 (3 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.
restoreWorkspacesFromSessionStore (cognitive 18) src/zen/spaces/ZenSpaceManager.mjs:854— restoreWorkspacesFromSessionStore has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (8 pts), boolean chains 5, loops 3, ternaries 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
#refreshRestoredTabsState (cognitive 18) REDACTED:986— #refreshRestoredTabsState has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (10 pts), boolean chains 4, error handling 1 (2 pts), loops 2 (nesting depth added 5). Of this number, 15 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.
#buildSearchOptions (cognitive 18) src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:252— #buildSearchOptions has cognitive complexity 18 (threshold 15). Drivers by points: if/else 4 (6 pts), loops 3 (4 pts), other 4, boolean chains 3, 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.
nsZenSpacesSyncApplier.#applyContainers (cognitive 17) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:258— nsZenSpacesSyncApplier.#applyContainers has cognitive complexity 17 (threshold 15). Drivers by points: if/else 5 (9 pts), error handling 2 (4 pts), loops 2, ternaries 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.
handleTabBeforeClose (cognitive 17) src/zen/spaces/ZenSpaceManager.mjs:1234— handleTabBeforeClose has cognitive complexity 17 (threshold 15). Drivers by points: if/else 8 (11 pts), boolean chains 5, ternaries 1 (nesting depth added 3). Of this number, 16 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
onFileRead (cognitive 17) REDACTED:359— onFileRead has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (9 pts), boolean chains 5, loops 1 (3 pts) (nesting depth added 4). Of this number, 14 points are the body's own statements and 3 belong to 3 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
nsZenFolders.storeDataForSessionStore (cognitive 16) src/zen/folders/ZenFolders.mjs:1255— nsZenFolders.storeDataForSessionStore has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (11 pts), boolean chains 2, ternaries 1 (2 pts), loops 1 (nesting depth added 5). 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.
ZenGlanceChild.on_click (cognitive 16) src/zen/glance/actors/ZenGlanceChild.sys.mjs:135— ZenGlanceChild.on_click has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (9 pts), boolean chains 7 (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.
nsZenSessionManager.#restoreWindowData (cognitive 16) REDACTED:848— nsZenSessionManager.#restoreWindowData has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 11, if/else 4 (5 pts) (nesting depth added 1). 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.
nsZenWorkspaces.switchTabIfNeeded (cognitive 16) src/zen/spaces/ZenSpaceManager.mjs:3570— nsZenWorkspaces.switchTabIfNeeded has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (10 pts), boolean chains 5, error handling 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.
nsZenViewSplitter.createEmptySplit (cognitive 16) src/zen/split-view/ZenViewSplitter.mjs:2567— nsZenViewSplitter.createEmptySplit has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (7 pts), ternaries 4 (6 pts), boolean chains 3 (nesting depth added 3). Most of this is not in the body itself: 4 of the 16 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 2601, 2585, 2582). 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.
onLocationChange (cognitive 16) src/zen/spaces/ZenSpaceManager.mjs:3175— onLocationChange has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 3 (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.
_handle_tabDragOverToSplit (cognitive 16) src/zen/drag-and-drop/ZenDragAndDrop.js:913— _handle_tabDragOverToSplit has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8, boolean chains 7, ternaries 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.
FunctionTooLong: generate-icons.swift.top-level code src/browser/themes/shared/zen-icons/sf/generate-icons.swift:20— FunctionTooLong — top-level code runs 137 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 37 over it, 1.37× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
D30 · Dependency Vulnerabilities· Medium advisory (unmaintained) · ×1
End-of-life runtime: Rust 1.95 rust-toolchain.toml:1— rust-toolchain.toml declares Rust 1.95 as this project's toolchain file, and Rust 1.95, superseded by 1.96 on 2026-05-28 (the Rust project patches only the current stable). An unsupported runtime receives no security patches, so every vulnerability disclosed in it since 2026-05-28 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.
Off the main sequence: src/zen — src/zen: abstractness 0.00, instability 0.00, distance 1.00 — zone of pain — concrete and depended on by 1 project(s), so it's rigid to change.
No structured logging — No logging or diagnostics emission found. This repository ships a binary its users launch rather than a service you operate, so there is no operator to page — but when a run fails on a user's machine, neither they nor you have anything to read.
Duplication concentrated across 12 sibling directories (9 clone groups) src/zen/library/ZenLibrary.mjs:698— 9 duplicated blocks under src/zen/ have copies in at least two of the sibling directories about, boosts, common, downloads, glance, library (+6 more sibling(s) not listed) — 4 of them are reported below, and 5 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 9 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 9 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 9 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 (77 matched lines × 2 locations) · ×1
Duplicated block with local edits (77 matched lines × 2 locations) src/zen/library/ZenLibraryWidget.sys.mjs:467— src/zen/library/ZenLibraryWidget.sys.mjs:467 · src/zen/library/sections/ZenLibraryDownloadsSection.mjs:159 — the two spans are one implementation copied and then locally edited — 408 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 (29 matched lines × 2 locations) · ×1
Duplicated block with local edits (29 matched lines × 2 locations) src/zen/library/ZenLibrary.mjs:698— src/zen/library/ZenLibrary.mjs:698 · src/zen/spaces/ZenSpaceAddSwipe.mjs:144 — the two spans are one implementation copied and then locally edited — 153 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 (27 matched lines × 2 locations) · ×1
Duplicated block with local edits (27 matched lines × 2 locations) src/zen/boosts/ZenSelectorComponent.sys.mjs:162— src/zen/boosts/ZenSelectorComponent.sys.mjs:162 · src/zen/boosts/ZenZapDissolve.sys.mjs:524 — the two spans are one implementation copied and then locally edited — 141 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 (24 matched lines × 2 locations) · ×1
Duplicated block with local edits (24 matched lines × 2 locations) src/zen/boosts/ZenBoostsEditor.mjs:684— src/zen/boosts/ZenBoostsEditor.mjs:684 · REDACTED:567 — the two spans are one implementation copied and then locally edited — 202 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 (19 lines × 2 locations) src/zen/boosts/ZenBoostReceiveDialog.mjs:37— src/zen/boosts/ZenBoostReceiveDialog.mjs:37 · src/zen/boosts/ZenBoostShareDialog.mjs:49 — 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 (17 matched lines × 2 locations) · ×1
Duplicated block with local edits (17 matched lines × 2 locations) src/zen/urlbar/ZenSiteDataPanel.sys.mjs:298— src/zen/urlbar/ZenSiteDataPanel.sys.mjs:298 · src/zen/urlbar/ZenSiteDataPanel.sys.mjs:646 — the two spans are one implementation copied and then locally edited — 126 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 (15 lines × 2 locations) src/zen/spaces/ZenSpaceCreation.mjs:110— src/zen/spaces/ZenSpaceCreation.mjs:110 · src/zen/spaces/ZenSpaceCreation.mjs:131 — 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.
R10 · Code Duplication· Duplicated block with local edits (14 matched lines × 2 locations) · ×1
Duplicated block with local edits (14 matched lines × 2 locations) src/zen/library/ZenLibrary.mjs:540— src/zen/library/ZenLibrary.mjs:540 · src/zen/library/ZenLibrary.mjs:645 — the two spans are one implementation copied and then locally edited — 75 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 (9 lines × 4 locations) src/zen/boosts/ZenBoostsEditor.mjs:100— src/zen/boosts/ZenBoostsEditor.mjs:100 · src/zen/boosts/ZenBoostsEditor.mjs:110 · src/zen/boosts/ZenBoostsEditor.mjs:128 · src/zen/boosts/ZenBoostsEditor.mjs:140 — all 4 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.
R10 · Code Duplication· Duplicated block with local edits (9 matched lines × 2 locations) · ×1
Duplicated block with local edits (9 matched lines × 2 locations) src/zen/migration/ZenMigrationUtils.sys.mjs:524— src/zen/migration/ZenMigrationUtils.sys.mjs:524 · src/zen/migration/ZenMigrationUtils.sys.mjs:538 — the two spans are one implementation copied and then locally edited — 80 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.
Complex function _updateEvent (cyclomatic 82, cognitive 102) src/zen/common/modules/ZenVerticalTabsManager.mjs:399— _updateEvent has cyclomatic complexity 82 and cognitive complexity 102; 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 #applyDragoverIndicator (cyclomatic 55, cognitive 57) src/zen/drag-and-drop/ZenDragAndDrop.js:1598— #applyDragoverIndicator has cyclomatic complexity 55 and cognitive complexity 57; 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 (anonymous) (cyclomatic 47, cognitive 69) REDACTED:1919— (anonymous) has cyclomatic complexity 47 and cognitive complexity 69; 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 #animateVerticalPinnedGridDragOver (cyclomatic 46, cognitive 70) src/zen/drag-and-drop/ZenDragAndDrop.js:1813— #animateVerticalPinnedGridDragOver has cyclomatic complexity 46 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 #animateTabs (cyclomatic 44, cognitive 84) src/zen/spaces/ZenSpaceManager.mjs:2365— #animateTabs has cyclomatic complexity 44 and cognitive complexity 84; 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 moveTabToSplitView (cyclomatic 43, cognitive 78) src/zen/split-view/ZenViewSplitter.mjs:2154— moveTabToSplitView has cyclomatic complexity 43 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.
Complex function (anonymous) (cyclomatic 39, cognitive 84) src/zen/tests/performance/browser_startup_content_mainthreadio.js:244— (anonymous) has cyclomatic complexity 39 and cognitive complexity 84; 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 moveToAnotherTabContainerIfNecessary (cyclomatic 39, cognitive 74) src/zen/tabs/ZenPinnedTabManager.mjs:756— moveToAnotherTabContainerIfNecessary has cyclomatic complexity 39 and cognitive complexity 74; 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 _animateTabMove (cyclomatic 36, cognitive 45) src/zen/drag-and-drop/ZenDragAndDrop.js:284— _animateTabMove has cyclomatic complexity 36 and cognitive complexity 45; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
Complex function handle_drop_transition (cyclomatic 36, cognitive 32) src/zen/drag-and-drop/ZenDragAndDrop.js:1319— handle_drop_transition has cyclomatic complexity 36 and cognitive complexity 32; 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 (anonymous) (cyclomatic 35, cognitive 71) src/zen/tests/performance/browser_startup_mainthreadio.js:589— (anonymous) has cyclomatic complexity 35 and cognitive complexity 71; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
Complex function onCloseTabShortcut (cyclomatic 32, cognitive 55) src/zen/tabs/ZenPinnedTabManager.mjs:315— onCloseTabShortcut has cyclomatic complexity 32 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.
Complex function #applySpaces (cyclomatic 29, cognitive 36) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:313— #applySpaces has cyclomatic complexity 29 and cognitive complexity 36; 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 onBrowserDragOverToSplit (cyclomatic 29, cognitive 24) src/zen/split-view/ZenViewSplitter.mjs:325— onBrowserDragOverToSplit has cyclomatic complexity 29 and cognitive complexity 24; 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 selectStartPage (cyclomatic 28, cognitive 34) src/zen/spaces/ZenSpaceManager.mjs:980— selectStartPage has cyclomatic complexity 28 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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 animateSelect (cyclomatic 27, cognitive 70) src/zen/folders/ZenFolders.mjs:2113— animateSelect has cyclomatic complexity 27 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 _buildModsList (cyclomatic 27, cognitive 60) src/browser/components/preferences/zen-settings.js:277— _buildModsList has cyclomatic complexity 27 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 handleStorage (cyclomatic 27, cognitive 47) src/zen/tests/mochitests/sync/head_http_server.js:1055— handleStorage has cyclomatic complexity 27 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.
Complex function #applyFolders (cyclomatic 27, cognitive 42) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:425— #applyFolders has cyclomatic complexity 27 and cognitive complexity 42; 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 #updateTabIdentity (cyclomatic 27, cognitive 27) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:608— #updateTabIdentity has cyclomatic complexity 27 and cognitive complexity 27; 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 applyDragoverClass (cyclomatic 26, cognitive 36) src/zen/tabs/ZenPinnedTabManager.mjs:1055— applyDragoverClass has cyclomatic complexity 26 and cognitive complexity 36; 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 (anonymous) (cyclomatic 25, cognitive 63) src/zen/tests/performance/browser_startup.js:144— (anonymous) has cyclomatic complexity 25 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.
Complex function restoreDataFromSessionStore (cyclomatic 25, cognitive 51) src/zen/folders/ZenFolders.mjs:1326— restoreDataFromSessionStore has cyclomatic complexity 25 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.
Complex function #childSequence (cyclomatic 25, cognitive 43) src/zen/sync/ZenSpacesSyncModel.sys.mjs:358— #childSequence has cyclomatic complexity 25 and cognitive complexity 43; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive is at or above cyclomatic here, so the branching is nested or entangled rather than laid out side by side — extracting each decision into its own named function is the change that pays. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
Complex function onPinnedTabsResize (cyclomatic 25, cognitive 34) src/zen/spaces/ZenSpaceManager.mjs:3044— onPinnedTabsResize has cyclomatic complexity 25 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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 receiveMessage (cyclomatic 25, cognitive 33) src/zen/boosts/actors/ZenBoostsParent.sys.mjs:108— receiveMessage has cyclomatic complexity 25 and cognitive complexity 33; 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 setFolderIndentation (cyclomatic 25, cognitive 25) src/zen/folders/ZenFolders.mjs:1112— setFolderIndentation has cyclomatic complexity 25 and cognitive complexity 25; 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 (anonymous) (cyclomatic 24, cognitive 39) src/zen/tests/performance/browser_startup_syncIPC.js:338— (anonymous) has cyclomatic complexity 24 and cognitive complexity 39; 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 #updateDropTarget (cyclomatic 24, cognitive 26) src/zen/library/ZenLibraryDragAndDrop.mjs:261— #updateDropTarget has cyclomatic complexity 24 and cognitive complexity 26; 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 _handle_tabDragOverToSplit (cyclomatic 24, cognitive 16) src/zen/drag-and-drop/ZenDragAndDrop.js:913— _handle_tabDragOverToSplit has cyclomatic complexity 24 and cognitive complexity 16; 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 _organizeWorkspaceStripLocations (cyclomatic 23, cognitive 37) src/zen/spaces/ZenSpaceManager.mjs:2140— _organizeWorkspaceStripLocations has cyclomatic complexity 23 and cognitive complexity 37; 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 animateExpand (cyclomatic 22, cognitive 50) src/zen/folders/ZenFolders.mjs:1824— animateExpand has cyclomatic complexity 22 and cognitive complexity 50; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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 applyBatch (cyclomatic 22, cognitive 29) src/zen/sync/ZenSpacesSyncApplier.sys.mjs:73— applyBatch has cyclomatic complexity 22 and cognitive complexity 29; 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 onStateChange (cyclomatic 22, cognitive 16) src/zen/space-routing/ZenSpaceRoutingNavigation.sys.mjs:27— onStateChange has cyclomatic complexity 22 and cognitive complexity 16; 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 (anonymous) (cyclomatic 21, cognitive 34) src/zen/split-view/ZenViewSplitter.mjs:1438— (anonymous) has cyclomatic complexity 21 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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 importStudioTokens (cyclomatic 21, cognitive 33) scripts/tokens_studio.mjs:428— importStudioTokens has cyclomatic complexity 21 and cognitive complexity 33; 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 #runStateMigration (cyclomatic 21, cognitive 32) REDACTED:488— #runStateMigration has cyclomatic complexity 21 and cognitive complexity 32; 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 fetchItems (cyclomatic 21, cognitive 31) src/zen/live-folders/providers/GithubLiveFolder.sys.mjs:24— fetchItems has cyclomatic complexity 21 and cognitive complexity 31; 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 start (cyclomatic 21, cognitive 17) src/zen/tabs/ZenTabRenamer.mjs:31— start has cyclomatic complexity 21 and cognitive complexity 17; 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 #setSitePermissions (cyclomatic 20, cognitive 36) src/zen/urlbar/ZenSiteDataPanel.sys.mjs:488— #setSitePermissions has cyclomatic complexity 20 and cognitive complexity 36; 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· src/zen/spaces/ZenSpaceManager.mjs · ×1
src/zen/spaces/ZenSpaceManager.mjs: 3449 lines of code src/zen/spaces/ZenSpaceManager.mjs:1— src/zen/spaces/ZenSpaceManager.mjs has 3449 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· src/zen/split-view/ZenViewSplitter.mjs · ×1
src/zen/split-view/ZenViewSplitter.mjs: 2456 lines of code src/zen/split-view/ZenViewSplitter.mjs:1— src/zen/split-view/ZenViewSplitter.mjs has 2456 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: 2295 lines of code REDACTED:1— REDACTED has 2295 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· src/zen/folders/ZenFolders.mjs · ×1
src/zen/folders/ZenFolders.mjs: 2197 lines of code src/zen/folders/ZenFolders.mjs:1— src/zen/folders/ZenFolders.mjs has 2197 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· src/zen/drag-and-drop/ZenDragAndDrop.js · ×1
src/zen/drag-and-drop/ZenDragAndDrop.js: 2107 lines of code src/zen/drag-and-drop/ZenDragAndDrop.js:1— src/zen/drag-and-drop/ZenDragAndDrop.js has 2107 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· src/zen/glance/ZenGlanceManager.mjs · ×1
src/zen/glance/ZenGlanceManager.mjs: 1924 lines of code src/zen/glance/ZenGlanceManager.mjs:1— src/zen/glance/ZenGlanceManager.mjs has 1924 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· src/zen/sessionstore/ZenWindowSync.sys.mjs · ×1
src/zen/sessionstore/ZenWindowSync.sys.mjs: 1694 lines of code src/zen/sessionstore/ZenWindowSync.sys.mjs:1— src/zen/sessionstore/ZenWindowSync.sys.mjs has 1694 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· src/zen/boosts/ZenBoostsEditor.mjs · ×1
src/zen/boosts/ZenBoostsEditor.mjs: 1595 lines of code src/zen/boosts/ZenBoostsEditor.mjs:1— src/zen/boosts/ZenBoostsEditor.mjs has 1595 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· src/zen/tabs/ZenPinnedTabManager.mjs · ×1
src/zen/tabs/ZenPinnedTabManager.mjs: 1112 lines of code src/zen/tabs/ZenPinnedTabManager.mjs:1— src/zen/tabs/ZenPinnedTabManager.mjs has 1112 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· src/zen/library/sections/ZenLibrarySpacesSection.mjs · ×1
src/zen/library/sections/ZenLibrarySpacesSection.mjs: 1079 lines of code src/zen/library/sections/ZenLibrarySpacesSection.mjs:1— src/zen/library/sections/ZenLibrarySpacesSection.mjs has 1079 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· src/zen/library/ZenLibrary.mjs · ×1
src/zen/library/ZenLibrary.mjs: 1070 lines of code src/zen/library/ZenLibrary.mjs:1— src/zen/library/ZenLibrary.mjs has 1070 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: 1021 lines of code REDACTED:1— REDACTED has 1021 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· src/zen/compact-mode/ZenCompactMode.mjs · ×1
src/zen/compact-mode/ZenCompactMode.mjs: 980 lines of code src/zen/compact-mode/ZenCompactMode.mjs:1— src/zen/compact-mode/ZenCompactMode.mjs has 980 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· src/zen/welcome/ZenWelcome.mjs · ×1
src/zen/welcome/ZenWelcome.mjs: 975 lines of code src/zen/welcome/ZenWelcome.mjs:1— src/zen/welcome/ZenWelcome.mjs has 975 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· src/zen/sync/ZenSpacesSyncApplier.sys.mjs · ×1
src/zen/sync/ZenSpacesSyncApplier.sys.mjs: 916 lines of code src/zen/sync/ZenSpacesSyncApplier.sys.mjs:1— src/zen/sync/ZenSpacesSyncApplier.sys.mjs has 916 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
R3 · Large Files· src/zen/boosts/ZenBoostsManager.sys.mjs · ×1
src/zen/boosts/ZenBoostsManager.sys.mjs: 893 lines of code src/zen/boosts/ZenBoostsManager.sys.mjs:1— src/zen/boosts/ZenBoostsManager.sys.mjs has 893 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· src/zen/urlbar/ZenSiteDataPanel.sys.mjs · ×1
src/zen/urlbar/ZenSiteDataPanel.sys.mjs: 880 lines of code src/zen/urlbar/ZenSiteDataPanel.sys.mjs:1— src/zen/urlbar/ZenSiteDataPanel.sys.mjs has 880 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· src/zen/share/ZenShareManager.mjs · ×1
src/zen/share/ZenShareManager.mjs: 824 lines of code src/zen/share/ZenShareManager.mjs:1— src/zen/share/ZenShareManager.mjs has 824 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· src/zen/sync/ZenSpacesSyncModel.sys.mjs · ×1
src/zen/sync/ZenSpacesSyncModel.sys.mjs: 821 lines of code src/zen/sync/ZenSpacesSyncModel.sys.mjs:1— src/zen/sync/ZenSpacesSyncModel.sys.mjs has 821 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· src/zen/library/sections/ZenLibraryDownloadsSection.mjs · ×1
src/zen/library/sections/ZenLibraryDownloadsSection.mjs: 746 lines of code src/zen/library/sections/ZenLibraryDownloadsSection.mjs:1— src/zen/library/sections/ZenLibraryDownloadsSection.mjs has 746 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· src/zen/library/sections/ZenLibraryHistorySection.mjs · ×1
src/zen/library/sections/ZenLibraryHistorySection.mjs: 728 lines of code src/zen/library/sections/ZenLibraryHistorySection.mjs:1— src/zen/library/sections/ZenLibraryHistorySection.mjs has 728 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· src/browser/components/preferences/zen-settings.js · ×1
src/browser/components/preferences/zen-settings.js: 726 lines of code src/browser/components/preferences/zen-settings.js:1— src/browser/components/preferences/zen-settings.js has 726 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· src/zen/media/ZenMediaController.sys.mjs · ×1
src/zen/media/ZenMediaController.sys.mjs: 716 lines of code src/zen/media/ZenMediaController.sys.mjs:1— src/zen/media/ZenMediaController.sys.mjs has 716 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· src/zen/common/modules/ZenVerticalTabsManager.mjs · ×1
src/zen/common/modules/ZenVerticalTabsManager.mjs: 706 lines of code src/zen/common/modules/ZenVerticalTabsManager.mjs:1— src/zen/common/modules/ZenVerticalTabsManager.mjs has 706 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· src/zen/library/ZenLibraryWidget.sys.mjs · ×1
src/zen/library/ZenLibraryWidget.sys.mjs: 704 lines of code src/zen/library/ZenLibraryWidget.sys.mjs:1— src/zen/library/ZenLibraryWidget.sys.mjs has 704 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· src/zen/boosts/ZenSelectorComponent.sys.mjs · ×1
src/zen/boosts/ZenSelectorComponent.sys.mjs: 689 lines of code src/zen/boosts/ZenSelectorComponent.sys.mjs:1— src/zen/boosts/ZenSelectorComponent.sys.mjs has 689 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· src/zen/migration/ZenMigrationUtils.sys.mjs · ×1
src/zen/migration/ZenMigrationUtils.sys.mjs: 683 lines of code src/zen/migration/ZenMigrationUtils.sys.mjs:1— src/zen/migration/ZenMigrationUtils.sys.mjs has 683 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· src/zen/spaces/ZenSpace.mjs · ×1
src/zen/spaces/ZenSpace.mjs: 669 lines of code src/zen/spaces/ZenSpace.mjs:1— src/zen/spaces/ZenSpace.mjs has 669 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: 659 lines of code REDACTED:1— REDACTED has 659 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
src/zen/mods/ZenMods.mjs: 630 lines of code src/zen/mods/ZenMods.mjs:1— src/zen/mods/ZenMods.mjs has 630 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· src/zen/live-folders/ZenLiveFoldersManager.sys.mjs · ×1
src/zen/live-folders/ZenLiveFoldersManager.sys.mjs: 629 lines of code src/zen/live-folders/ZenLiveFoldersManager.sys.mjs:1— src/zen/live-folders/ZenLiveFoldersManager.sys.mjs has 629 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· src/zen/common/modules/ZenUIManager.mjs · ×1
src/zen/common/modules/ZenUIManager.mjs: 627 lines of code src/zen/common/modules/ZenUIManager.mjs:1— src/zen/common/modules/ZenUIManager.mjs has 627 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· src/zen/urlbar/ZenUBActionsProvider.sys.mjs · ×1
src/zen/urlbar/ZenUBActionsProvider.sys.mjs: 564 lines of code src/zen/urlbar/ZenUBActionsProvider.sys.mjs:1— src/zen/urlbar/ZenUBActionsProvider.sys.mjs has 564 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· src/zen/library/ZenLibraryMediaPreview.mjs · ×1
src/zen/library/ZenLibraryMediaPreview.mjs: 541 lines of code src/zen/library/ZenLibraryMediaPreview.mjs:1— src/zen/library/ZenLibraryMediaPreview.mjs has 541 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· src/zen/boosts/ZenZapDissolve.sys.mjs · ×1
src/zen/boosts/ZenZapDissolve.sys.mjs: 534 lines of code src/zen/boosts/ZenZapDissolve.sys.mjs:1— src/zen/boosts/ZenZapDissolve.sys.mjs has 534 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· src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs · ×1
src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs: 533 lines of code src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs:1— src/zen/library/sections/ZenLibrarySpaceRoutingSection.mjs has 533 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· src/zen/boosts/ZenBoostShareDialog.mjs · ×1
src/zen/boosts/ZenBoostShareDialog.mjs: 504 lines of code src/zen/boosts/ZenBoostShareDialog.mjs:1— src/zen/boosts/ZenBoostShareDialog.mjs has 504 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· src/zen/common/sys/ZenPGOTraining.sys.mjs · ×1
src/zen/common/sys/ZenPGOTraining.sys.mjs: 494 lines of code src/zen/common/sys/ZenPGOTraining.sys.mjs:1— src/zen/common/sys/ZenPGOTraining.sys.mjs has 494 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· src/zen/downloads/ZenDownloadAnimation.mjs · ×1
src/zen/downloads/ZenDownloadAnimation.mjs: 475 lines of code src/zen/downloads/ZenDownloadAnimation.mjs:1— src/zen/downloads/ZenDownloadAnimation.mjs has 475 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· src/zen/library/sections/ZenLibraryMediaSection.mjs · ×1
src/zen/library/sections/ZenLibraryMediaSection.mjs: 447 lines of code src/zen/library/sections/ZenLibraryMediaSection.mjs:1— src/zen/library/sections/ZenLibraryMediaSection.mjs has 447 significant lines (blank lines excluded), over the 400-line bar, and contains logic — a file this long is usually several responsibilities in one module.
No typecheck script — test ✓ · lint ✓ · typecheck ✗ — read from this repository's package.json scripts and corroborated against its CI workflows. A script counts when its name or command matches the step: `test` for the suite, `lint` or `prettier` for linting, `typecheck`/`type-check`/`tsc` for type checking. ✗ therefore means no script or CI step under those names was found, NOT that the step is absent from your pipeline — a task invoked by a runner this check does not read, or named something else entirely, is not seen and is worth confirming before acting on a cross. A ✓ means the wiring is DECLARED — a script or CI step under those names exists. It is not a statement that the step passes, or that it runs at all: nothing here installs a dependency or executes a suite.
Dead file (~3750 LoC) src/zen/spaces/ZenSpaceManager.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~2659 LoC) src/zen/split-view/ZenViewSplitter.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~2527 LoC) REDACTED— no import path from any entry point (32 application, 7 tooling, 755 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 (~2434 LoC) src/zen/folders/ZenFolders.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~2248 LoC) src/zen/drag-and-drop/ZenDragAndDrop.js— no import path from any entry point (32 application, 7 tooling, 755 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 (~2163 LoC) src/zen/glance/ZenGlanceManager.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~1804 LoC) src/zen/sessionstore/ZenWindowSync.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~1193 LoC) src/zen/tabs/ZenPinnedTabManager.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~1077 LoC) REDACTED— no import path from any entry point (32 application, 7 tooling, 755 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 (~1075 LoC) src/zen/compact-mode/ZenCompactMode.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~1041 LoC) src/zen/welcome/ZenWelcome.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~983 LoC) src/zen/urlbar/ZenSiteDataPanel.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~966 LoC) src/zen/sync/ZenSpacesSyncApplier.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~880 LoC) src/zen/sync/ZenSpacesSyncModel.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~877 LoC) src/browser/components/preferences/zen-settings.js— no import path from any entry point (32 application, 7 tooling, 755 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 (~830 LoC) src/zen/media/ZenMediaController.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~764 LoC) src/zen/common/modules/ZenVerticalTabsManager.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~752 LoC) src/zen/spaces/ZenSpace.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~737 LoC) REDACTED— no import path from any entry point (32 application, 7 tooling, 755 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 (~723 LoC) src/zen/live-folders/ZenLiveFoldersManager.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~721 LoC) src/zen/migration/ZenMigrationUtils.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~677 LoC) src/zen/common/modules/ZenUIManager.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~592 LoC) src/zen/urlbar/ZenUBActionsProvider.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~581 LoC) src/zen/library/ZenLibraryMediaPreview.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~554 LoC) src/zen/downloads/ZenDownloadAnimation.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~543 LoC) src/zen/common/sys/ZenPGOTraining.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~456 LoC) src/zen/spaces/ZenSpaceCreation.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~428 LoC) src/zen/live-folders/providers/GithubLiveFolder.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~417 LoC) src/zen/urlbar/ZenUrlbarController.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~414 LoC) src/zen/about/zen-about.js— no import path from any entry point (32 application, 7 tooling, 755 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 (~382 LoC) src/zen/urlbar/ZenUBGlobalActions.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~365 LoC) src/zen/library/ZenLibraryDragAndDrop.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~360 LoC) src/zen/common/sys/ZenCustomizableUI.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~344 LoC) src/zen/live-folders/ZenLiveFolder.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~332 LoC) src/zen/spaces/ZenSpacesSwipe.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~331 LoC) src/zen/folders/ZenFolder.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~316 LoC) src/zen/live-folders/providers/RssLiveFolder.sys.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~315 LoC) src/zen/library/sections/ZenLibrarySearchSection.mjs— no import path from any entry point (32 application, 7 tooling, 755 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 (~306 LoC) src/zen/common/emojis/ZenEmojiPicker.mjs— no import path from any entry point (32 application, 7 tooling, 755 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
Unused dependency 'formal-git' — Declared in the root package.json but never imported anywhere in that package or its workspace members — no static import reaches it. Usually that is dead weight and attack surface, but two shapes are indistinguishable from source and are NOT dead: an optional or native peer that another dependency loads dynamically at runtime, and a package a build, docs or test step installs and invokes separately. Confirm which of the three this is before removing it.
`async` callback passed to `forEach` src/zen/boosts/ZenZapOverlayChild.sys.mjs:125— `forEach` ignores what its callback returns, so the Promise each `async` call returns is dropped: nothing can await it, the code after this loop runs before any of the awaited work has finished (a function that `await`s around this loop still returns early), and a rejection is never handled — in Node.js an unhandled rejection terminates the process by default, and in a browser it is lost. Iterate with `for (const item of items) { await … }` when the work must run in order, or `await Promise.all(items.map(async (item) => { … }))` when it may run concurrently, so the enclosing function finishes only when the work does and its failures reach the caller. Where firing and forgetting is genuinely intended, make the callback's whole body a `try { … } catch (e) { … }` that handles the failure, so it cannot escape.
redundant comment src/zen/boosts/ZenBoostsEditor.mjs:1201— "Arc fill path" repeats the code it sits on: 3 of its 3 words (arc, fill, path) are already in `const arcFill = this.doc.createElementNS(NS, "path");`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/boosts/ZenBoostsManager.sys.mjs:795— "Make boost active" repeats the code it sits on: 3 of its 3 words (make, boost, active) are already in `this.makeBoostActiveForDomain(domain, boost.id);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/common/modules/ZenVerticalTabsManager.mjs:612— "Case: single toolbar, compact mode, right side and windows styled buttons" repeats the code it sits on: 9 of its 10 words (single, toolbar, compact, mode, right, side, windows, styled, buttons) are already in `if (`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/downloads/ZenDownloadAnimation.mjs:115— "Create and prepare the arc animation element" repeats the code it sits on: 4 of its 5 words (create, arc, animation, element) are already in `const arcAnimationElement = this.#createArcAnimationElement(startPosition);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/downloads/ZenDownloadAnimation.mjs:134— "Start the download animation" repeats the code it sits on: 3 of its 3 words (start, download, animation) are already in `await this.#startDownloadAnimation(`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/folders/ZenFolders.mjs:2097— "Await the tab unload animation first" repeats the code it sits on: 4 of its 5 words (await, tab, unload, animation) are already in `await Promise.all(tabUnloadAnimations);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment REDACTED:275— "ignore errors reading backup files" repeats the code it sits on: 4 of its 5 words (errors, reading, backup, files) are already in `console.error(`Failed to read backup file ${backupFile}`, e);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/spaces/ZenSpaceManager.mjs:2760— "Update workspace indicator" repeats the code it sits on: 3 of its 3 words (update, workspace, indicator) are already in `await this.updateWorkspaceIndicator(workspace, this.workspaceIndicator);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/split-view/ZenViewSplitter.mjs:1504— "Add tabs to the split view group" repeats the code it sits on: 4 of its 5 words (tabs, split, view, group) are already in `let splitGroup = this._getSplitViewGroup(tabs, groupFetchId);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/pageinfo/browser_pageinfo_permissions.js:311— "Selecting the allow radio sets the ALLOW exception." repeats the code it sits on: 4 of its 5 words (selecting, allow, radio, sets) are already in `radioGroup.selectedItem = allowRadioButton;`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/pageinfo/browser_pageinfo_security.js:371— "Add some test cookies." repeats the code it sits on: 3 of its 3 words (add, test, cookies) are already in `SiteDataTestUtils.addToCookies({`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/readermode/browser_readerMode_customColorScheme.js:16— "Set the custom pref to the color value." repeats the code it sits on: 4 of its 5 words (set, custom, pref, color) are already in `Services.prefs.setCharPref(`reader.custom_colors.${aPref}`, color);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/remote-settings/test_remote_settings.js:33— "Set up an HTTP Server" repeats the code it sits on: 3 of its 3 words (set, http, server) are already in `server = new HttpServer();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/remote-settings/test_remote_settings_older_than_local.js:20— "Set up an HTTP Server" repeats the code it sits on: 3 of its 3 words (set, http, server) are already in `server = new HttpServer();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/remote-settings/test_remote_settings_poll.js:40— "Clear sync history." repeats the code it sits on: 3 of its 3 words (clear, sync, history) are already in `await new SyncHistory("").clear();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/remote-settings/test_remote_settings_poll.js:60— "Set up an HTTP Server" repeats the code it sits on: 3 of its 3 words (set, http, server) are already in `server = new HttpServer();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/remote-settings/test_remote_settings_recover_broken.js:18— "Clear sync history." repeats the code it sits on: 3 of its 3 words (clear, sync, history) are already in `await new SyncHistory("").clear();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/remote-settings/test_remote_settings_recover_broken.js:48— "Set up an HTTP Server" repeats the code it sits on: 3 of its 3 words (set, http, server) are already in `server = new HttpServer();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/remote-settings/test_remote_settings_signatures.js:38— "Set up an HTTP Server" repeats the code it sits on: 3 of its 3 words (set, http, server) are already in `server = new HttpServer();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/remote-settings/test_remote_settings_signatures.js:231— "set the server date" repeats the code it sits on: 3 of its 3 words (set, server, date) are already in `response.setHeader("Date", new Date(serverTimeMillis).toUTCString());`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/safebrowsing/browser_whitelisted.js:47— "Wait for AboutBlockedLoaded event" repeats the code it sits on: 4 of its 4 words (wait, blocked, loaded, event) are already in `let blockedLoaded = BrowserTestUtils.waitForContentEvent(`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/scroll-to-text-fragment/browser_scroll-to-text-fragment-from-browser-chrome.js:20— "Define the cross-origin URL with the text fragment" repeats the code it sits on: 5 of its 6 words (cross, origin, url, text, fragment) are already in `let crossOriginUrl = `https://example.org/browser/browser/base/content/test/browser-scroll-to-text-fragment/scroll-to-te …`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/scroll-to-text-fragment/browser_scroll-to-text-fragment-from-browser-chrome.js:42— "Wait for the cross-origin page to load completely" repeats the code it sits on: 5 of its 6 words (wait, cross, origin, page, load) are already in `info("Waiting for cross-origin page to load...");`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/sessionstore/SessionStoreTestUtils.sys.mjs:192— "Finally, call setBrowserState" repeats the code it sits on: 4 of its 5 words (call, set, browser, state) are already in `lazy.SessionStore.setBrowserState(JSON.stringify(aState));`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment src/zen/tests/mochitests/sessionstore/browser_248970_b_perwindowpb.js:102— "get closed tab count" repeats the code it sits on: 4 of its 4 words (get, closed, tab, count) are already in `let count = ss.getClosedTabCountForWindow(aWin);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
Silent fallback default in catch scripts/build_tokens.mjs:55— `read` 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 src/zen/about/zen-about.js:148— `manualUpdateURL` 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 src/zen/boosts/actors/ZenBoostsChild.sys.mjs:276— `#matchingFocusSelectors` swallows every exception into `return false` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
Silent fallback default in catch src/zen/library/ZenLibraryMediaPreview.mjs:466— `#openerName` 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 src/zen/share/ZenShareManager.mjs:263— `#serializeIcon` 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 src/zen/sync/ZenSpacesSyncModel.sys.mjs:88— `syncableIconUrl` 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 src/zen/tests/mochitests/remote-settings/test_remote_settings_dump_lastmodified.js:9— `getLocalDumpLastModified` swallows every exception into `return -1` — 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 src/zen/urlbar/ZenSiteDataPanel.sys.mjs:130— `#getCurrentDomain` 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 src/zen/urlbar/ZenSiteDataPanel.sys.mjs:524— `#setSitePermissions` swallows every exception into `return false` — a data error becomes a silent behavior change with no trail. Log the failure or let it raise. If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment on the handler or in the docstring, and the row stops firing.
Duplicated predicate src/zen/library/ZenLibraryWidget.sys.mjs:302— `!download.stopped && !!download.launchWhenSucceeded` appears character-identically in 2 files — src/zen/library/ZenLibraryWidget.sys.mjs, src/zen/library/sections/ZenLibraryDownloadsSection.mjs. 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 src/zen/boosts/ZenSelectorComponent.sys.mjs:165— `!this.#content || Cu.isDeadWrapper(this.#content)` appears character-identically in 2 files — src/zen/boosts/ZenSelectorComponent.sys.mjs, src/zen/boosts/ZenZapDissolve.sys.mjs. 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 src/zen/library/ZenLibraryWidget.sys.mjs:598— `download.canceled && download.hasPartialData` appears character-identically in 2 files — src/zen/library/ZenLibraryWidget.sys.mjs, src/zen/library/sections/ZenLibraryDownloadsSection.mjs. 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 src/zen/library/ZenLibraryWidget.sys.mjs:543— `download.succeeded && download.target.path` appears character-identically in 2 files — src/zen/library/ZenLibraryWidget.sys.mjs, src/zen/library/sections/ZenLibraryDownloadsSection.mjs. 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 src/zen/library/ZenLibraryWidget.sys.mjs:585— `parsed && Services.io.newURI(parsed.href)` appears character-identically in 2 files — src/zen/library/ZenLibraryWidget.sys.mjs, src/zen/library/sections/ZenLibraryDownloadsSection.mjs. 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 src/zen/common/modules/ZenSessionStore.mjs:29— `tabData.zenSyncId || tabData.zenPinnedId` appears character-identically in 2 files — src/zen/common/modules/ZenSessionStore.mjs, REDACTED. 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 src/zen/spaces/ZenSpaceIcons.mjs:9— `this.delayConnectedCallback() || this.#hasConnected` appears character-identically in 2 files — src/zen/spaces/ZenSpaceIcons.mjs, src/zen/tabs/ZenEssentialsPromo.mjs. 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.
Orphaned file src/zen/live-folders/ZenLiveFolder.sys.mjs:1— No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
Orphaned file scripts/copy_language_pack.py:1— No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
Orphaned file scripts/check_rc_response.py:1— No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
Orphaned file scripts/prepare-flatpak-release.py:1— No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
Subsumed condition operand tools/eslint-plugin-spidermonkey-js/lib/environments/self-hosted.js:83— `line.startsWith("function*")` can never decide this `||` — every value satisfying `line.startsWith("function*")` also satisfies `line.startsWith("function")`, 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 tools/eslint-plugin-spidermonkey-js/lib/environments/self-hosted.js:85— `line.startsWith("async function*")` can never decide this `||` — every value satisfying `line.startsWith("async function*")` also satisfies `line.startsWith("async function")`, 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 src/zen/glance/ZenGlanceManager.mjs:1725— `urlSpec.startsWith("https")` can never decide this `||` — every value satisfying `urlSpec.startsWith("https")` also satisfies `urlSpec.startsWith("http")`, 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.
Off-boarding risk: anonymized user #1 — If anonymized user #1 becomes unavailable, 16 significant file(s) lose their only recent owner: src/zen/sync/ZenSpacesSyncApplier.sys.mjs, src/zen/share/ZenShareManager.mjs, src/zen/sync/ZenSpacesSyncModel.sys.mjs, src/zen/boosts/ZenSelectorComponent.sys.mjs, src/zen/library/sections/ZenLibraryMediaSection.mjs, src/zen/share/ZenShareClient.sys.mjs, src/zen/library/sections/ZenLibraryBoostsSection.mjs, src/zen/library/sections/ZenLibrarySearchSection.mjs (+8 more). Pair on, review, or document these before any departure.
D16 · Bus Factor· Further sole-owners (lower concentration) · ×1
Further sole-owners (lower concentration) — 1 other contributor(s) are each the sole owner of a small amount of code below the off-boarding threshold — folded into the bus-factor score and metrics (17 single-owned of 99 analysed files in total, counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated, example/demo and scaffolding-template trees and test files identified by path convention, largest first; 99 of the 119 production source files in this repository met that bar). They are anonymized user #2 (1 file(s)) — spread or document their files in the same way, at lower priority than the named off-boarding risks above. The files folded here: src/zen/common/modules/ZenToasts.mjs.
No ADRs found package.json:12— No ADRs found. No recognised ADR directory (`docs/adr/`, `docs/decisions/`, `adr/`, `docs/rfcs/`, an `ADR0001/` folder, or their siblings) exists anywhere in this tree. What was searched, so you can tell an empty log from a search that missed one: every directory under the tree (build output, dependencies and VCS metadata excepted), for a document that is either any non-index page inside a recognised ADR directory, whatever its name and however deeply nested (`docs/adr/use-postgres.md`, `docs/adr/2024/0001-x.md`); or a file anywhere whose name is ADR-shaped (`0001-use-postgres.md`, `adr-012-caching.md`); or, when neither turned anything up, a document carrying the decision-record signature (an "Architecture Decision Record" heading, or Status / Context / Decision / Consequences as section headings). A decision log that clears none of these — unnumbered files outside any recognised directory, without those headings — is not seen by this check and this row is then wrong. If that is your case, say so rather than renaming anything; otherwise, consider recording architectural decisions in `docs/adr/`. ADRs are expected here because `package.json` makes this repository a deployable product (line 12).
D26 · Project Cohesion· Projects may be oversized for their cohesion · ×1
Projects may be oversized for their cohesion — 1 of 3 project(s) overshoot their size bounds, lowering Project Cohesion to 3.3/10. The most over is `(repository root)` (55059 LoC, 110 module-visible types across 31 directories). Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
D34 · Knowledge Freshness· Orphaned files with no living knowledge · ×1
Orphaned files with no living knowledge — 4 of 99 analysed file(s) have no living knowledge left — their last meaningful change has decayed away, so if one breaks, no one currently understands it (counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated, example/demo and scaffolding-template trees and test files identified by path convention, largest first; 99 of the 119 production source files in this repository met that bar). None is large enough to earn a read-through of its own, so this row stands in for the per-file rows rather than raising one each — most significant first: src/zen/live-folders/ZenLiveFolder.sys.mjs, scripts/copy_language_pack.py, scripts/check_rc_response.py, scripts/prepare-flatpak-release.py. Attach the read to the next change that touches one of them: have a second person review that change, and leave behind a short comment or test recording what the file is for, so the knowledge comes back at the cost of a change you were making anyway.
No ADRs — No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
No SAST REDACTED:7— No static application security testing detected. For this repository's stack, add CodeQL's Swift pack (Swift/Xcode) (or `semgrep --config=auto`, which runs on any language) as a CI step. What was searched, so you can tell an absence from a miss: the 16 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
No dependency-update automation package.json:51— `package.json` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`.
X2 · Cancellation propagation· Not all async functions that make a request accept an AbortSignal · ×1
Not all async functions that make a request accept an AbortSignal — Only 1/5 async functions that make a cancellable request (fetch, axios, ky, ofetch, got, undici, node:http) accept an AbortSignal or pass one on, so a request keeps running after whatever wanted it has given up — a page navigated away from, an unmounted component, a timed-out job. Take a `signal` (or an options object that carries one) and hand it to the request; where nothing could ever cancel the call, omitting it is a deliberate choice — judge against how the function is used.
Outdated: serde — `serde` is locked at 1.0.219 but 1.0.229 is the current stable release on crates.io, and it already satisfies the `"1.0.104"` requirement declared in tools/ffprefs/Cargo.toml — so the lockfile is behind this repository's own declared range. Run `cargo update -p serde` and commit the updated REDACTED.
doc comments repeat the names src/zen/boosts/ZenBoostsEditor.mjs:29— 60 of 823 documented parameters and 38 of 855 summaries in `zen-desktop` only repeat the member or parameter name (e.g. "The window object for the editor." for `editorWindow`). 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 2 file(s) — `src/zen/@types/index.d.ts`, `src/zen/@types/lib.gecko.tweaks.d.ts` — 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 01a1d604-d92b-7324-aa10-ec5746f75060 · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.
Issues: 200 · Warnings: 630 · Recommendations: 100 · Info: 2 — Appendix A · all findings · full markdown report.
Generated by the Canine Code Analyzer: deterministic code-health analysis. 13-11-2026 @ 17:46 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.