Public report — dotnet-starter-kit, published 21 Sep 2026.
Concrete security findings (which rule fired, in which file, on which line; CVE IDs, secret matches,
dependency versions) are REDACTED in this version; ask the repo owner for the full report.
Public
Codebase surveyMeasured under the Code Assurance Index · rubric rubric-2026.09.15 (frozen) · verify this surveyFiledcd_09e43ff847024ffdbbc61e8143373269
Filed 25 September 2026, 05:09 UTC
Public
REDACTED · 97,855 LoC · 50 projects · rebuild ~2.5 person-years · weakest lens: Code Health (53%)
Findings by grade
205 critical578 serious199 minor5 could not be resolved — could be critical — see Limitations
This survey was produced by
Watchdog
Producer
Canine Development
Analyzer
Watchdog engine 1.0.0
Measured
21 September 2026, 10:37 UTC
A measurement, not a certificate. The Code Assurance Index does not certify,
approve or guarantee this codebase; it records a reproducible number and the evidence it was computed from. The
standard is authored by Canine Development, who also build Watchdog — its only implementation today. That is said
here so the number is checked rather than believed.
Grounded in facts. Every number here is computed, not narrated — reproducible, tool-backed, and traceable to a line of code. How to trust this ▸
927findings with an exact file:lineof 982 — the remainder are repo-wide signals (a dimension-level measurement, not a single line); open any file:line and verify
118/145dimensions across the health lenses97855 LoC · 50 projects — wide & deep
⚠ A critical security finding caps this grade — resolve it before relying on the score below; see the Security lens.
Template / example. This repo declares itself a template, kata, sample or demo — code to read or copy, not operate — so the ship-it and operate-it dimensions (CI/CD, observability, ADRs, architecture docs, deployment security) are N/A and what remains is judged accordingly.
The platform is a medium-sized, workable system carrying significant hidden risk, reflected in an overall health score of 62%. While the architecture is robust and event-driven patterns are mature, the codebase suffers from poor maintainability that threatens delivery speed and long-term cost efficiency. With nearly 100,000 lines of production code and a rebuild cost of approximately €360,000, the asset holds substantial value, but its current state requires immediate attention to prevent escalating technical debt.
The primary concern is fragile code health, which sits at only 53%. This weakness creates a velocity tax on every change, plausibly increasing effort by 2–5% across the 616,000 lines modified annually. The root cause is an un-encapsulated domain layer, where 41 findings related to public setters and weak type protection indicate the business logic does not safeguard its own invariants. This lack of discipline leads to ripple effects during updates, increasing the likelihood of defects and extending release cycles. Addressing this encapsulation issue resolves multiple findings simultaneously, offering high leverage for stabilizing the core business rules.
A secondary, high-impact risk lies in unchecked explicit debt, specifically 66 suppressed warnings in critical modules like Eventing, Billing, and Auditing. These suppressions mask potential issues and reduce visibility into code quality. Resolving these warnings is the highest-leverage action available, as the one-time effort of a few engineer-days pays for itself within months by reducing the annual drag on development. Ignoring this debt costs significantly more in cumulative delays and maintenance overhead. While the system’s architecture and event-driven design are strong points, they cannot compensate for the underlying code rot in the domain layer.
The system’s strengths include a solid architectural foundation and mature event-driven processes, which provide a stable backbone for future growth. However, the low code health score means these strengths are underutilized. The team should focus first on resolving the suppressed warnings in the billing and eventing modules, as this action offers the fastest return on investment. This step stabilizes the development environment and reveals hidden issues, enabling more accurate planning. Confidence in this assessment is high, though event sourcing metrics were not measured, leaving a small gap in the full picture. Prioritizing these quick wins will immediately improve delivery predictability and reduce long-term maintenance costs.
How the score is built — each lens's share of the headlineWidth is the lens's weight in the worst-heaviest fold (the weakest area pulls hardest); colour is that lens's own band. A lens fixes the score in proportion to its width.
0.8× (at 62% quality) — the last 20% of quality is most of the work
Size & shape
REDACTED · effort split not classified for 55,064 line(s) outside the .NET model (the tier breakdown is a C#-only syntax walk)
Dead frontend code
~364 LoC unreachable (9 file(s)) — that slice of this estimate buys code with zero runtime value; deleting it is the cheapest win in this report (the R7 card lists every file)
This codebase represents roughly ~2.5 person-years of build effort (about ~€360,000 to rebuild). Its weakest lens is Code Health at 53% — the part of that asset most exposed by the findings below.
How we model this: boilerplate at a scaffolding rate + logic × domain Very high (×2.2) — microservices, DDD/clean architecture, CQRS, domain model, event-driven integration × a 0.8× quality factor, at €60–95/h; indicative, ±~30% · size measured directly from source. Indicative only — most sensitive to the hourly rate and the domain tier (both tunable in config).
Top priorities
The highest-leverage moves; the full ranked list is in the Roadmap below.
1
Resolve the 66 NoWarnInCsproj finding(s) in Explicit Debt — start with Eventing.csproj (5), Modules.Billing.csproj (5), Modules.Auditing.csproj (5).
The top fix pays for itself · REDACTED · Economics
The top-ranked fix costs roughly 3–10 engineer-days once. Not doing it costs about 32.8–205.6 engineer-days every year, paid as drag on the ~616,886 lines this team changes annually — a bill that arrives whether or not anyone books it. On those figures the fix breaks even in roughly 1–4 months and is free after that. Method, stated so this is not read as a quotation: debt from the ranked task's effort band; interest = annual changed lines (measured, annualised from the 90-day window) ÷ an ASSUMED 150–400 lines per engineer-day × the 2–5% drag implied by the code-quality signals; breaking point = debt ÷ annual interest. A modelled planning range built from measured inputs and one named assumption — not a quotation, a valuation, or a certified figure.
Evidence: D15 churn: 152,109 line(s) changed over a 90-day window ⇒ ~616,886/year · D1/D2/D4 code quality: averaging 7.1/10 ⇒ a 2–5% drag on each change · top-ranked remediation: REDACTED effort ⇒ about 3–10 engineer-day(s)
→ Do the top-ranked fix now if this code will still be yours in 4 months.
Value concentrated against a weak lens · REDACTED · Value at risk
This is a REDACTED asset (~2.5 person-years to rebuild), and its weakest lens is Code Health at 53%. The operational and business risk on an asset this size concentrates there — that's where remediation buys the most protection.
→ Direct remediation budget at Code Health first — highest risk-reduction per euro on an asset this size.
Root cause: an un-encapsulated domain · REDACTED · Root cause
41 findings across public setters, anemic types and primitive ids share one root cause — the domain layer doesn't protect its own invariants. Fixing the encapsulation pattern resolves them together, rather than chasing each finding.
→ Address encapsulation as one pattern (private setters + behaviour + strongly-typed ids), not 100 separate findings.
Highest-leverage move · REDACTED · Leverage
Of everything flagged, the best return on effort is: Resolve the 66 NoWarnInCsproj finding(s) in Explicit Debt — start with Eventing.csproj (5), Modules.Billing.csproj (5), Modules.Auditing.csproj (5). The rest can wait behind it.
Evidence: priority ranking: top of 5 ranked by impact/effort
→ Resolve the 66 NoWarnInCsproj finding(s) in Explicit Debt — start with Eventing.csproj (5), Modules.Billing.csproj (5), Modules.Auditing.csproj (5).
A velocity tax on every change · REDACTED · Economics
The code-quality signals (complexity, duplication, cohesion) average 7.1/10, which acts as a tax on every change in the weaker areas: modifications there plausibly cost on the order of 2–5% more than in clean code, and the tax compounds as the codebase grows. (A modelled estimate, not a measured fact.)
Evidence: D1/D2/D4 code quality: averaging 7.1/10 across the code-quality signals actually measured
→ Pay it down where churn is highest — the hotspots — not everywhere; that's where the tax is actually paid.
Architecture — bounded-context dependency graph
Each box is a bounded context (its layer projects grouped, or a project count when large); arrows show dependencies between contexts. A shared kernel is where many arrows converge.
Architecture — module dependency matrix
Rows and columns are the same modules, ordered so that a module only depends on ones above it. A cell means the row depends on the column, and its number is how many type pairs create that dependency. Read one thing: is anything above the diagonal? A mark there is a dependency cycle. (A cycle is all this shows — an unusual but cycle-free dependency sits below the diagonal like any other.)
577 modules, 1125 dependencies. 5 dependency cycles across 11 modules, marked above the diagonal.
Showing the 40 most-connected modules; 537 more are not drawn.
Module dependency matrix. The row depends on the column; the number is how many type pairs create the dependency. A cell above the diagonal is part of a dependency cycle.
FSH.Framework.Persistence uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Framework.Persistence, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
21→5 FSH.Framework.Persistence.Context depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
1 distinct (type in FSH.Framework.Persistence.Context → type in FSH.Framework.Shared.Multitenancy) reference.
FSH.Framework.Persistence.Context uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Framework.Persistence.Context, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
21→6 FSH.Framework.Persistence.Context depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Framework.Persistence.Context → type in FSH.Framework.Shared.Persistence) reference.
FSH.Framework.Persistence.Context uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Framework.Persistence.Context, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
22→10 FSH.Modules.Auditing.Contracts.Dtos depends on FSH.Modules.Auditing.Contracts✕
Type pairs
8 distinct (type in FSH.Modules.Auditing.Contracts.Dtos → type in FSH.Modules.Auditing.Contracts) references.
FSH.Modules.Auditing.Contracts.Dtos uses FSH.Modules.Auditing.Contracts. Changing FSH.Modules.Auditing.Contracts can break FSH.Modules.Auditing.Contracts.Dtos, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
23→1 FSH.Modules.Identity.Contracts.Services depends on FSH.Framework.Core.Context✕
Type pairs
3 distinct (type in FSH.Modules.Identity.Contracts.Services → type in FSH.Framework.Core.Context) references.
FSH.Modules.Identity.Contracts.Services uses FSH.Framework.Core.Context. Changing FSH.Framework.Core.Context can break FSH.Modules.Identity.Contracts.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
23→6 FSH.Modules.Identity.Contracts.Services depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Identity.Contracts.Services → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Identity.Contracts.Services uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Identity.Contracts.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
23→17 FSH.Modules.Identity.Contracts.Services depends on FSH.Modules.Identity.Contracts.DTOs✕
Type pairs
8 distinct (type in FSH.Modules.Identity.Contracts.Services → type in FSH.Modules.Identity.Contracts.DTOs) references.
FSH.Modules.Identity.Contracts.Services uses FSH.Modules.Identity.Contracts.DTOs. Changing FSH.Modules.Identity.Contracts.DTOs can break FSH.Modules.Identity.Contracts.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
24→2 FSH.Modules.Identity.Domain depends on FSH.Framework.Core.Domain✕
Type pairs
7 distinct (type in FSH.Modules.Identity.Domain → type in FSH.Framework.Core.Domain) references.
FSH.Modules.Multitenancy.Contracts uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Multitenancy.Contracts, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
25→6 FSH.Modules.Multitenancy.Contracts depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Multitenancy.Contracts → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Multitenancy.Contracts uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Multitenancy.Contracts, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
25→18 FSH.Modules.Multitenancy.Contracts depends on FSH.Modules.Multitenancy.Contracts.Dtos✕
Type pairs
3 distinct (type in FSH.Modules.Multitenancy.Contracts → type in FSH.Modules.Multitenancy.Contracts.Dtos) references.
FSH.Modules.Multitenancy.Contracts uses FSH.Modules.Multitenancy.Contracts.Dtos. Changing FSH.Modules.Multitenancy.Contracts.Dtos can break FSH.Modules.Multitenancy.Contracts, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
26→19 FSH.Modules.Tickets.Contracts.v1.Tickets depends on FSH.Modules.Tickets.Contracts.Dtos✕
Type pairs
4 distinct (type in FSH.Modules.Tickets.Contracts.v1.Tickets → type in FSH.Modules.Tickets.Contracts.Dtos) references.
FSH.Modules.Tickets.Contracts.v1.Tickets uses FSH.Modules.Tickets.Contracts.Dtos. Changing FSH.Modules.Tickets.Contracts.Dtos can break FSH.Modules.Tickets.Contracts.v1.Tickets, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
27→5 FSH.Modules.Auditing.Persistence depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
1 distinct (type in FSH.Modules.Auditing.Persistence → type in FSH.Framework.Shared.Multitenancy) reference.
FSH.Modules.Auditing.Persistence uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Auditing.Persistence, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
27→6 FSH.Modules.Auditing.Persistence depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Auditing.Persistence → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Auditing.Persistence uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Auditing.Persistence, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
27→10 FSH.Modules.Auditing.Persistence depends on FSH.Modules.Auditing.Contracts✕
Type pairs
13 distinct (type in FSH.Modules.Auditing.Persistence → type in FSH.Modules.Auditing.Contracts) references.
FSH.Modules.Auditing.Persistence uses FSH.Modules.Auditing.Contracts. Changing FSH.Modules.Auditing.Contracts can break FSH.Modules.Auditing.Persistence, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
27→20 FSH.Modules.Auditing.Persistence depends on FSH.Framework.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Auditing.Persistence → type in FSH.Framework.Persistence) reference.
FSH.Modules.Auditing.Persistence uses FSH.Framework.Persistence. Changing FSH.Framework.Persistence can break FSH.Modules.Auditing.Persistence, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
27→21 FSH.Modules.Auditing.Persistence depends on FSH.Framework.Persistence.Context✕
Type pairs
1 distinct (type in FSH.Modules.Auditing.Persistence → type in FSH.Framework.Persistence.Context) reference.
FSH.Modules.Auditing.Persistence uses FSH.Framework.Persistence.Context. Changing FSH.Framework.Persistence.Context can break FSH.Modules.Auditing.Persistence, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
28→20 FSH.Modules.Billing.Data depends on FSH.Framework.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Billing.Data → type in FSH.Framework.Persistence) reference.
FSH.Modules.Catalog.Data uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Catalog.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
29→6 FSH.Modules.Catalog.Data depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Catalog.Data → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Catalog.Data uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Catalog.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
29→20 FSH.Modules.Catalog.Data depends on FSH.Framework.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Catalog.Data → type in FSH.Framework.Persistence) reference.
FSH.Modules.Catalog.Data uses FSH.Framework.Persistence.Context. Changing FSH.Framework.Persistence.Context can break FSH.Modules.Catalog.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
30→5 FSH.Modules.Chat.Data depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
1 distinct (type in FSH.Modules.Chat.Data → type in FSH.Framework.Shared.Multitenancy) reference.
FSH.Modules.Chat.Data uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Chat.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
30→6 FSH.Modules.Chat.Data depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Chat.Data → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Chat.Data uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Chat.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
30→20 FSH.Modules.Chat.Data depends on FSH.Framework.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Chat.Data → type in FSH.Framework.Persistence) reference.
FSH.Modules.Chat.Data uses FSH.Framework.Persistence.Context. Changing FSH.Framework.Persistence.Context can break FSH.Modules.Chat.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
31→5 FSH.Modules.Files.Data depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
1 distinct (type in FSH.Modules.Files.Data → type in FSH.Framework.Shared.Multitenancy) reference.
FSH.Modules.Files.Data uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Files.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
31→6 FSH.Modules.Files.Data depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Files.Data → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Files.Data uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Files.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
31→20 FSH.Modules.Files.Data depends on FSH.Framework.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Files.Data → type in FSH.Framework.Persistence) reference.
FSH.Modules.Files.Data uses FSH.Framework.Persistence.Context. Changing FSH.Framework.Persistence.Context can break FSH.Modules.Files.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
32→4 FSH.Modules.Identity.Data depends on FSH.Framework.Shared.Constants✕
Type pairs
1 distinct (type in FSH.Modules.Identity.Data → type in FSH.Framework.Shared.Constants) reference.
FSH.Modules.Identity.Data uses FSH.Framework.Shared.Constants. Changing FSH.Framework.Shared.Constants can break FSH.Modules.Identity.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
32→5 FSH.Modules.Identity.Data depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
3 distinct (type in FSH.Modules.Identity.Data → type in FSH.Framework.Shared.Multitenancy) references.
FSH.Modules.Identity.Data uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Identity.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
32→6 FSH.Modules.Identity.Data depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Identity.Data → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Identity.Data uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Identity.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
32→20 FSH.Modules.Identity.Data depends on FSH.Framework.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Identity.Data → type in FSH.Framework.Persistence) reference.
FSH.Modules.Multitenancy.Provisioning uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Multitenancy.Provisioning, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
33→18 FSH.Modules.Multitenancy.Provisioning depends on FSH.Modules.Multitenancy.Contracts.Dtos✕
Type pairs
2 distinct (type in FSH.Modules.Multitenancy.Provisioning → type in FSH.Modules.Multitenancy.Contracts.Dtos) references.
FSH.Modules.Multitenancy.Provisioning uses FSH.Modules.Multitenancy.Contracts.Dtos. Changing FSH.Modules.Multitenancy.Contracts.Dtos can break FSH.Modules.Multitenancy.Provisioning, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
33→25 FSH.Modules.Multitenancy.Provisioning depends on FSH.Modules.Multitenancy.Contracts✕
Type pairs
1 distinct (type in FSH.Modules.Multitenancy.Provisioning → type in FSH.Modules.Multitenancy.Contracts) reference.
FSH.Modules.Multitenancy.Provisioning uses FSH.Modules.Multitenancy.Contracts. Changing FSH.Modules.Multitenancy.Contracts can break FSH.Modules.Multitenancy.Provisioning, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
34→5 FSH.Modules.Tickets.Data depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
1 distinct (type in FSH.Modules.Tickets.Data → type in FSH.Framework.Shared.Multitenancy) reference.
FSH.Modules.Tickets.Data uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Tickets.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
34→6 FSH.Modules.Tickets.Data depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Tickets.Data → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Tickets.Data uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Tickets.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
34→20 FSH.Modules.Tickets.Data depends on FSH.Framework.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Tickets.Data → type in FSH.Framework.Persistence) reference.
FSH.Modules.Tickets.Data uses FSH.Framework.Persistence.Context. Changing FSH.Framework.Persistence.Context can break FSH.Modules.Tickets.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
35→5 FSH.Modules.Webhooks.Data depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
1 distinct (type in FSH.Modules.Webhooks.Data → type in FSH.Framework.Shared.Multitenancy) reference.
FSH.Modules.Webhooks.Data uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Webhooks.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
35→6 FSH.Modules.Webhooks.Data depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Webhooks.Data → type in FSH.Framework.Shared.Persistence) reference.
FSH.Modules.Webhooks.Data uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Webhooks.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
35→20 FSH.Modules.Webhooks.Data depends on FSH.Framework.Persistence✕
Type pairs
1 distinct (type in FSH.Modules.Webhooks.Data → type in FSH.Framework.Persistence) reference.
FSH.Modules.Webhooks.Data uses FSH.Framework.Persistence.Context. Changing FSH.Framework.Persistence.Context can break FSH.Modules.Webhooks.Data, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
36→6 Mediator.Internals depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in Mediator.Internals → type in FSH.Framework.Shared.Persistence) reference.
Mediator.Internals uses FSH.Modules.Catalog.Contracts.v1.Products. Changing FSH.Modules.Catalog.Contracts.v1.Products can break Mediator.Internals, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
36→14 Mediator.Internals depends on FSH.Modules.Chat.Contracts.v1.Commands✕
Type pairs
15 distinct (type in Mediator.Internals → type in FSH.Modules.Chat.Contracts.v1.Commands) references.
Mediator.Internals uses FSH.Modules.Chat.Contracts.v1.Commands. Changing FSH.Modules.Chat.Contracts.v1.Commands can break Mediator.Internals, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
36→15 Mediator.Internals depends on FSH.Modules.Chat.Contracts.v1.DTOs✕
Type pairs
2 distinct (type in Mediator.Internals → type in FSH.Modules.Chat.Contracts.v1.DTOs) references.
Mediator.Internals uses FSH.Modules.Files.Contracts.v1.DTOs. Changing FSH.Modules.Files.Contracts.v1.DTOs can break Mediator.Internals, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
36→17 Mediator.Internals depends on FSH.Modules.Identity.Contracts.DTOs✕
Type pairs
9 distinct (type in Mediator.Internals → type in FSH.Modules.Identity.Contracts.DTOs) references.
Mediator.Internals uses FSH.Modules.Identity.Contracts.DTOs. Changing FSH.Modules.Identity.Contracts.DTOs can break Mediator.Internals, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
36→18 Mediator.Internals depends on FSH.Modules.Multitenancy.Contracts.Dtos✕
Type pairs
6 distinct (type in Mediator.Internals → type in FSH.Modules.Multitenancy.Contracts.Dtos) references.
Mediator.Internals uses FSH.Modules.Multitenancy.Contracts.Dtos. Changing FSH.Modules.Multitenancy.Contracts.Dtos can break Mediator.Internals, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
36→19 Mediator.Internals depends on FSH.Modules.Tickets.Contracts.Dtos✕
Type pairs
2 distinct (type in Mediator.Internals → type in FSH.Modules.Tickets.Contracts.Dtos) references.
Mediator.Internals uses FSH.Modules.Auditing.Contracts.Dtos. Changing FSH.Modules.Auditing.Contracts.Dtos can break Mediator.Internals, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
36→26 Mediator.Internals depends on FSH.Modules.Tickets.Contracts.v1.Tickets✕
Type pairs
13 distinct (type in Mediator.Internals → type in FSH.Modules.Tickets.Contracts.v1.Tickets) references.
Mediator.Internals uses FSH.Modules.Tickets.Contracts.v1.Tickets. Changing FSH.Modules.Tickets.Contracts.v1.Tickets can break Mediator.Internals, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
36→40 Mediator.Internals depends on Mediatorcycle✕
Type pairs
16 distinct (type in Mediator.Internals → type in Mediator) references.
FSH.Modules.Billing.Services uses FSH.Framework.Eventing.Abstractions. Changing FSH.Framework.Eventing.Abstractions can break FSH.Modules.Billing.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
37→5 FSH.Modules.Billing.Services depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
2 distinct (type in FSH.Modules.Billing.Services → type in FSH.Framework.Shared.Multitenancy) references.
FSH.Modules.Billing.Services uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Billing.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
37→11 FSH.Modules.Billing.Services depends on FSH.Modules.Billing.Contracts.Dtos✕
Type pairs
2 distinct (type in FSH.Modules.Billing.Services → type in FSH.Modules.Billing.Contracts.Dtos) references.
FSH.Modules.Billing.Services uses FSH.Modules.Billing.Contracts.Dtos. Changing FSH.Modules.Billing.Contracts.Dtos can break FSH.Modules.Billing.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
37→28 FSH.Modules.Billing.Services depends on FSH.Modules.Billing.Data✕
Type pairs
2 distinct (type in FSH.Modules.Billing.Services → type in FSH.Modules.Billing.Data) references.
FSH.Modules.Identity.Services uses FSH.Framework.Core.Context. Changing FSH.Framework.Core.Context can break FSH.Modules.Identity.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
38→5 FSH.Modules.Identity.Services depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
7 distinct (type in FSH.Modules.Identity.Services → type in FSH.Framework.Shared.Multitenancy) references.
FSH.Modules.Identity.Services uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Identity.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
38→7 FSH.Modules.Identity.Services depends on FSH.Framework.Storage.Services✕
Type pairs
1 distinct (type in FSH.Modules.Identity.Services → type in FSH.Framework.Storage.Services) reference.
FSH.Modules.Identity.Services uses FSH.Framework.Storage.Services. Changing FSH.Framework.Storage.Services can break FSH.Modules.Identity.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
38→10 FSH.Modules.Identity.Services depends on FSH.Modules.Auditing.Contracts✕
Type pairs
1 distinct (type in FSH.Modules.Identity.Services → type in FSH.Modules.Auditing.Contracts) reference.
FSH.Modules.Identity.Services uses FSH.Modules.Auditing.Contracts. Changing FSH.Modules.Auditing.Contracts can break FSH.Modules.Identity.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
38→17 FSH.Modules.Identity.Services depends on FSH.Modules.Identity.Contracts.DTOs✕
Type pairs
7 distinct (type in FSH.Modules.Identity.Services → type in FSH.Modules.Identity.Contracts.DTOs) references.
FSH.Modules.Identity.Services uses FSH.Modules.Identity.Contracts.DTOs. Changing FSH.Modules.Identity.Contracts.DTOs can break FSH.Modules.Identity.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
38→23 FSH.Modules.Identity.Services depends on FSH.Modules.Identity.Contracts.Services✕
Type pairs
27 distinct (type in FSH.Modules.Identity.Services → type in FSH.Modules.Identity.Contracts.Services) references. Showing 25 of them; the rest are in namespace-graph.json in this report's bundle.
FSH.Modules.Identity.Services uses FSH.Modules.Identity.Contracts.Services. Changing FSH.Modules.Identity.Contracts.Services can break FSH.Modules.Identity.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
38→24 FSH.Modules.Identity.Services depends on FSH.Modules.Identity.Domain✕
Type pairs
15 distinct (type in FSH.Modules.Identity.Services → type in FSH.Modules.Identity.Domain) references.
FSH.Modules.Identity.Services uses FSH.Modules.Identity.Domain. Changing FSH.Modules.Identity.Domain can break FSH.Modules.Identity.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
38→32 FSH.Modules.Identity.Services depends on FSH.Modules.Identity.Data✕
Type pairs
12 distinct (type in FSH.Modules.Identity.Services → type in FSH.Modules.Identity.Data) references.
FSH.Modules.Identity.Services uses FSH.Modules.Identity.Data. Changing FSH.Modules.Identity.Data can break FSH.Modules.Identity.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
39→1 FSH.Modules.Multitenancy.Services depends on FSH.Framework.Core.Context✕
Type pairs
1 distinct (type in FSH.Modules.Multitenancy.Services → type in FSH.Framework.Core.Context) reference.
FSH.Modules.Multitenancy.Services uses FSH.Framework.Core.Context. Changing FSH.Framework.Core.Context can break FSH.Modules.Multitenancy.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
39→3 FSH.Modules.Multitenancy.Services depends on FSH.Framework.Eventing.Abstractions✕
Type pairs
7 distinct (type in FSH.Modules.Multitenancy.Services → type in FSH.Framework.Eventing.Abstractions) references.
FSH.Modules.Multitenancy.Services uses FSH.Framework.Eventing.Abstractions. Changing FSH.Framework.Eventing.Abstractions can break FSH.Modules.Multitenancy.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
39→5 FSH.Modules.Multitenancy.Services depends on FSH.Framework.Shared.Multitenancy✕
Type pairs
8 distinct (type in FSH.Modules.Multitenancy.Services → type in FSH.Framework.Shared.Multitenancy) references.
FSH.Modules.Multitenancy.Services uses FSH.Framework.Shared.Multitenancy. Changing FSH.Framework.Shared.Multitenancy can break FSH.Modules.Multitenancy.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
39→6 FSH.Modules.Multitenancy.Services depends on FSH.Framework.Shared.Persistence✕
Type pairs
2 distinct (type in FSH.Modules.Multitenancy.Services → type in FSH.Framework.Shared.Persistence) references.
FSH.Modules.Multitenancy.Services uses FSH.Framework.Shared.Persistence. Changing FSH.Framework.Shared.Persistence can break FSH.Modules.Multitenancy.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
39→7 FSH.Modules.Multitenancy.Services depends on FSH.Framework.Storage.Services✕
Type pairs
1 distinct (type in FSH.Modules.Multitenancy.Services → type in FSH.Framework.Storage.Services) reference.
FSH.Modules.Multitenancy.Services uses FSH.Framework.Storage.Services. Changing FSH.Framework.Storage.Services can break FSH.Modules.Multitenancy.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
39→18 FSH.Modules.Multitenancy.Services depends on FSH.Modules.Multitenancy.Contracts.Dtos✕
Type pairs
4 distinct (type in FSH.Modules.Multitenancy.Services → type in FSH.Modules.Multitenancy.Contracts.Dtos) references.
FSH.Modules.Multitenancy.Services uses FSH.Modules.Multitenancy.Contracts.Dtos. Changing FSH.Modules.Multitenancy.Contracts.Dtos can break FSH.Modules.Multitenancy.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
39→25 FSH.Modules.Multitenancy.Services depends on FSH.Modules.Multitenancy.Contracts✕
Type pairs
2 distinct (type in FSH.Modules.Multitenancy.Services → type in FSH.Modules.Multitenancy.Contracts) references.
FSH.Modules.Multitenancy.Services uses FSH.Modules.Multitenancy.Contracts. Changing FSH.Modules.Multitenancy.Contracts can break FSH.Modules.Multitenancy.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
39→33 FSH.Modules.Multitenancy.Services depends on FSH.Modules.Multitenancy.Provisioning✕
Type pairs
1 distinct (type in FSH.Modules.Multitenancy.Services → type in FSH.Modules.Multitenancy.Provisioning) reference.
FSH.Modules.Multitenancy.Services uses FSH.Modules.Multitenancy.Provisioning. Changing FSH.Modules.Multitenancy.Provisioning can break FSH.Modules.Multitenancy.Services, not the reverse.
Position
Below the diagonal — points down the layering, which is what you want.
40→6 Mediator depends on FSH.Framework.Shared.Persistence✕
Type pairs
1 distinct (type in Mediator → type in FSH.Framework.Shared.Persistence) reference.
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
A03:2021 — Injection
65
REDACTED / Critical
A05:2021 — Security Misconfiguration
63
REDACTED / Critical
A02:2021 — Cryptographic Failures
13
REDACTED / Critical
A06:2021 — Vulnerable & Outdated Components
11
REDACTED / Critical
A04:2021 — Insecure Design
1
REDACTED
Roadmap
Begin by resolving explicit configuration debt, specifically addressing NoWarn settings in key project files and AnalyzerSeverityNone issues in the editor configuration. Next, split the 39 oversized source files into smaller, focused modules to improve maintainability and reduce cognitive load. Then, refactor branch-heavy functions to lower cyclomatic complexity and ensure the system meets performance targets. Finally, fix the single instance of swallowed exceptions to improve error visibility and reliability.
Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.
Do this
Helps
Effort
Dimension
Resolve the 66 NoWarnInCsproj finding(s) in Explicit Debt — start with Eventing.csproj (5), Modules.Billing.csproj (5), Modules.Auditing.csproj (5).
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.
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 — 205
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 — 578
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 — 199
Recorded, with no effect on how the codebase functions.
Present so the survey is complete, not because it needs doing.
Could not be resolved — 5
Something this survey could not settle
from the outside, and which could be critical or serious. Either a control was required and no
positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves
nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean
result. These are excluded from the score rather than awarded a pass, so the number on the cover neither
rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each
one is named under Limitations.
Methodology & how to trust this report
Watchdog is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. 111 of 118 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); 7 documentation/naming judgement(s) are LLM-assisted and labelled advisory. Overall confidence is 0.8 — the weighted average across measured dimensions; it falls as more of the score leans on LLM-assisted judgement and rises when it's fully tool-backed.
Every figure here is one of three kinds, and we label which: ✓ Measured — a deterministic fact (LoC, complexity, coverage); ~ Modeled — an estimate from a stated model (cost, effort, value-at-risk), always a range with its assumptions, never a precise fact; ◐ Advisory — an LLM prose judgement. We never present a modelled estimate as if it were measured. Perfect or absent scores carry their provenance too (ADR-0011): ✓ Tool-verified means the property itself was measured across the surface; ○ Nothing flagged means the probes came back clean — a claim bounded by what a repository can show; ⊘ Not evidenced means a working control (a tested restore, an automated rollback) showed no positive evidence — absence of evidence is not evidence of a control, so it's excluded from the score rather than awarded a spurious 10; ◐ Sampled · advisory marks an LLM verdict over a bounded sample — advisory, never a deterministic measurement.
What we checked — 118 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, 927 of 982 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, a scanner, or (for a handful of documentation/naming dimensions) an LLM labelled sampled · advisory — not a narrative.
Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.
This report answers yes to all three. That's the bar to hold any assessment to.
Tools & methods
The actual versions used this run (captured at analysis time) — re-run on the same commit for the identical score.
Method
Backs
Version
Evaluator
Roslyn static analysis
Complexity, cohesion, coupling, dead code, API surface, layering
What ran differently this time — a tool absent, degraded, or that fell back to an estimate. Named openly, not folded silently into the scores. A degraded run also records its exact cause in diagnostics.md.
D8 Code Coverage — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Coverage NOT MEASURED: the .NET half could not be measured — no coverage produced (collector absent, or test run exceeded the inline budget); the JavaScript/TypeScript half could not be measured — the JavaScript/TypeScript suite(s) are browser-driven — clients/admin/ (@playwright/test), clients/dashboard/ (@playwright/test) — and the analyzer image carries no browser to run them in. This repository's production source spans both ecosystems, and no partial figure is published as if it were the whole: coverage is excluded from the score rather than counted as a near-zero. This is OUR limitation, not a defect in the repo. In the meantime, commit (or publish into the working tree) the lcov/Cobertura report your CI produces and the real number is read on the next scan. You can widen what we reach: optional: commit the lcov/Cobertura report your CI produces, and the real number is read on the next scan.
D10 Test Quality — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. The 1,654 test(s) behind this row are the ones the C# collector could read, and this repository also carries at least 61 test source file(s) (.ts) that it cannot: it parses C# syntax and matches C# test attributes, so a vitest/jest/JUnit/pytest-style suite is invisible to it. Skipped tests, zero-assertion tests and the other quality signals on this row are UNMEASURED in that suite — their absence from the counts above is a gap in this analyzer's language coverage, not a finding that those tests are sound.
D11 Test Reliability — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Test reliability NOT SCORED: this repository's production source spans .cs, .tsx, and the built-in reliability runner cannot re-run the .tsx test suite(s) — so reliability was not measured for the repository as a whole. The .NET suite did build and re-run, and came back with 0 flaky across 2 measured tier(s) (unit: measured (0 flaky); integration: measured (0 flaky)) — but that is a figure for one half of the product, and we do not publish a partial one as if it were complete. This is OUR limitation, not a defect in the repo — test reliability is excluded from the score rather than counted.
D12 Dependency Hygiene — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This repository has NuGet-managed production source (.cs), whose `<PackageReference>` dependencies are exactly what this dimension assesses — but `dotnet list package` returned no packages, so there was nothing to assess. Zero packages read is NOT a clean dependency tree, so this is NOT SCORED. This is a gap in the analysis run (restore or project-load failed), not a verdict about this repository. Dependencies declared for the other ecosystems present here (.ts, .tsx) are not read yet either.
D17 Explicit Debt — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. The 205 deducted marker(s) and the 4.0/KLoC density on this row were taken over this repository's .NET projects ALONE: .tsx (48,185 lines, 47% of production source) went unread, because every marker collector on this path is reached through a C# workspace. D17's marker collectors need a compiler we do not have for that language, so none of its nine marker kinds were read there. The debt in that source is UNMEASURED — its absence from the score above is a gap in this analyzer's language coverage, not a finding that the code carries none.
D30 Dependency Vulnerabilities — measured, with a gap in what it reached — 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. The solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan. 2 of 3 declared ecosystem(s) (npm,osv) WERE scanned and every vulnerability they reported is included in this result; nuget was not, so this dimension's score covers less than the dependency surface this repository declares, and nothing here is evidence that nuget is free of known-vulnerable dependencies.
D32 Data Compliance (PII/GDPR) — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. `clients/admin/src/components/impersonation/impersonate-dialog.tsx`, `clients/admin/src/components/list/filter-bar.tsx`, `clients/admin/src/components/notifications/notification-bell.tsx`, `clients/admin/src/components/route-error.tsx`, `clients/admin/src/hooks/use-file-upload.ts`, … (+186 more) produced a parse error, so every rule in this engine's `gdpr.yml` was absent there. That absence is NOT a clean result: these rules detect personal data crossing a boundary into a log sink, a URL or browser storage, and a file that was never parsed cannot report any of the three. The rest of the tree analysed normally and its rows above stand; only these files are unaccounted for. You can widen what we reach: fix the syntax error (or exclude the file deliberately) and re-scan to cover it.
D39 IL Efficiency — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. IL NOT MEASURED: the analyzer's own build of this repository failed for an ENVIRONMENT reason (exit 1) — MSBuild's engine or the CLR gave up, or our image does not carry the SDK band/targeting pack this repository needs. This is OUR limitation, not a defect in the repo, and it is not a statement that this repository fails to build. D18 owns the question of whether this repository builds; it was not answered here.
D43 Malicious Dependencies — measured, with a gap in what it reached — 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. The solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan. 2 of 3 declared ecosystem(s) (npm,osv) WERE scanned and every vulnerability they reported is included in this result; nuget was not, so this dimension's score covers less than the dependency surface this repository declares, and nothing here is evidence that nuget is free of known-vulnerable dependencies.
DM2 Strongly-typed ids — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 55 further occurrence(s) are not listed individually; the score already reflects all 95.
DM9 Scattered domain decisions — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Both arms resolve expressions to symbols (a comparison operand to the member it judges, a construction to the type it constructs) and that resolution comes from a Roslyn compilation, which this run has for the C#/VB projects only. The other languages in this repository were not walked for this dimension, so the counts above speak for part of the codebase.
ED3 Event naming — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 247 further occurrence(s) are not listed individually; the score already reflects all 287.
R10 Code Duplication — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 198 further occurrence(s) are not listed individually; the score already reflects all 238.
Repo exclusion declarations (.gitattributes linguist-generated/vendored, .editorconfig generated_code): none declared — every source file was scored.
Limitations & what we did not check
Watchdog assesses the repository exactly as committed, and only the repository. By design it does not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.
Per-dimension blind spots
For each dimension that was measured, what a static, repo-only scan structurally cannot see — the honest edge of the measurement, not a failure of it.
D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
D9 Test Distribution: The test-pyramid shape is inferred from project/folder naming and references, with a single test host bucketed per-file by its path tier and content signals — a suite that names tiers unconventionally and gives no per-file signal can still be mis-bucketed.
D10 Test Quality: Assertion density is structural — it cannot tell a meaningful behavioural assertion from a trivial one, only that an assertion is present.
D13 REDACTED Scanning: REDACTED detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
D14 License Compliance: License compatibility is checked against declared package metadata and a policy — mislabelled or missing license metadata, and obligations that depend on how you distribute, are not resolved here.
D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
D16 Bus Factor: Bus-factor is a time-decayed model of commit attribution (who has recently, repeatedly worked a file), not comprehension — pairing, review and reading-without-committing spread knowledge it can't see; bot commits and shared accounts still distort it.
D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
D19 Documentation Quality: Documentation quality is judged by an LLM over a bounded sample of docs — it reads what is written, not whether the docs match the running system, and it is advisory, not a measurement. Its critique rows are drawn from a closed category vocabulary and each row means the same thing in every run, so two scans can be compared row by row; the SET that fires is still a sample, and does not repeat exactly. Measured on one frozen input, six scans at one engine SHA: 2-5 critique rows per scan, 8 distinct rows across the six, 3 of those 8 seen in only one scan. So a D19 row is evidence about the documentation, but a COUNT of D19 rows is not a quantity — never read a change in it as an improvement or a regression.
D21 Naming Consistency: Naming quality is an LLM judgement over a bounded sample — it assesses clarity/consistency of the names it sees, not domain-correctness, and is advisory.
D22 Internal API Consistency: API-surface coherence is an LLM judgement over a sample of the public surface — consistency of intent across the whole API is approximated, not exhaustively verified.
D23 Boundary Type-Coupling: Boundary leakage is detected from type references across detected contexts — leaks that flow through primitives, serialization or shared infrastructure may not surface as a typed reference.
D24 Comment Value: Comment value (WHY vs WHAT) is an LLM judgement over a bounded sample — it is advisory and cannot weigh a comment against the precise code change it was written to explain.
D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
D31 IaC & Container Security: IaC scanning checks Dockerfiles/Terraform/Kubernetes against best-practice rules — it cannot see the live cloud account, runtime configuration, or drift between the committed config and what is actually deployed.
D32 Data Compliance (PII/GDPR): PII/GDPR signals are heuristic pattern matches in code — they flag likely handling concerns, not legal compliance, and cannot trace where data actually flows at runtime.
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 REDACTED (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (go.mod, a Gemfile ruby directive) is invisible here, which is why a repository declaring none of them abstains rather than scoring. Only frameworks with a PUBLISHED support policy are tracked: React, Flask and Express publish none, so their age cannot be judged and their absence from a report is not a statement that they are supported.
AC1 Text alternatives: Alt-text is detected structurally — the scan sees that an alternative EXISTS, not whether it meaningfully describes the image, and decorative-vs-missing is judged by attribute shape; runtime-injected images and a non-role=img decorative svg are out of scope. This is accessibility readiness, never a WCAG conformance claim.
AC2 Forms & labels: Label association is read from static markup — a label wired up at runtime (JS-set aria-labelledby, framework-injected ids) reads as missing, a present label says nothing about whether its text is correct. A known UI-library field component (e.g. a JSX <TextField>) is now checked conservatively — flagged only when it carries NO label/aria-label/aria-labelledby/id/name — but wrapper/context-labelled libraries (Chakra/Radix FormControl+FormLabel) aren't statically visible (possible false positive) and non-JSX lowercased components are still skipped. A click handler on a plain element is now asked for a name too (it is a control the author declared), but the subtree test that answers it is deliberately generous: any DYNAMIC text expression in the subtree counts as a name, so an icon chosen by a ternary ({cond ? <IconA/> : <IconB/>}) reads as named, and a glyph component from a library the icon-import list does not know still names its parent. A clean result is "no unlabelled control found", not a labelling proof.
AC3 Page structure: Page structure is read from the static markup tree — landmarks, headings and lang injected at runtime aren't seen, heading ORDER is checked structurally (not against the rendered visual hierarchy), and lang/title/main fire only on full documents, never partials, and the data-table check sees header-cell presence (a <th> exists), not whether each header correctly associates with its cells. Static readiness, not conformance.
AC4 Keyboard semantics: Keyboard semantics are inferred from markup attributes — interactivity wired purely in script, focus managed at runtime, and component-level handlers are invisible. A clean result means "no static keyboard-trap shape", not a keyboard-operability proof.
AC5 ARIA correctness: ARIA correctness is checked against the static role/attribute shape — roles/attributes set dynamically aren't seen, a valid role says nothing about whether it matches the element's real behaviour, and required-state checks are suppressed when a JSX spread could supply them. The two-branch toggle check (a control whose state is conveyed only by which of two mutually exclusive branches renders) reads CONDITIONALS THAT ARE ATTRIBUTES — Vue v-if/v-else/v-show and Alpine x-if/x-show — so the same toggle written as a Svelte {#if} block or a JSX ternary is control flow the markup model never projects as a branch and is not seen at all.
AC6 Visual & motion safety: Contrast and motion safety are PARTIAL by construction — literal colours (hex/rgb/hsl/named) in inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS top-level declarations are read (same-rule/same-element colour+background pairs only); computed/runtime/theme colour, external-CDN stylesheets, CSS-in-JS dynamic (${…}) and nested-selector colours, cross-element pairs and image contrast stay out of reach, so a clean result is bounded by what the static CSS itself shows.
AC7 A11y enforcement: Enforcement is scored from in-repo config/CI evidence only — an a11y gate enforced in external tooling with no in-repo trace can't be credited, and a configured linter is presence, not proof the rules actually run or block a merge.
AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
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.
C3 Audit Trail: This control is scored from in-repo evidence only — a working control configured outside the repository leaves no signal a static scan can credit.
C4 Data Retention: This control is scored from in-repo evidence only — its real-world effectiveness, exercised only at runtime, is outside a static scan.
DM4 Rich vs anemic model: Behaviour is detected as state mutation inside a method body — a method that enforces an invariant by validating-and-throwing without mutating reads as a query, and mutation delegated through an interface the scan can't resolve isn't credited; entities with zero public properties still drop out of the population. It detects that state changes, not whether the rule is correct.
DM6 Domain ↔ infrastructure boundary: Infrastructure reached through a hand-rolled wrapper, a domain-named facade, reflection, or a string-keyed service locator resolves to a non-infra type and isn't seen; the body scan is symbol resolution over syntax, not full dataflow. A clean result means "no resolved infra reference in a domain body", not a proof of purity.
ED5 Idempotency: Idempotency is judged from the handler body's visible writes and guards — a guard enforced by a database unique constraint, a broker's exactly-once delivery, or a domain method whose no-op-when-applied logic the scan can't follow may read as at-risk; the at-risk candidates are confirmed by a SAMPLED LLM verdict (advisory, not exhaustive) and degrade to heuristic-only when no model is configured. It flags the at-least-once double-apply SHAPE, not a runtime proof of a duplicate effect.
M4 Documentation accuracy: Onboarding quality is an LLM read of the docs/setup present — it cannot run the onboarding or measure how long a real new joiner takes; the verdict is sampled and advisory.
P4 Deployment & Rollback: Approval/branch-protection rules live in repository settings the scan cannot see — only their in-repo evidence (config files, workflows) is checked, so a control enforced purely in the host's settings reads as "not evidenced".
P5 DR & Backup: Backup/restore and disaster-recovery readiness is judged from in-repo evidence — a config that exists is not a tested restore, so the absence of positive evidence is reported as "not evidenced", never scored as present.
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.
The LLM boundary
LLM-set scores this run (7): D19, D21, D22, D24, D26, ED5, M4 (model: Local LLM). For these, a model reads a bounded sample and sets the numeric score; each names its own sample and method on its card. They are sampled and advisory by design: they vary at the margins between runs and are never a deterministic measurement. Every other score in this report is tool-computed at confidence 1.0.
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.
71 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was message-list.MessageList at 92. 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 WebhookUrlGuard.IsBlockedAddress 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/Modules/Webhooks/Modules.Webhooks/Services/WebhookUrlGuard.cs (WebhookUrlGuard.IsBlockedAddress at 20), clients/admin/src/pages/users/detail.tsx (detail.UserDetailPage at 20). 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.
+ 62 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 2 reset-password.ResetPasswordPage (cyclomatic 29) finding(s) in Cyclomatic Complexity — start with reset-password.tsx (2). — One of this dimension's main actionable groups (2 warning-level).
Resolve the 2 use-file-upload.useFileUpload (cyclomatic 27) finding(s) in Cyclomatic Complexity — start with use-file-upload.ts (2). — One of this dimension's main actionable groups (2 warning-level).
Resolve the 2 login.LoginPage (cyclomatic 21) finding(s) in Cyclomatic Complexity — start with login.tsx (2). — One of this dimension's main actionable groups (2 warning-level).
Enforce Cyclomatic Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
Detailed fixes: d1_recommendation.md · top locations in Appendix A, every location in findings.md.
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.
+ 74 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 2 reset-password.ResetPasswordPage (cognitive 35) finding(s) in Cognitive Complexity — start with reset-password.tsx (2). — One of this dimension's main actionable groups (2 warning-level).
Resolve the 2 use-file-upload.useFileUpload (cognitive 32) finding(s) in Cognitive Complexity — start with use-file-upload.ts (2). — One of this dimension's main actionable groups (2 warning-level).
Resolve the 2 login.LoginPage (cognitive 21) finding(s) in Cognitive Complexity — start with login.tsx (2). — One of this dimension's main actionable groups (2 warning-level).
Enforce Cognitive Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D3 · God Classes2.1 / 10Critical✓ 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 88 FunctionTooLong finding(s) in God Classes — start with list.tsx (6), detail.tsx (5), security.tsx (5). — One of this dimension's main actionable groups (88 warning-level).
Resolve the 20 FileTooLong finding(s) in God Classes — start with products.tsx, audits.tsx, overview.tsx. — One of this dimension's main actionable groups (20 warning-level).
Resolve the 4 MethodTooLong finding(s) in God Classes — start with 20251222232937_Initial.cs, 20260512193158_InitialChat.cs, 20260420140335_InitialBilling.cs. — One of this dimension's main actionable groups (4 warning-level).
Enforce God Classes in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Copy-pasted code that should be shared instead.
Method: Code duplication via token-stream sliding windows with type-aware normalization (locals masked, type names preserved), density-scored per KLoC of production code. Deterministic.
58 duplicated block group(s) detected. A further 6 rows report members as variants of one another; they aggregate block groups already counted above and are not themselves counted. Measured on part of this repository only: .tsx (47% of production source) was not exposed to THIS dimension's token comparison and is not in this count; duplication there is measured by R10 Code Duplication, the frontend lens's card running the same clone algorithm over the JS/TS token stream.
+ 38 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 5 Duplicated block (7 lines × 2) finding(s) in Code Duplication — start with 20260420140335_InitialBilling.cs, 20260430033202_InitialCatalog.cs, 20260512193158_InitialChat.cs. — One of this dimension's main actionable groups (5 warning-level).
Resolve the 4 Duplicated block (11 lines × 2) finding(s) in Code Duplication — start with IAuditEvent.cs, ApproveTopupRequestCommandHandler.cs, AddReactionCommandHandler.cs. — One of this dimension's main actionable groups (4 warning-level).
Resolve the 3 Members sharing a duplicated core (4 members, 50+ identical tokens) finding(s) in Code Duplication — start with GetInvoicesQueryHandler.cs, Brand.cs, GetPinnedMessagesQueryHandler.cs. — One of this dimension's main actionable groups (3 warning-level).
Enforce Code Duplication in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.
Detailed fixes: d4_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D5 · Coupling9.4 / 10Stronggated by 5 serious findings✓ 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.
Resolve the 5 Off the main sequence finding(s) in Coupling. — One of this dimension's main actionable groups (5 warning-level).
Enforce Coupling in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
Detailed fixes: d5_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D9 · Test Distribution10.0 / 10Exemplary✓ Tool-verified
What it measures: Whether the test suite has a healthy mix of unit / integration / end-to-end tests.
Method: Test projects classified (Unit/Integration/BDD/E2E) from compiled metadata; test methods counted exhaustively across projects with placement-agnostic disk fallback. Deterministic.
1915 test methods: 1167 unit, 748 integration, 0 BDD, 0 e2e. The JavaScript/TypeScript suite contributes 261 `it`/`test` case(s) across 55 test file(s) declaring at least one beside 1654 .NET test method(s); its tier split is read from package names and paths only.
✓ On the Gold path — maintain.
Detailed fixes: d9_recommendation.md.
Do you agree with this assessment?
D10 · Test Quality10.0 / 10Exemplary✓ Tool-verified
What it measures: Whether the tests truly assert behaviour rather than just running the code.
Method: Per-test assertions, skips, and mock references analyzed via Roslyn; structured skip-reason tags (BUG:/ENV:) separate documented deferrals from debt. Deterministic.
1 skipped (1 with a documented reason), 0 zero-assertion, 8 mock references across 1654 tests. Measured on the C# suite only — at least 61 test source file(s) (.ts) went unread, so its test quality is unmeasured and is not in these counts.
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 250 packages use a banned license. ★ DEPTH: this repository's MSBuild projects declare 88 direct `PackageReference`(s), and 162 further package(s) were reached beyond them by closing the graph over nuget.org's own nuspec dependency graph — so a banned licence pulled in only by a dependency's OWN dependencies is inside this verdict. A package whose licence nuget.org could not be asked for is not graded, and version ranges are taken at their lower bound, so this is the closure as that graph states it rather than a restored consumer's exact resolution.
What it measures: Files that change often and are also complex — the riskiest hotspots.
Method: Per production file churn times cyclomatic complexity over a rolling window, computed from git and Roslyn/JS/Razor analysis. Exhaustive, deterministic per commit date.
Top hotspots: clients/dashboard/src/pages/chat/message.tsx (20×39=780); clients/admin/src/pages/tenants/detail.tsx (9×40=360); clients/dashboard/src/pages/chat/composer.tsx (13×21=273) Repeated repair below the complexity floor: src/BuildingBlocks/Web/Realtime/AppHub.cs (5 of 7 changes were fixes); REDACTED (5 of 6 changes were fixes); clients/dashboard/src/auth/auth-context.tsx (5 of 5 changes were fixes)
Resolve the 46 Hotspot finding(s) in Churn × Complexity Hotspots — start with detail.tsx (4), list.tsx (4), login.tsx (2). — One of this dimension's main actionable groups (46 warning-level).
Resolve the 14 Repeated repair finding(s) in Churn × Complexity Hotspots — start with Extensions.cs (2), AppHub.cs, REDACTED. — One of this dimension's main actionable groups (14 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 Factor4.5 / 10Weak✓ 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.
118 source file(s) have their living knowledge concentrated in one author (≥90% of recent, decayed contribution). The largest is REDACTED. Counted over 217 of the 1292 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.
205 deducted debt markers + 3 dead symbols across 47569 LoC in the .NET projects (4.0/KLoC) → score 2.0. Measured on the .NET source only: .tsx (47% of production source) was not read, and carries at least 0 uncounted task marker(s) in 0 file(s).
NoWarnInCsproj — 6 warning codes suppressed in one element · ×66src/Tests/Webhooks.Tests/Webhooks.Tests.csproj:8
NoWarnInCsproj repeated across 10 files · ×3src/Tests/Multitenancy.Tests/Multitenancy.Tests.csproj:8
Dead code: Promote · ×3src/Modules/Chat/Modules.Chat/Domain/ChannelMember.cs:31
+ 2 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 66 NoWarnInCsproj finding(s) in Explicit Debt — start with Eventing.csproj (5), Modules.Billing.csproj (5), Modules.Auditing.csproj (5). — One of this dimension's main actionable groups (66 issue-level).
Resolve the 19 FileScopedPragmaDisable finding(s) in Explicit Debt — start with AdjustTenantValidityTests.cs (2), ChangeTenantActivationValidationTests.cs (2), RenewTenantTests.cs (2). — One of this dimension's main actionable groups (19 issue-level).
Resolve the 11 AnalyzerSeverityNone finding(s) in Explicit Debt — start with .editorconfig (11). — One of this dimension's main actionable groups (11 issue-level).
Enforce Explicit Debt in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
Detailed fixes: d17_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether the project's documentation is clear, complete, and useful.
Method: Judged by language model at low temperature (0.0-0.1) on a deterministic doc sample (READMEs plus first 25 architecture docs), with two-pass stability filtering. Advisory, sampled.
The FullStackHero .NET 10 Starter Kit is a clear, well-structured documentation set: the README and seven README files (Architecture.Tests, deploy/docker/, clients/admin/, clients/dashboard/, FSH.DbMigrator, Terraform stack) cover installation, usage, architecture tests, deployment, modules, licensing, and contributor guidance. The XML-doc coverage is strong across modules (62% Caching, 78% Core, 100% Eventing.Abstractions, 46% Eventing, 5% Jobs, 0% Mailing, 65% Persistence, 37% Quota, 18% Shared, 7% Storage, 29% Web), with the README and architecture docs providing the most visible overview. The only unshown section is the architecture-guard workflow (architecture-guard.md) that appears clipped mid-steps; no defect. The repository is well documented: the README lists seven README files plus architecture/Docs markdown and XML coverage for each module (62% Caching, 45% Core, 100% Eventing.Abstractions, 37% Eventing). The architecture document covers a modular Monolith + VSA with dependency direction, BuildingBlocks vs modules, the four-place registration footgun, DI/handler conventions, middleware ordering, static/global state, and configuration; it is clipped mid-sentence. A separate design doc addresses admin → dashboard unification as a multi-phase program (draft), covering context, why it matters, and the proposed phases with inventory, risks, and verification.
Documentation: no installation or build instructions · ×3README.md
Resolve the 3 Documentation finding(s) in Documentation Quality — start with README.md (3). — One of this dimension's main actionable groups (3 recommendation-level).
Detailed fixes: d19_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether names — types, methods, variables — are clear and consistent.
Method: Judged by language model at low temperature (0.0-0.1) on a deterministic random symbol sample (fixed size, not exhaustive), with disclosed confidence band. Advisory, sampled.
1 naming inconsistencies across 200 sampled symbols.
The term 'Area' is used in the query DTO to represent what is likely a correlation identifier or scope context, while the main audit envelope type is named 'AuditEnvelope'. In the context of auditing, 'Area' is ambiguous and inconsistent with the standard 'CorrelationId' or 'Scope' terminology used elsewhere (e.g., `HttpAuditScope.CorrelationId`).
✓ On the Gold path — maintain.
Detailed fixes: d21_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D22 · Internal API ConsistencyStronggated by 2 serious findings◐ Sampled · advisory
What it measures: Whether the internal API surface is consistent and coherent.
Method: Judged by language model at low temperature over a sample of the public API surface (IsPackable or .Contracts types). Sampled, advisory; confidence discounted by model uncertainty.
2 API inconsistencies across a 400-member sample of 355 exposed types.
Inconsistent naming convention for audit writing methods. The methods use specific domain verbs (WriteEntityChange, WriteSecurity, WriteActivity, WriteException) rather than a unified verb like 'WriteAudit' or 'Record' with a payload type, or a consistent 'Log' prefix. While distinct, the lack of a common root verb makes the API surface feel fragmented compared to standard logging abstractions.
Duplication of intent between ISecurityAudit and IAuditClient.WriteSecurityAsync. ISecurityAudit provides specific, high-level methods for security events (Login, Token, Impersonation), while IAuditClient.WriteSecurityAsync provides a generic method that takes a SecurityAction enum. This forces implementers to either implement both interfaces or choose one, creating confusion about which is the primary entry point for security auditing.
What to do
Resolve the 1 Inconsistent naming convention for audit writing methods. The methods… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 Duplication of intent between ISecurityAudit and… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d22_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether domain types (IDs, enums, value objects) leak across bounded-context boundaries.
Method: Cross-context domain-type leakage via Roslyn structural classification (strongly-typed IDs / value objects) over every public surface. Exhaustive, deterministic, type-level aggregate-boundary check.
Coverage: Bounded contexts derived from NAMESPACE prefix (or graph-inferred where available); cross-boundary domain-type leakage then checked exhaustively over every public member of every type.
11 domain type(s) cross context boundaries across 13 contexts.
Cross-context type FileAccessContext (Files → Catalog) · ×2
Cross-context type FileAccessContext (Files → Chat) · ×2
Cross-context type TenantRenewedIntegrationEvent (Multitenancy → Billing)
Cross-context type TenantSubscribedIntegrationEvent (Multitenancy → Billing)
Cross-context type InvoiceIssuedIntegrationEvent (Billing → Notifications)
+ 14 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 2 Cross-context type FileAccessContext (Files → Catalog) finding(s) in Boundary Type-Coupling. — One of this dimension's main actionable groups (2 warning-level).
Resolve the 2 Cross-context type FileAccessContext (Files → Chat) finding(s) in Boundary Type-Coupling. — One of this dimension's main actionable groups (2 warning-level).
Resolve the 1 Cross-context type TenantRenewedIntegrationEvent (Multitenancy →… finding(s) in Boundary Type-Coupling. — One of this dimension's main actionable groups (1 warning-level).
Enforce Boundary Type-Coupling in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.
Detailed fixes: d23_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D24 · Comment ValueExemplary◐ Sampled · advisory
What it measures: Whether comments are worth it — explaining WHY (valuable) rather than WHAT (redundant).
Method: Judged by language model at low temperature (0.0-0.1) on deterministically sampled inline comments with surrounding code; findings verified back to sampled comments by substring match. Advisory, sampled.
What it measures: Whether any secrets were ever committed — scanned across the full git history, not just now.
Method: REDACTED scan via TWO gitleaks detect passes in an isolated checkout — the full git history, then a second --no-git pass over the working tree as it stands — merged and de-duplicated by (rule, file, line); each match flagged REDACTED. 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.
12 finding(s): 0 critical, 12 high, 0 medium, 0 low. Remediation for historically-committed secrets is credential rotation — they remain in history regardless of later deletion.
REDACTED
REDACTED
REDACTED
What to do
Resolve the 11 REDACTED finding(s) in Secrets (history) — start with REDACTED (4), REDACTED (2), REDACTED (2). — One of this dimension's main actionable groups (11 issue-level).
Resolve the 1 REDACTED secret finding(s) in Secrets (history) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
Resolve the 1 Rotate the exposed credentials finding(s) in Secrets (history). — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d28_recommendation.md · top locations in Appendix A, every location in findings.md.
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).
65 finding(s): 0 critical, 58 high, 6 medium, 1 low. semgrep hit a parse error in 198 file(s) — `clients/admin/docker/docker-entrypoint.sh` (line 5, line 6), `clients/admin/src/components/impersonation/impersonate-dialog.tsx`, `clients/admin/src/components/list/filter-bar.tsx` (lines 17–28), `clients/admin/src/components/notifications/notification-bell.tsx`, `clients/admin/src/components/route-error.tsx`, … (+193 more) — so no absence of findings in the named regions is evidence of anything; rows reported elsewhere in those files are real. Fix the syntax error (or exclude the file deliberately) and re-scan to cover them. In 176 of those file(s) — `src/BuildingBlocks/Mailing/MailRequest.cs`, `src/BuildingBlocks/Mailing/Services/SmtpMailService.cs`, `src/BuildingBlocks/Persistence/ConnectionStringValidator.cs`, `src/BuildingBlocks/Persistence/Context/BaseDbContext.cs`, `src/BuildingBlocks/Web/Auth/CurrentUserMiddleware.cs`, … (+171 more) — the break is a C# primary constructor, which semgrep's grammar cannot parse and which hides the type from every rule scoped to it; those files were re-scanned from a shadow copy with the constructor's parameter list blanked (line and column preserving), which restores the type to the rules, and 0 additional row(s) came from that pass. Only the header's own parameter list is unread in them. In 2 of those file(s) — `src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs`, `src/Modules/Catalog/Modules.Catalog/Data/CatalogSeedData.cs` — the break is at a TYPE DECLARATION (a C# primary constructor semgrep's grammar cannot parse), so the loss is wider than the named lines: rules scoped to that type see no type to scope to and are blind over its whole body, while rules matching statements keep working there. Absence of a type-scoped finding in those types is not evidence of anything. Separately, one or more rules could not re-parse an embedded snippet in 1 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
What to do
Resolve the 58 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (38), REDACTED (7), REDACTED (7). — One of this dimension's main actionable groups (58 issue-level).
Resolve the 6 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (5), REDACTED. — One of this dimension's main actionable groups (6 warning-level).
Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d29_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether any dependency has a known published vulnerability (CVE), direct or transitive, in ANY ecosystem the repository declares — Dart pub, Elixir/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, Go, Java and Kotlin via Maven/Gradle, 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.
11 finding(s): 0 critical, 9 high, 2 medium, 0 low. Partial dependency scan: 2 of 3 declared ecosystem(s) were scanned (npm,osv), and the findings above are real and complete for them. nuget was not scanned (nuget: the solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan), so this is not the whole dependency surface and the result is reported at reduced confidence.
REDACTED
REDACTED
What to do
Resolve the 9 REDACTED CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (9). — One of this dimension's main actionable groups (9 issue-level).
Resolve the 2 REDACTED CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (2). — One of this dimension's main actionable groups (2 warning-level).
Detailed fixes: d30_recommendation.md · top locations in Appendix A, every location in findings.md.
Resolve the 42 REDACTED IaC finding(s) in IaC & Container Security — start with REDACTED (32), REDACTED (8), REDACTED (2). — One of this dimension's main actionable groups (42 warning-level).
Resolve the 8 REDACTED IaC finding(s) in IaC & Container Security — start with REDACTED (4), REDACTED (2), REDACTED (2). — One of this dimension's main actionable groups (8 issue-level).
Resolve the 4 Critical IaC finding(s) in IaC & Container Security — start with REDACTED (4). — One of this dimension's main actionable groups (4 issue-level).
Detailed fixes: d31_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D32 · Data Compliance (PII/GDPR)9.0 / 10Stronggated by 1 serious finding✓ Tool-verified
What it measures: Likely personal-data (PII / GDPR) handling concerns — logging or storing data without safeguards.
Method: Heuristic PII/GDPR LEAK scan via semgrep across the repo, using Watchdog's own ruleset: personal data crossing a boundary it should not — reaching a log/console sink, a URL or query string, or unprotected browser storage. Matches map to severity and a 0-10 wide normalizer. A clean sweep is unscored rather than an unearned 10, and is a statement about the leak paths checked only — this dimension does not inventory the personal data a repository holds (the personal-data map and the C1-C5 compliance cards do that), so it never reports that a repository has no personal-data surface. Reported LOUDLY as a measurement gap if the ruleset is missing from the analyzer image. Exhaustive over the leak paths, advisory-leaning; degrades on parse failure.
1 finding(s): 0 critical, 0 high, 1 medium, 0 low. semgrep could not parse 191 file(s) — `clients/admin/src/components/impersonation/impersonate-dialog.tsx`, `clients/admin/src/components/list/filter-bar.tsx`, `clients/admin/src/components/notifications/notification-bell.tsx`, `clients/admin/src/components/route-error.tsx`, `clients/admin/src/hooks/use-file-upload.ts`, … (+186 more) — so the PII/GDPR sweep did not cover the unparsed regions of them; rows reported elsewhere in those files are real.
REDACTED
What to do
Resolve the 1 REDACTED finding(s) in Data Compliance (PII/GDPR) — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d32_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether anyone still has living knowledge of each file, or it has been orphaned — last understood long ago by someone now gone quiet. The sibling of the bus factor: D16 asks who owns it, D34 asks whether anyone still knows it.
Method: File orphaning as total living-knowledge decay below one focused-commit's worth within a year, computed per-file from the D16 decay model. Exhaustive, deterministic over fixed history.
Every significant source file has living knowledge — recently and meaningfully worked. Counted over 217 of the 1292 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.
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. Scored apart from D30 because the answer is binary: there is no safe version to upgrade to, and the fix is to remove the package and rotate every credential it could have read.
Method: The same dependency scan D30 reads, partitioned on the scanner's own classification rather than rescanned: a row is MALICIOUS when its id is in the `MAL-` space (the ossf/malicious-packages feed) OR its `database_specific.cwe_ids` carries `CWE-506` ("Embedded Malicious Code"). Both channels are structural; the summary text is deliberately NOT read, because a malicious-package record whose summary says only "Critical severity vulnerability" is a real shape ([GHSA redacted]) and a text matcher misses it. Scored BINARY: any surviving row is 0, whatever its severity and however many CVEs sit beside it — a hostile dependency is not a quantity. Applicability and degradation are D30's: NotApplicable only when no ecosystem is readable, and an unscannable ecosystem degrades rather than reading clean. SCORED, not informational.
No known-vulnerable dependencies in the 2 ecosystem(s) that were scanned (npm,osv). Partial dependency scan: 2 of 3 declared ecosystem(s) were scanned (npm,osv), and the findings above are real and complete for them. nuget was not scanned (nuget: the solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan), so this is not the whole dependency surface and the result is reported at reduced confidence.
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.
0 end-of-life runtime(s) and 0 end-of-life framework(s), read from 11 platform declaration(s) and 0 dependency declaration(s). This dimension reads what the repository says about ITSELF — a pinned target framework, a version file, a capped requires-python, a framework major a constraint cannot move off. A FLOOR is deliberately never charged: `requires-python = ">=3.8"` states what the package SUPPORTS, not what it runs on, and a well-maintained library declares exactly that while running its own CI on a current release. The end-of-life facts are FROZEN and dated, so this dimension needs no network and answers identically inside a closed scan fence; as the table ages it loses recall and never precision, because a statement about support that ended in the past cannot become false. The OS layer of a container image is D31's question and the toolchain a CI workflow installs is D29's; this row is neither.
✓ On the Gold path — maintain.
Detailed fixes: d44_recommendation.md.
Do you agree with this assessment?
Frontend & cross-cutting dimensions
R = React/JS · M = Maturity · P = Readiness.
AC1 · Text alternatives10.0 / 10Exemplary○ Nothing flagged
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.
Do you agree with this assessment?
AC2 · Forms & labels7.0 / 10Strong✓ Tool-verified
Other · Accessibility — Whether form controls have a programmatic label (an associated label, aria-label or aria-labelledby), buttons have text, links have an accessible name, a click handler on a plain element names the control it declares, fieldsets have a non-empty legend, known UI-library field components carry a label prop, and a placeholder isn't used as the only label. Static markup readiness, not a WCAG conformance claim.
Method: Static markup-model scan: inputs/selects/textareas checked for an associated label[for]/wrapping label/aria-label/aria-labelledby (per document), buttons for accessible text, fieldsets for a legend; placeholder-only labelling flagged. Deterministic, hard fact per control.
Coverage: Population: form controls, buttons, links, fieldsets and known UI-library field components in the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx); components, hidden subtrees and spread/dynamic-attribute elements are skipped, so a control whose label arrives through a spread or a runtime expression is deliberately not judged. Markup built in script — tagged-template (html`…`) UIs and hyperscript DOM factories — is not read at all.
This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label htmlFor>, a wrapping <label>, or aria-label. (×3) — clients/admin/src/components/webhooks/create-webhook-dialog.tsx:199, clients/dashboard/src/components/list/combobox.tsx:145, clients/dashboard/src/pages/catalog/products.tsx:274
This UI-library field component has no label / aria-label / aria-labelledby / id / name — and neither does anything it renders — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed. (×3) — clients/admin/src/pages/audits/list.tsx:173, clients/admin/src/pages/audits/list.tsx:180, clients/admin/src/pages/notifications/inbox.tsx:97
This UI-library field component is named only by a placeholder — a placeholder is not a label (it vanishes as soon as the user types, and many assistive technologies ignore it). Give it a real name whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed. — clients/admin/src/pages/impersonation/list.tsx:103
This control has no associated label. Add a <label htmlFor> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it. — clients/dashboard/src/components/file/file-dropzone.tsx:111
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.
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: interactive elements plus elements the markup gives a click/key handler or the repo's own CSS styles `cursor: pointer`, in the PARSED MARKUP files only (.html/.htm/.cshtml/.razor/.vue/.svelte/.jsx/.tsx). 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".
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.
Other · Accessibility — Whether accessibility is ENFORCED in the toolchain — an accessibility checker configured over the markup (an a11y lint rule set, e.g. eslint-plugin-jsx-a11y or vuejs-accessibility where the project lints JavaScript) and an automated accessibility assertion wired into tests or CI (axe/pa11y/Lighthouse or an equivalent) — on the Documented→Verified→Prevented ladder.
Method: Repo config/CI scan: an accessibility checker configured over the markup (an a11y lint rule set such as eslint-plugin-jsx-a11y / vuejs-accessibility where JavaScript is linted) and an automated accessibility assertion in tests or CI (axe/pa11y/Lighthouse or equivalent), graded on the Documented→Verified→Prevented rungs. Deterministic, presence/rung detection.
Coverage: Population: the repository's own tooling configuration — lint config, test and CI files — NOT the markup. It is read for a configured accessibility checker and an automated accessibility assertion (axe/pa11y/Lighthouse, or a native-toolkit equivalent), and it credits an INVOCATION, never a mention: a licence filename, an import comment or a doc reference earns no rung. Enforcement configured entirely outside the repository leaves no evidence here and cannot be credited.
An a11y linter is configured (Documented) but there's no automated a11y test or CI gate. Add @axe-core/playwright to verify at runtime, then gate it in CI. What was searched, so you can tell an absence from a miss: the 190 markup file(s) this pass actually assessed, the linter configuration checked in beside them, and this repository's test and CI files — matched by name against the accessibility checkers this dimension carries. An audit run outside the repository, a hosted scanner, or a check whose name is not one of those, is not seen here.
What to do
Accessibility linting is already configured — assert with @axe-core/playwright in tests, then gate axe/pa11y/Lighthouse in CI.
Other · Architecture — Whether any singleton service captures a scoped/transient dependency — a silent lifetime/threading bug.
Method: Roslyn scan: DI registrations parsed from AddSingleton/Scoped/Transient; each singleton checked for captured shorter-lifetime dependencies. Exhaustive, deterministic.
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.
Method: Roslyn line-count by code ROLE: every source file classified Domain/Application/Infrastructure/Test/Generated by namespace + path convention (the shared CodeRoleClassifier), then significant lines summed per role. Deterministic; the advisory score is the business-logic (domain+application) share of production code.
Coverage: Population: ALL source files, each bucketed into ONE of five roles (Domain/Application/Infrastructure/Test/Generated) by namespace + path convention — a file whose layer isn't named in the convention falls to Application (the neutral default), and the split is line-count, not semantic depth or business value.
What to do
The domain core is a small share of production code, but most of the rest matched no layer vocabulary at all — so this is not yet an anemic-domain finding. The namespace/path convention could not place that code, which makes the composition above a statement about the naming, not about the design. Name the layers (or check that the repository's conventions differ from the ones this check knows) before reading a thin domain into it.
Other · Architecture — Whether singleton services avoid mutable shared instance state that concurrent callers would race on.
Method: Roslyn scan: singleton field mutations unguarded by lock or Interlocked, per type; syntax-based guard detection. Deterministic, traceable per field.
`RabbitMqEventBus` is a singleton (one shared instance) but mutates instance state outside any lock (_channel, _connection; e.g. `_channel` at line 207). — src/BuildingBlocks/Eventing/RabbitMq/RabbitMqEventBus.cs:13
What to do
Keep singletons stateless or back their state with thread-safe types (Concurrent*/Immutable*); otherwise concurrent callers race.
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 the codebase has a recognisable, scale-appropriate structure (a named architectural style, or modular enough for its size) rather than being an ad-hoc ball of mud.
Method: Roslyn plus csproj analysis: architecture style detection (DDD, clean, vertical-slice, CQRS) and structure fitness for repo size. Deterministic.
Other · Architecture — Whether interfaces stay focused rather than fat — the Interface-Segregation principle (SOLID 'I').
Method: Roslyn scan: public interface declared-member counts (accessors fold into their property/event); fat-interface threshold (over 15 declared members) flagged per type. Each finding also reports the distinct-OPERATION count — members counted by name, so an overload group counts once — which decides whether it states the caller-side ISP harm or the implementer-side burden of an overload set. Deterministic, type-level.
`IJobService` declares 17 members under just 4 distinct name(s): `Delete`, `Delete`, `Enqueue`, `Enqueue`, `Enqueue`, `Enqueue`, `Enqueue`, `Requeue`, `Requeue`, `Schedule`, `Schedule`, `Schedule`, `Schedule`, `Schedule`, `Schedule`, `Schedule`, `Schedule`. Counted as the author wrote them — a property is ONE member and its get/set accessors are not counted separately, and an event counts once. That is an OVERLOAD SET, not 17 separate responsibilities: a caller binds to 4 operation(s) and uses the overload it selected, so the Interface-Segregation harm does NOT apply on the caller's side and splitting this into role-interfaces would scatter one operation without relieving anything. The burden that does remain is the IMPLEMENTER's — all 17 signatures must be written and kept in step. Reduce it by collapsing overloads (optional or default parameters, or an options object) rather than by segregating the interface. — src/BuildingBlocks/Jobs/Services/IJobService.cs:5
`IUserService` declares 22 members: `ExistsWithNameAsync`, `ExistsWithEmailAsync`, `ExistsWithPhoneNumberAsync`, `GetListAsync`, `GetCountAsync`, `GetAsync`, `ToggleStatusAsync`, `GetOrCreateFromPrincipalAsync`, `RegisterAsync`, `UpdateAsync`, `DeleteAsync`, `ConfirmEmailAsync`, `AdminConfirmEmailAsync`, `ResendConfirmationEmailAsync`, `ConfirmPhoneNumberAsync`, `HasPermissionAsync`, `ForgotPasswordAsync`, `ResetPasswordAsync`, `GetPermissionsAsync`, `ChangePasswordAsync`, `AssignRolesAsync`, `GetUserRolesAsync`. Counted as the author wrote them — a property is ONE member and its get/set accessors are not counted separately, and an event counts once. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces. — src/Modules/Identity/Modules.Identity.Contracts/Services/IUserService.cs:7
What to do
Split fat interfaces into focused role-interfaces so clients depend only on what they use.
Where the width is an overload set rather than separate responsibilities, collapse the overloads instead — segregating those relieves no caller.
Other · Architecture — Whether feature slices stay independent (no direct cross-slice references) — the discipline that makes vertical-slice architecture pay off.
Method: Roslyn scan (vertical-slice gated): feature slices resolved from namespaces (.Features.*, .Slices.*) or project names; cross-slice type references detected. Deterministic, traceable.
Do you agree with this assessment?
AX8 · Test isolation10.0 / 10Exemplary✓ Tool-verified
Other · Architecture — Whether production projects stay free of references to test projects — tests may depend on production, never the reverse.
Method: Csproj graph: each production project checked for references to test projects (identified by test-framework presence, not name). Zero violations is clean. Deterministic.
Other · 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.
Do you agree with this assessment?
C1 · Data Protection6.5 / 10Adequate✓ Tool-verified
Other · Security — Whether sensitive data is encrypted at rest and in transit and keys are vaulted.
Method: Roslyn plus filesystem scan: encryption presence (EF ColumnEncryption, key-vault references, HTTPS enforcement) and key-derivation KDF detection. Deterministic.
What to do
Strengthen data-at-rest protection: vault your keys (Azure Key Vault / AWS KMS / IDataProtector key ring) and encrypt the most sensitive columns (EF HasConversion encryption or provider-native column encryption) — partial coverage still leaves gaps.
Other · Security — Whether access is authorized by default — a framework authorization attribute/decorator or policy, or imperative guard methods (throw-on-violation) called from handlers.
Method: Roslyn scan: [Authorize] usage and authorization policies, plus imperative throw-on-violation guard methods detected via syntax. Deterministic.
Do you agree with this assessment?
C3 · Audit Trail10.0 / 10Exemplary✓ Tool-verified
Other · Security — Whether changes to sensitive data are recorded (who, what, when) for compliance + incident response.
C4 · Data Retention10.0 / 10Exemplary✓ Tool-verified
Other · Security — Whether data has a defined lifetime — retention periods, TTLs, cleanup jobs (storage limitation).
Method: Roslyn scan: retention/TTL configuration presence in schema; CascadeDelete detected but not scored as retention control. Deterministic, gated by PII presence.
Other · Domain Modelling — Whether aggregates reference each other by identity (id) rather than by direct object reference — the core DDD consistency-boundary rule.
Method: Roslyn (DDD-gated): aggregate roots identified by convention; each aggregate field checked for direct references to other aggregates versus id-only. Deterministic, DDD-native.
Coverage: Population: aggregate roots identified by AggregateRoot/IAggregateRoot base/interface NAME convention; reference-by-identity then checked exhaustively within that set — a root not using those names is invisible.
Do you agree with this assessment?
DM10 · One transaction, one aggregate9.3 / 10Exemplary✓ Tool-verified
Other · Domain Modelling — Whether a single operation mutates more than one aggregate root. An aggregate is a consistency boundary, so saving two together fuses them into one — the second's invariants come to depend on the first's transaction, and the pair can no longer be separated. Reads of other aggregates are not counted.
Method: Neutral body surface (DDD-gated): every method body scanned for repository WRITE calls (Add/Update/Save/Remove/Delete/Insert/Store and their async forms), keyed on the ARGUMENT type rather than the repository type — three `IRepository<T>` writes collapse to one repository but are three distinct aggregates. Reads (Get/Find/Load/Query) are excluded, so loading another aggregate for context never counts. Score is offending methods over methods that write at all. Deterministic.
`DemoSeeder.SeedTenantSubscriptionAsync` saves `Subscription`, `Invoice` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event. — src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:190
`DemoSeeder.SeedTenantChatAsync` saves `ChatChannel`, `Message` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event. — src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:537
`DemoSeeder.SeedChannelAsync` saves `ChatChannel`, `Message` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event. — src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:659
`IdentityDbInitializer.SeedSystemGroupsAsync` saves `Group`, `GroupRole` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event. — src/Modules/Identity/Modules.Identity/Data/IdentityDbInitializer.cs:103
`CreateGroupCommandHandler.Handle` saves `GroupRole`, `Group` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event. — src/Modules/Identity/Modules.Identity/Features/v1/Groups/CreateGroup/CreateGroupCommandHandler.cs:23
`WebhookDeliveryService.DeliverAsync` saves `HttpHeaders`, `DbSet` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event. — src/Modules/Webhooks/Modules.Webhooks/Services/WebhookDeliveryService.cs:14
`WebhookDispatchJob.DispatchAsync` saves `HttpHeaders`, `DbSet` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event. — src/Modules/Webhooks/Modules.Webhooks/Services/WebhookDispatchJob.cs:46
What to do
Mutate one aggregate per operation and let the others follow from a domain event — the second aggregate reaching consistency a moment later is the design, not a compromise.
Other · Domain Modelling — Whether an aggregate can be constructed in a state its own rules forbid — a public constructor that takes a raw primitive, stores it, and validates nothing, with no factory beside it. A constructor taking only value objects is not counted: each parameter has already validated itself.
Method: Neutral surface (DDD-gated): each non-abstract entity/aggregate checked for a PUBLIC constructor taking at least one RAW PRIMITIVE parameter whose body contains no guard token (throw / Guard. / Ensure. / ArgumentException / CheckRule), on a type that also offers no static Create/Of/From/New factory. A constructor taking only value objects is never charged -- measured: 64 of 87 unguarded public constructors on the C# corpus take value objects only, so ignoring parameter types would be 73% false positives. One finding per entity. Deterministic.
Do you agree with this assessment?
DM12 · Ambient inputs in the domain7.4 / 10Strong✓ Tool-verified
Other · Domain Modelling — Whether domain types receive the time and randomness their rules depend on, rather than reading the process clock or a global random source directly — an ambient read makes the rule it feeds untestable at the instant that matters and lets two reads inside one operation disagree.
Method: Roslyn (DDD-gated, C#/VB only): domain-layer types scanned for ambient reads — DateTime/DateTimeOffset.Now/UtcNow/Today, Random.Shared, new Random(), Stopwatch.GetTimestamp — resolved against the semantic model, with a comment/string-stripped token fallback only where resolution fails. Body reads are scored; field/property initialisers are surfaced unscored. Apply/When folds excluded (ES1 owns them). Deterministic, symbol-resolved.
`BillingPlan` reads `DateTime.UtcNow` inside `Create`, `Update`, `Deactivate` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Billing/Modules.Billing/Domain/BillingPlan.cs:39
`Brand` reads `DateTime.UtcNow` inside `Restore`, `Create`, `Update` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:23
`Category` reads `DateTime.UtcNow` inside `Restore`, `Create`, `Update` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Catalog/Modules.Catalog/Domain/Category.cs:18
`ChannelMember` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Chat/Modules.Chat/Domain/ChannelMember.cs:16
`ChatChannel` reads `DateTime.UtcNow` inside `Archive`, `Restore`, `CreateChannel`, `CreateDirect` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Chat/Modules.Chat/Domain/ChatChannel.cs:46
`DomainEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/BuildingBlocks/Core/Domain/DomainEvent.cs:23
`FileAsset` reads `DateTime.UtcNow` inside `CreatePending`, `MarkAvailable`, `Restore`, `ChangeVisibility` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Files/Modules.Files/Domain/FileAsset.cs:40
`Invoice` reads `DateTime.UtcNow` inside `CreateDraft`, `Issue`, `MarkPaid`, `Void` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Billing/Modules.Billing/Domain/Invoice.cs:55
`Message` reads `DateTime.UtcNow` inside `Create`, `Edit`, `SoftDelete`, `Pin` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Chat/Modules.Chat/Domain/Message.cs:35
`MessageReaction` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Chat/Modules.Chat/Domain/MessageReaction.cs:18
`Notification` reads `DateTime.UtcNow` inside `Create`, `MarkRead` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Notifications/Modules.Notifications/Domain/Notification.cs:33
`PasswordChangedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Identity/Modules.Identity/Domain/Events/PasswordChangedEvent.cs:15
`Product` reads `DateTime.UtcNow` inside `Restore`, `Create`, `Update`, `ChangePrice` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:32
`ProductImage` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Catalog/Modules.Catalog/Domain/ProductImage.cs:33
`SessionRevokedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Identity/Modules.Identity/Domain/Events/SessionRevokedEvent.cs:17
`Subscription` reads `DateTime.UtcNow` inside `Create`, `Suspend`, `Reactivate`, `Cancel` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Billing/Modules.Billing/Domain/Subscription.cs:26
`TenantTheme` reads `DateTimeOffset.UtcNow` inside `Create`, `Update` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Multitenancy/Modules.Multitenancy/Domain/TenantTheme.cs:57
`Ticket` reads `DateTime.UtcNow` inside `Restore`, `Create`, `Assign`, `Resolve` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Tickets/Modules.Tickets/Domain/Ticket.cs:41
`TicketComment` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Tickets/Modules.Tickets/Domain/TicketComment.cs:27
`TopupRequest` reads `DateTime.UtcNow` inside `Create`, `MarkInvoiced`, `MarkCompleted`, `Reject` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Billing/Modules.Billing/Domain/TopupRequest.cs:21
`UsageSnapshot` reads `DateTime.UtcNow` inside `Capture` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Billing/Modules.Billing/Domain/UsageSnapshot.cs:23
`UserActivatedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Identity/Modules.Identity/Domain/Events/UserActivatedEvent.cs:15
`UserDeactivatedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Identity/Modules.Identity/Domain/Events/UserDeactivatedEvent.cs:16
`UserRegisteredEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Identity/Modules.Identity/Domain/Events/UserRegisteredEvent.cs:17
`UserRoleAssignedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Identity/Modules.Identity/Domain/Events/UserRoleAssignedEvent.cs:15
`Wallet` reads `DateTime.UtcNow` inside `Create`, `Credit`, `Debit` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Billing/Modules.Billing/Domain/Wallet.cs:21
`WalletTransaction` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has. — src/Modules/Billing/Modules.Billing/Domain/WalletTransaction.cs:18
What to do
Route the listed sites through the clock abstraction this repo already declares, so the domain's rules can be exercised at a chosen instant.
Other · Domain Modelling — How much of the domain uses strongly-typed ids vs raw Guid/string/int — adoption curve, not all-or-nothing.
Method: Roslyn (DDD-gated): strongly-typed id adoption on domain entities/events; raw Guid/int/string ids counted versus wrapped types. An id wrapper is recognised by VALUE SEMANTICS, not by being a struct — a record struct, a record class (`record ApartmentId(Guid Value)`) or a class declared by a typed-id base (`class MemberId : TypedIdValueBase`) all count, while a plain mutable class (reference equality) and a verb-phrase query record (`GetCustomerById`) do not. Deterministic, adoption percentage.
Coverage: Population: id-like members by *Id/*Key NAME suffix; strongly-typed-ID shape then checked semantically — non-suffixed identifiers are not seen.
`DomainEvent.EventId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/BuildingBlocks/Core/Domain/DomainEvent.cs:11
`DomainEvent.CorrelationId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/BuildingBlocks/Core/Domain/DomainEvent.cs:13
`DomainEvent.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/BuildingBlocks/Core/Domain/DomainEvent.cs:14
`IDomainEvent.EventId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/BuildingBlocks/Core/Domain/IDomainEvent.cs:14
`IDomainEvent.CorrelationId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/BuildingBlocks/Core/Domain/IDomainEvent.cs:24
`IDomainEvent.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/BuildingBlocks/Core/Domain/IDomainEvent.cs:29
`BillingPlan.Key` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/BillingPlan.cs:19
`Invoice.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/Invoice.cs:15
`InvoiceLineItem.InvoiceId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/InvoiceLineItem.cs:13
`Subscription.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/Subscription.cs:13
`Subscription.PlanId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/Subscription.cs:14
`TopupRequest.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/TopupRequest.cs:8
`TopupRequest.InvoiceId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/TopupRequest.cs:12
`UsageSnapshot.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/UsageSnapshot.cs:13
`Wallet.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/Wallet.cs:10
`WalletTransaction.WalletId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/WalletTransaction.cs:8
`WalletTransaction.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/WalletTransaction.cs:9
`WalletTransaction.ReferenceId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Billing/Modules.Billing/Domain/WalletTransaction.cs:13
`Category.ParentCategoryId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Catalog/Modules.Catalog/Domain/Category.cs:10
`Product.BrandId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:12
`Product.CategoryId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:13
`ProductImage.ProductId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Catalog/Modules.Catalog/Domain/ProductImage.cs:24
`ProductImage.FileAssetId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Catalog/Modules.Catalog/Domain/ProductImage.cs:25
`ProductCreatedDomainEvent.ProductId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Catalog/Modules.Catalog/Domain/Events/ProductCreatedDomainEvent.cs:6
`ProductPriceChangedDomainEvent.ProductId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Catalog/Modules.Catalog/Domain/Events/ProductPriceChangedDomainEvent.cs:6
`ProductStockAdjustedDomainEvent.ProductId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Catalog/Modules.Catalog/Domain/Events/ProductStockAdjustedDomainEvent.cs:6
`ChannelMember.ChannelId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/ChannelMember.cs:8
`ChannelMember.UserId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/ChannelMember.cs:9
`ChannelMember.LastReadMessageId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/ChannelMember.cs:12
`ChatChannel.DirectKey` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/ChatChannel.cs:25
`ChatChannel.CreatedByUserId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/ChatChannel.cs:27
`Message.ChannelId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/Message.cs:12
`Message.AuthorUserId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/Message.cs:13
`Message.ParentMessageId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/Message.cs:15
`Message.PinnedByUserId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/Message.cs:21
`MessageAttachment.MessageId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/MessageAttachment.cs:7
`MessageAttachment.FileAssetId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/MessageAttachment.cs:8
`MessageMention.MessageId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/MessageMention.cs:11
`MessageMention.MentionedUserId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/MessageMention.cs:12
`MessageReaction.MessageId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that. — src/Modules/Chat/Modules.Chat/Domain/MessageReaction.cs:11
What to do
Adopt strongly-typed ids across the domain — finish the migration or document the boundary; primitive ids invite transposed-argument bugs.
Other · Domain Modelling — Whether cross-context integration events stay loosely coupled — no producer-owned enums/domain types leaking to consumers. Shared-kernel/contracts types are allowed.
Method: Roslyn (DDD-gated): integration-event properties scanned for producer-domain type/enum leaks versus primitives and shared-kernel types. Deterministic, hard fact.
`BillingPlanDto.OverageRates` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead. — src/Modules/Billing/Modules.Billing.Contracts/Dtos/BillingPlanDto.cs:11
`InvoiceLineItemDto.Resource` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead. — src/Modules/Billing/Modules.Billing.Contracts/Dtos/InvoiceLineItemDto.cs:8
`UsageSnapshotDto.Resource` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead. — src/Modules/Billing/Modules.Billing.Contracts/Dtos/UsageSnapshotDto.cs:10
`CreatePlanCommand.OverageRates` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead. — src/Modules/Billing/Modules.Billing.Contracts/v1/Plans/CreatePlanCommand.cs:11
`UpdatePlanCommand.OverageRates` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead. — src/Modules/Billing/Modules.Billing.Contracts/v1/Plans/UpdatePlanCommand.cs:10
What to do
Keep integration events to primitives + shared-contract types; never reference a producer-domain enum or type, so services evolve independently.
Do you agree with this assessment?
DM4 · Rich vs anemic model10.0 / 10Exemplary✓ Tool-verified
Other · Domain Modelling — Whether aggregates/entities carry the behaviour that protects their invariants, rather than being data bags driven by external services.
Method: Roslyn (DDD-gated): entity method BODIES classified mutator-vs-query — only methods that mutate the entity's own declared state count as invariant-protecting behaviour, so a getter/passthrough doesn't rescue an anemic class. Deterministic, exhaustive over domain-layer entities.
Coverage: Population: entities by name/base convention; rich-vs-anemic judged by classifying each method body mutator-vs-query — logic-bearing domain types outside the convention are invisible.
Other · Domain Modelling — Whether entities protect their state — private/init-only setters, and collections handed out as read-only views rather than the mutable backing collection — instead of exposing writable state that bypasses invariants. Softened when a rehydration framework (Marten/EF) is present.
Method: Roslyn (DDD-gated): entities scanned for publicly writable state — public setters, and (C#/VB) own mutable collections handed out through an auto-property, a public field or a bare-field expression getter, where a computed/copying getter is never charged. One finding per entity; score softened when Marten/EF rehydration frameworks present. Deterministic, framework-aware.
Coverage: Population: entities by convention; encapsulation (setter shape) checked exhaustively within the set.
`TenantTheme` exposes publicly writable state (PrimaryColor, SecondaryColor, TertiaryColor, BackgroundColor, SurfaceColor, ErrorColor, and 22 more). — src/Modules/Multitenancy/Modules.Multitenancy/Domain/TenantTheme.cs:5
What to do
Make entity setters private/init-only and hand collections out as IReadOnlyList/IReadOnlyCollection over a private backing field; change state only through methods that enforce the invariants (Marten/EF can bind via constructor or private setters).
Other · Domain Modelling — Whether the domain layer stays free of infrastructure dependencies (EF/Marten/HTTP/ASP.NET) — the clean-architecture dependency rule.
Method: Roslyn (DDD-gated): domain-layer types scanned for infrastructure usage in member SIGNATURES and inside method/accessor BODIES — resolved calls and object-creations into EF/Marten/HTTP/Mongo/Redis/message-bus types (not just a namespace allowlist). Deterministic, symbol-resolved, exhaustive over domain-layer bodies, DDD-native.
Coverage: Domain layer identified by NAMESPACE heuristic; infrastructure then resolved by symbol in member SIGNATURES and method/accessor BODIES — rename the layer and the check evaporates.
Other · Domain Modelling — Whether clusters of primitives that travel together (a missing value object) are extracted — a low-weight suggestion, LLM-confirmed when configured.
Method: Roslyn (DDD-gated): primitive parameter clusters recurring three or more times across signatures extracted, then confirmed by language model when configured. Advisory, low-weight.
The parameters [authoruserid, channelid, eventid, messageid] travel together across 4 signatures — that's a missing value object. Extracting them into one type (e.g. `Address`, `Money`, `Coordinate`) removes repetition, prevents argument-order mistakes, and gives the concept a home for its rules. — src/Modules/Chat/Modules.Chat/Domain/Events/MessageDeletedDomainEvent.cs:5
What to do
Extract recurring primitive parameter clusters into value objects so the concept (and its rules) lives in one place.
Other · Domain Modelling — Whether one domain rule is decided — or one measurement produced — in more than one place, rather than living on the type that owns it.
Method: Neutral body surface plus Roslyn (DDD-gated), two arms. DECISION (Roslyn only): a predicate over a domain type's members judged in two or more types, where none of those decisions live on the owning type — operands of comparisons and relational property patterns only, so a member merely passed as an argument is not judged. DERIVATION: a plain all-numeric carrier of ≥2 members, with no base type and exactly one constructor, CONSTRUCTED as the result of a method (returned or assigned, never inline as an argument) in two or more types other than its own — the same measurement produced twice, which centralising the judgement does not fix. DERIVATION runs on every language whose frontend declares the produced-or-passed fact per construction (Roslyn and the Java sidecar today); a target with only the derivation arm carries an engine gap naming the decision arm as not assessed, and a frontend that declares nothing keeps the dimension not measured rather than clean. Single-member rules, test code and generated code are out of population for both. Advisory.
FSH.Modules.Billing.Domain.Subscription's [Status, TenantId] are judged in FSH.Modules.Billing.Features.v1.Subscriptions.AssignSubscription.AssignSubscriptionCommandHandler, FSH.Modules.Billing.Features.v1.Subscriptions.GetSubscription.GetSubscriptionQueryHandler, FSH.Modules.Billing.IntegrationEventHandlers.TenantSubscriptionMaintenance, FSH.Modules.Billing.Services.BillingService — the same decision, restated. Every copy is a chance to drift, and copies drift silently because each one looks correct on its own. Move the judgement onto the type that owns the members and let the call sites ask it.
FSH.Modules.Chat.Domain.Message's [ChannelId, DeletedAtUtc] are judged in FSH.Modules.Chat.Features.v1.Channels.GetChannelById.GetChannelByIdQueryHandler, FSH.Modules.Chat.Features.v1.Channels.ListMyChannels.ListMyChannelsQueryHandler — the same decision, restated. Every copy is a chance to drift, and copies drift silently because each one looks correct on its own. Move the judgement onto the type that owns the members and let the call sites ask it.
Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>'s [ClaimType, RoleId] are judged in FSH.Modules.Identity.Authorization.RolePermissionSyncer, FSH.Modules.Identity.Features.v1.Roles.RoleService — the same decision, restated. Every copy is a chance to drift, and copies drift silently because each one looks correct on its own. Move the judgement onto the type that owns the members and let the call sites ask it.
FSH.Modules.Notifications.Domain.Notification's [ReadAtUtc, UserId] are judged in FSH.Modules.Notifications.Features.v1.GetUnreadCount.GetUnreadCountQueryHandler, FSH.Modules.Notifications.Features.v1.MarkAllNotificationsRead.MarkAllNotificationsReadCommandHandler — the same decision, restated. Every copy is a chance to drift, and copies drift silently because each one looks correct on its own. Move the judgement onto the type that owns the members and let the call sites ask it.
What to do
Move each repeated judgement onto the type that owns the members it reads, so the rule has one home and cannot drift.
Other · Event-Driven — Whether event handlers stay asynchronous (no blocking remote HTTP/gRPC calls awaited inside a handler).
Method: Roslyn semantic scan (event-driven gated): event-handler bodies scanned for HTTP/gRPC invocations by resolved symbol type, not substring. Deterministic, semantic-resolved.
Other · Event-Driven — Whether commands have a single handler (one owner of the decision) and fan-out is modelled with events.
Method: Roslyn scan (event-driven gated): command-shaped messages identified by convention; handler count per command checked for the exactly-one rule. Deterministic, hard fact.
Do you agree with this assessment?
ED3 · Event naming7.5 / 10Strong✓ Tool-verified
Other · Event-Driven — Whether events are named in the past tense (a clarity nudge — low weight).
Method: Roslyn scan (event-driven gated): domain and integration events checked for past-tense naming (-ed/-en suffix or irregular set). Naming nudge, low-weight advisory.
`ActivityEventPayload` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/ActivityEventPayload.cs:3
`AuditEventType` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:8
`AuditSeverity` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:20
`SecurityAction` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:34
`EntityOperation` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:53
`ActivityKind` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:66
`ExceptionArea` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:79
`BodyCapture` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:92
`AuditTag` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:105
`AuditEnvelope` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnvelope.cs:9
`AuditHttpOptions` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditHttpOptions.cs:3
`AuditingContractsMarker` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditingContractsMarker.cs:4
`AuditRetentionOptions` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/AuditRetentionOptions.cs:10
`EntityChangeEventPayload` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/EntityChangeEventPayload.cs:3
`ExceptionEventPayload` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/ExceptionEventPayload.cs:3
`ExceptionSeverityClassifier` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/ExceptionSeverityClassifier.cs:3
`MaskingResult` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/IAuditMaskingService.cs:10
`NoAuditAttribute` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/NoAuditAttribute.cs:26
`NoAuditEndpointExtensions` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/NoAuditEndpointExtensions.cs:8
`NumericEnumConverter` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/NumericEnumConverter.cs:15
`PropertyChange` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/PropertyChange.cs:6
`SecurityEventPayload` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/SecurityEventPayload.cs:3
`AuditingPermissions` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/Authorization/AuditingPermissions.cs:5
`AuditTrails` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/Authorization/AuditingPermissions.cs:7
`AuditDetailDto` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditDetailDto.cs:6
`AuditSummaryAggregateDto` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditSummaryAggregateDto.cs:5
`AuditSummaryDto` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditSummaryDto.cs:5
`GetAuditByIdQuery` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/v1/GetAuditById/GetAuditByIdQuery.cs:6
`GetAuditsQuery` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/v1/GetAudits/GetAuditsQuery.cs:8
`GetAuditsByCorrelationQuery` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/v1/GetAuditsByCorrelation/GetAuditsByCorrelationQuery.cs:6
`GetAuditsByTraceQuery` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/v1/GetAuditsByTrace/GetAuditsByTraceQuery.cs:6
`GetAuditSummaryQuery` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/v1/GetAuditSummary/GetAuditSummaryQuery.cs:6
`GetExceptionAuditsQuery` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/v1/GetExceptionAudits/GetExceptionAuditsQuery.cs:7
`GetSecurityAuditsQuery` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Auditing/Modules.Auditing.Contracts/v1/GetSecurityAudits/GetSecurityAuditsQuery.cs:7
`BillingContractsMarker` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Billing/Modules.Billing.Contracts/BillingContractsMarker.cs:6
`InvoiceStatus` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Billing/Modules.Billing.Contracts/BillingEnums.cs:3
`SubscriptionStatus` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Billing/Modules.Billing.Contracts/BillingEnums.cs:11
`InvoiceLineItemKind` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Billing/Modules.Billing.Contracts/BillingEnums.cs:18
`PlanInterval` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Billing/Modules.Billing.Contracts/BillingEnums.cs:25
`InvoicePurpose` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear. — src/Modules/Billing/Modules.Billing.Contracts/BillingEnums.cs:31
What to do
Name events in the past tense — they record facts that already happened.
Other · Event-Driven — Whether state changes and message publishes are atomic (a transactional outbox) rather than a crash-unsafe dual write.
Method: Roslyn semantic scan (event-driven gated): event-handler methods scanned for DB-save plus bus-publish without a transactional outbox reference. Deterministic, semantic-resolved.
`SendMessageCommandHandler.Handle` writes to the database AND publishes to the message bus in the same flow, with no outbox referenced in this path. These two writes aren't atomic — a crash between them either loses the message (DB committed, publish failed) or emits a phantom event (publish succeeded, DB rolled back). Use the transactional outbox pattern — write the message to an outbox table in the SAME transaction as the state change, and dispatch it from there afterwards — or your platform's equivalent (a broker transaction, or an outbox library from your own ecosystem). — src/Modules/Chat/Modules.Chat/Features/v1/Messages/SendMessage/SendMessageCommandHandler.cs:28
`CreateTenantCommandHandler.Handle` writes to the database AND publishes to the message bus in the same flow, with no outbox referenced in this path. These two writes aren't atomic — a crash between them either loses the message (DB committed, publish failed) or emits a phantom event (publish succeeded, DB rolled back). Use the transactional outbox pattern — write the message to an outbox table in the SAME transaction as the state change, and dispatch it from there afterwards — or your platform's equivalent (a broker transaction, or an outbox library from your own ecosystem). — src/Modules/Multitenancy/Modules.Multitenancy/Features/v1/CreateTenant/CreateTenantCommandHandler.cs:23
`RenewTenantCommandHandler.Handle` writes to the database AND publishes to the message bus in the same flow, with no outbox referenced in this path. These two writes aren't atomic — a crash between them either loses the message (DB committed, publish failed) or emits a phantom event (publish succeeded, DB rolled back). Use the transactional outbox pattern — write the message to an outbox table in the SAME transaction as the state change, and dispatch it from there afterwards — or your platform's equivalent (a broker transaction, or an outbox library from your own ecosystem). — src/Modules/Multitenancy/Modules.Multitenancy/Features/v1/RenewTenant/RenewTenantCommandHandler.cs:19
What to do
Adopt the transactional outbox pattern so DB writes and message publishes commit atomically — no lost or phantom events on a crash.
Other · Readiness — Whether retry-prone mutations (command handlers + message/event consumers) are idempotent so an at-least-once redelivery or client retry doesn't double-apply the effect — heuristic at-risk detection confirmed by language model, advisory.
Method: Roslyn heuristic (any mutation, ungated): command handlers and message/event consumers that mutate persistent state without a visible idempotency guard (exists/dedup check, upsert, idempotency-key/inbox, conditional/versioned write, fixed-value set) flagged as at-risk; each at-risk candidate then confirmed or cleared by a language model as genuinely non-idempotent versus naturally-idempotent. Advisory without a model (heuristic-only, degraded), per-candidate judged with one.
Coverage: Population: retry-prone mutations — command handlers (CQRS write side) + message/event consumers (IConsumer/I*EventHandler) — that mutate persistent state; runs on any repo with mutations, not only event-driven ones. The at-risk subset (no obvious guard) is a HEURISTIC candidate set, each then LLM-JUDGED non-idempotent vs safe; a handler outside those conventions, or a guard the LLM can't confirm, is bounded by the sample. Degrades to heuristic-only when no model is configured.
Other · Code Health — Unreviewed-generation residue: shipped members still throwing NotImplementedException, and placeholder string literals left in 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: members that only throw a "not implemented" exception, methods that take inputs and return a constant, async methods that never await, dead `if (false)` / `#if false` branches, and skeleton types most of whose members are holes. A real, objective slice of technical debt.
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.
A test is skipped ("Idempotency replay does not engage in the test environment — IDistributedCache (probe) and HybridCache (write-through) are wired to separate in-process stores, so the second call never sees the cached response. Same caveat as IdempotencyFilterTests.cs: 'full replay-with-matching-body coverage is not yet possible'. Backlog item 2.4b tracks the fix.") — coverage that looks present but never runs in any gate. If it's an opt-in suite, document how it runs; otherwise re-enable or delete it. — src/Tests/Integration.Tests/Tests/Chat/ChatSendMessageTests.cs:74
What to do
Clear the softer debt: remove commented-out code and dead branches, re-enable or delete skipped tests, and replace blanket warning suppressions with targeted ones.
Maturity · Maturity — Whether the repo and its projects have a README, and whether it's substantive and current.
Method: Filesystem scan: README presence, word count, and headings for depth; git history for staleness. Exhaustive across root and project dirs, deterministic.
What to do
Add a README to the 49 of 50 project(s) that lack one — worth up to 2 pts.
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 significant decisions one document per decision — dated, stating the context, the decision and its consequences — and keep them together wherever your design docs already live (a conventional `docs/adr/` tree, with each file named `NNNN-title` in whatever markup those docs already use, is the most discoverable form).
Maturity · Maturity — Whether the README actually describes the code that exists (LLM-judged, advisory).
Method: Judged by language model at low temperature: README accuracy versus actual projects, within a disclosed tolerance. Advisory, not a measured number.
Readiness · Readiness — Whether an automated pipeline builds and tests every change.
Method: Filesystem scan: CI workflow files (.github/workflows, .gitlab-ci.yml, etc.) for build and test stages. Exhaustive, deterministic.
Do you agree with this assessment?
P10 · Library API & versioning6.0 / 10Strong✓ Tool-verified
Readiness · Readiness — For a library: a deliberate (small) public API surface and explicit semantic versioning so consumers can depend on it safely.
Method: Roslyn scan: public API surface area and semantic-versioning markers (SemVer attributes, changelog entries) for libraries. Exhaustive, deterministic.
1358/1666 types (82%) are public. For a library, every public type is a stability contract — make internal-by-default and expose only the intended API.
What to do
Make types internal by default; expose only the deliberate public API so internals can change without breaking consumers.
Only 19/24 service-like projects use logging (pure contract/DTO projects are excluded — they have nothing to log). Of those 24, 4 ship a process this repository operates; the rest are libraries their consumer hosts, where the logging decision belongs to the host.
What to do
Extend structured logging across the projects you operate, and give the library ones a diagnostics seam instead — an `EventSource`/`ActivitySource` the host can subscribe to, or an optional logger on your options object — rather than taking a logging dependency on your consumers' behalf.
Readiness · Readiness — Whether SAST, secret/dependency scanning and performance benchmarking are wired in (presence, not runtime).
Method: Filesystem scan: SAST configuration, dependency-update automation, secret scanning, and a benchmark harness or benchmark step — in this repository's own ecosystem. Exhaustive, deterministic.
What to do
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.
Deployment is automated and no gate that pauses it for a human is DECLARED IN THIS REPOSITORY'S PIPELINE FILES. What was read: every file under `.github/workflows/`, `.forgejo/workflows/`, `.gitea/workflows/`, `.azuredevops/` and `.azure-pipelines/`, plus `.gitlab-ci*` and `azure-pipelines*` — with comment text stripped, so documenting a gate is not declaring one. What would have counted: GitLab's `when: manual`, CircleCI's `type: approval`, an Azure `ManualValidation@` task or an `approvals:` block, a Jenkins `input` step, a `uses:` step naming an approval action, an `environment:` paired with `reviewers` / `required_reviewers` / `protection` / `wait-timer` / `deployment_branch_policy`, a draft-release step, a `workflow_dispatch` promotion, or a release-event gate. ★ What this cannot see, because none of it is a file: a GitHub environment whose required reviewers are configured in repo SETTINGS, a branch protection rule, or an organisation deployment policy — all of them real, enforced gates that live outside the repository. If yours is one of those, this row is wrong and nothing in the tree could have told us. Otherwise: whatever reaches the release trigger goes to production unreviewed, so a mistaken merge or tag is live before anyone can stop it.
What to do
Add an approval/environment gate (required reviewers / protection rules) before production promotion.
Do you agree with this assessment?
P5 · DR & Backup7.0 / 10Strong✓ Tool-verified
Readiness · Readiness — Whether disaster recovery is planned and codified — backups, geo-recovery, RTO/RPO, persistence guarantees — from IaC + container manifests + docs, never the live cloud.
Method: Filesystem scan: disaster recovery, backup, geo-recovery, RTO/RPO, persistence guarantees from IaC, manifests, and docs. Exhaustive, deterministic, never a live environment.
What to do
Document RTO/RPO and a tested restore procedure (a backup config alone isn't disaster recovery).
Readiness · Performance — Whether the code protects its performance with benchmarks — a benchmark suite, allocation/memory measurement, and (ideally) a CI gate. Presence is credited as a bonus, never a deduction.
Method: Repo + source scan: BenchmarkDotNet referenced (csproj/source), [Benchmark]/[MemoryDiagnoser] attribute counts, and a benchmark step in CI — scored as a bonus ladder (absence is neutral, never a deduction). Deterministic, presence detection.
No benchmark suite was found by the two searches this check runs. FIRST, a BenchmarkDotNet package reference in any project file — every project the workspace loaded, plus a walk of project files on disk that never loaded, because a benchmark suite is exactly the project a partial load drops. SECOND, a script harness: a file whose name contains `benchmark` and ends `.py`, `.sh`, `.ps1`, `.bash`, `.rb`, `.js` or `.mjs`, credited ONLY when this repository's CI text also mentions benchmarks — a harness no pipeline runs is read as a fixture, deliberately. Neither search can see a benchmark suite in another ecosystem's idiom (a Go `testing.B` file, a JMH or criterion project, a pytest-benchmark run), so this is 'no benchmark found by those two searches', not a verdict that the repository has none. Where code is performance-sensitive, a benchmark guards against silent regressions — but it's a bonus here, not a deduction.
What to do
Add a benchmarking harness for the hot paths and run it in CI to catch regressions (for .NET, a BenchmarkDotNet project with [MemoryDiagnoser] to track allocations).
Readiness · Performance — Whether the code is written to minimise allocations so it doesn't pressure its host's memory manager — buffer/slice views over copies, object pooling, stack or value-type allocation, and buffer writers. Reward-only: credited where present, never penalised where a simpler style is fine.
Raise allocation-aware density on the hot paths — currently 287 use(s) across 62,788 production line(s) (~4.6/1k). More Span/Memory, pooling (ArrayPool/ObjectPool), stackalloc and ValueTask on the allocation-heavy paths climbs this toward 10.
Readiness · Performance — Whether asynchronous code stays responsive — it avoids sync-over-async blocking (.Wait()/.GetAwaiter().GetResult()) that wastes threads and risks deadlock, and, where the code is a reusable library, awaits with ConfigureAwait(false) so it never captures and stalls its caller's context.
Method: Production-source scan: sync-over-async blocking (.Wait()/.GetAwaiter().GetResult()) counted everywhere, and — for a library with ≥5 awaits — the share of awaits using ConfigureAwait(false). Deterministic, syntax/text detection.
Do you agree with this assessment?
R1 · Type Safety10.0 / 10Exemplary✓ Tool-verified
React / JS · Code Health — How much of the frontend is typed TypeScript vs untyped JavaScript.
Method: Frontend file inventory: the share of typed TypeScript vs untyped JavaScript across the source tree. Deterministic, exhaustive over frontend files.
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.
119 duplicated blocks under clients/ have copies in at least two of the sibling directories admin, dashboard — 96 of them are reported below, and 23 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 119 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 119 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 119 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. — clients/admin/src/components/tenants/tenant-branding-card.tsx:2
24 duplicated blocks under clients/dashboard/src/pages/ have copies in at least two of the sibling directories catalog, chat, files, identity, settings, system (+1 more sibling(s) not listed) — 15 of them are reported below, and 9 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 24 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 24 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 24 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. — clients/dashboard/src/pages/system/sessions.tsx:58
18 duplicated blocks under clients/admin/src/pages/ have copies in at least two of the sibling directories audits, billing, health, impersonation, notifications, roles (+4 more sibling(s) not listed) — 11 of them are reported below, and 7 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 18 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 18 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 18 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. — clients/admin/src/pages/tenants/list.tsx:41
13 duplicated blocks under clients/admin/src/ have copies in at least two of the sibling directories components, pages — 6 of them are reported below, and 7 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 13 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 13 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 13 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. — clients/admin/src/components/sessions/user-sessions-card.tsx:182
13 duplicated blocks under clients/dashboard/src/ have copies in at least two of the sibling directories components, lib, pages — 8 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 13 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 13 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 13 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. — clients/dashboard/src/components/list/entity-shell.tsx:136
9 duplicated blocks under clients/admin/src/components/ have copies in at least two of the sibling directories billing, impersonation, list, roles, tenants, ui (+2 more sibling(s) not listed) — 6 of them are reported below, and 3 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 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. — clients/admin/src/components/list/select.tsx:10
clients/dashboard/src/pages/catalog/brands.tsx:66 · clients/dashboard/src/pages/catalog/categories.tsx:92 — the two spans are one implementation copied and then locally edited — 1849 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. — clients/dashboard/src/pages/catalog/brands.tsx:66
clients/dashboard/src/pages/catalog/product-detail.tsx:781 · clients/dashboard/src/pages/catalog/products.tsx:975 — the two spans are one implementation copied and then locally edited — 1544 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. — clients/dashboard/src/pages/catalog/product-detail.tsx:781
clients/admin/src/components/tenants/tenant-branding-card.tsx:2 · clients/dashboard/src/pages/settings/branding.tsx:2 — these 2 files are line-for-line copies of one another — 263 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/components/tenants/tenant-branding-card.tsx:2
clients/admin/src/components/layout/topbar.tsx:44 · clients/dashboard/src/components/layout/topbar.tsx:51 — the two spans are one implementation copied and then locally edited — 1065 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. — clients/admin/src/components/layout/topbar.tsx:44
clients/dashboard/src/pages/catalog/categories.tsx:217 · clients/dashboard/src/pages/catalog/products.tsx:329 — the two spans are one implementation copied and then locally edited — 869 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. — clients/dashboard/src/pages/catalog/categories.tsx:217
clients/admin/src/components/layout/sidebar.tsx:2 · clients/dashboard/src/components/layout/sidebar.tsx:2 — these 2 files are line-for-line copies of one another — 168 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/components/layout/sidebar.tsx:2
clients/admin/src/hooks/use-file-upload.ts:1 · clients/dashboard/src/hooks/use-file-upload.ts:1 — these 2 files are line-for-line copies of one another — 162 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/hooks/use-file-upload.ts:1
clients/dashboard/src/pages/identity/roles.tsx:87 · clients/dashboard/src/pages/identity/users.tsx:144 — the two spans are one implementation copied and then locally edited — 686 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. — clients/dashboard/src/pages/identity/roles.tsx:87
clients/admin/src/pages/tenants/list.tsx:41 · clients/admin/src/pages/users/list.tsx:79 — the two spans are one implementation copied and then locally edited — 880 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. — clients/admin/src/pages/tenants/list.tsx:41
clients/admin/src/pages/settings/layout.tsx:64 · clients/dashboard/src/pages/settings/settings-layout.tsx:62 — 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. — clients/admin/src/pages/settings/layout.tsx:64
clients/dashboard/src/pages/identity/groups.tsx:191 · clients/dashboard/src/pages/identity/roles.tsx:214 — the two spans are one implementation copied and then locally edited — 617 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. — clients/dashboard/src/pages/identity/groups.tsx:191
clients/admin/src/components/file/image-input.tsx:2 · clients/dashboard/src/components/file/image-input.tsx:2 — these 2 files are line-for-line copies of one another — 118 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/components/file/image-input.tsx:2
clients/admin/src/lib/api-client.ts:4 · clients/dashboard/src/lib/api-client.ts:5 — the two spans are one implementation copied and then locally edited — 789 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. — clients/admin/src/lib/api-client.ts:4
clients/admin/src/pages/billing/invoices-list.tsx:29 · clients/admin/src/pages/billing/topups-list.tsx:45 — the two spans are one implementation copied and then locally edited — 718 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. — clients/admin/src/pages/billing/invoices-list.tsx:29
clients/admin/src/realtime/realtime-context.tsx:40 · clients/dashboard/src/realtime/realtime-context.tsx:50 — the 2 copies are spread across 2 files, and the CITED SPAN is inside a TYPE DECLARATION, not executable code. There is no function to extract and no call site to call one from, so do not read this as an extract-a-helper row: the collapse a type offers is a generic — name the shape once, parameterised over the part that varies, and have each copy instantiate it. First check what actually differs between the copies: where they are a MATRIX of cases (one entry per input, differing precisely in the case each one pins), the repetition IS the enumeration and collapsing it would delete cases rather than de-duplicate anything — leave those alone. Reported because the copies that are not a matrix drift apart the first time only one of them is edited. — clients/admin/src/realtime/realtime-context.tsx:40
clients/dashboard/src/pages/system/sessions.tsx:58 · clients/dashboard/src/pages/tickets/tickets.tsx:89 — the two spans are one implementation copied and then locally edited — 627 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. — clients/dashboard/src/pages/system/sessions.tsx:58
clients/dashboard/src/pages/identity/groups.tsx:52 · clients/dashboard/src/pages/identity/roles.tsx:54 — the two spans are one implementation copied and then locally edited — 629 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. — clients/dashboard/src/pages/identity/groups.tsx:52
clients/admin/src/pages/billing/invoices-list.tsx:254 · clients/admin/src/pages/billing/topups-list.tsx:271 — the two spans are one implementation copied and then locally edited — 620 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. — clients/admin/src/pages/billing/invoices-list.tsx:254
clients/admin/src/components/list/select.tsx:10 · clients/admin/src/components/ui/select.tsx:10 — the two spans are one implementation copied and then locally edited — 426 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. — clients/admin/src/components/list/select.tsx:10
clients/admin/src/components/roles/create-role-dialog.tsx:38 · clients/admin/src/components/users/create-user-dialog.tsx:78 — the two spans are one implementation copied and then locally edited — 480 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. — clients/admin/src/components/roles/create-role-dialog.tsx:38
clients/admin/src/components/ui/dialog.tsx:1 · clients/dashboard/src/components/ui/dialog.tsx:1 — these 2 files are line-for-line copies of one another — 98 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/components/ui/dialog.tsx:1
clients/dashboard/src/pages/identity/roles.tsx:238 · clients/dashboard/src/pages/tickets/tickets.tsx:340 — the two spans are one implementation copied and then locally edited — 442 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. — clients/dashboard/src/pages/identity/roles.tsx:238
clients/admin/src/api/files.ts:1 · clients/dashboard/src/api/files.ts:1 — these 2 files are line-for-line copies of one another — 89 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/api/files.ts:1
clients/admin/src/auth/use-inactivity-timeout.ts:1 · clients/dashboard/src/auth/use-inactivity-timeout.ts:1 — these 2 files are line-for-line copies of one another — 82 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/auth/use-inactivity-timeout.ts:1
clients/admin/src/components/auth/inactivity-dialog.tsx:1 · clients/dashboard/src/components/auth/inactivity-dialog.tsx:1 — these 2 files are line-for-line copies of one another — 82 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/components/auth/inactivity-dialog.tsx:1
clients/admin/src/auth/auth-context.tsx:82 · clients/dashboard/src/auth/auth-context.tsx:134 — the two spans are one implementation copied and then locally edited — 429 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. — clients/admin/src/auth/auth-context.tsx:82
clients/dashboard/src/pages/catalog/brands.tsx:282 · clients/dashboard/src/pages/catalog/products.tsx:608 — the two spans are one implementation copied and then locally edited — 283 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. — clients/dashboard/src/pages/catalog/brands.tsx:282
clients/admin/src/components/ui/avatar.tsx:1 · clients/dashboard/src/components/ui/avatar.tsx:1 — these 2 files are line-for-line copies of one another — 72 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/components/ui/avatar.tsx:1
clients/admin/src/pages/roles/list.tsx:62 · clients/admin/src/pages/users/list.tsx:109 — the two spans are one implementation copied and then locally edited — 361 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. — clients/admin/src/pages/roles/list.tsx:62
clients/admin/src/components/ui/dropdown-menu.tsx:1 · clients/dashboard/src/components/ui/dropdown-menu.tsx:1 — these 2 files are line-for-line copies of one another — 71 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done. — clients/admin/src/components/ui/dropdown-menu.tsx:1
clients/admin/src/pages/login.tsx:206 · clients/dashboard/src/pages/login.tsx:155 — 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. — clients/admin/src/pages/login.tsx:206
clients/admin/src/api/billing.ts:135 · clients/dashboard/src/api/billing.ts:33 — the two spans are one implementation copied and then locally edited — 467 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. — clients/admin/src/api/billing.ts:135
clients/admin/src/components/ui/button.tsx:20 · clients/dashboard/src/components/ui/button.tsx:12 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are. — clients/admin/src/components/ui/button.tsx:20
clients/admin/src/components/layout/mobile-nav.tsx:76 · clients/dashboard/src/components/layout/mobile-nav.tsx:65 — the two spans are one implementation copied and then locally edited — 300 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. — clients/admin/src/components/layout/mobile-nav.tsx:76
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.
UserDetailPage has cyclomatic complexity 55 and cognitive complexity 53; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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. — clients/dashboard/src/pages/identity/user-detail.tsx:84
InvoiceDetailPage has cyclomatic complexity 41 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 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. — clients/admin/src/pages/billing/invoice-detail.tsx:73
TenantDetailPage has cyclomatic complexity 40 and cognitive complexity 35; 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. — clients/admin/src/pages/tenants/detail.tsx:50
OverviewPage has cyclomatic complexity 40 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — clients/dashboard/src/pages/overview.tsx:942
Message has cyclomatic complexity 39 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 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. — clients/dashboard/src/pages/chat/message.tsx:54
RoleDetailPage has cyclomatic complexity 35 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. — clients/dashboard/src/pages/identity/role-detail.tsx:66
AuditsListPage has cyclomatic complexity 33 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 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. — clients/admin/src/pages/audits/list.tsx:40
UserDetailPage has cyclomatic complexity 33 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 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. — clients/admin/src/pages/users/detail.tsx:26
ResetPasswordPage has cyclomatic complexity 29 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 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. (×2) — clients/admin/src/pages/auth/reset-password.tsx:44, clients/dashboard/src/pages/auth/reset-password.tsx:71
UsersListPage has cyclomatic complexity 29 and cognitive complexity 22; 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. — clients/admin/src/pages/users/list.tsx:29
WebhookDetailPage has cyclomatic complexity 28 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 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. — clients/admin/src/pages/webhooks/detail.tsx:42
AuditsPage has cyclomatic complexity 26 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. — clients/dashboard/src/pages/audits.tsx:187
GroupDetailPage has cyclomatic complexity 24 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 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. — clients/dashboard/src/pages/identity/group-detail.tsx:74
TopupsListPage has cyclomatic complexity 24 and cognitive complexity 23; 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. — clients/admin/src/pages/billing/topups-list.tsx:96
apiFetch has cyclomatic complexity 23 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 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. — clients/admin/src/lib/api-client.ts:108
StepRow has cyclomatic complexity 23 and cognitive complexity 21; 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. — clients/admin/src/pages/tenants/detail.tsx:542
TenantsListPage has cyclomatic complexity 23 and cognitive complexity 18; 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. — clients/admin/src/pages/tenants/list.tsx:25
ProductEditorDialog has cyclomatic complexity 23 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. — clients/dashboard/src/pages/catalog/products.tsx:811
apiFetch has cyclomatic complexity 22 and cognitive complexity 23; 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. — clients/dashboard/src/lib/api-client.ts:155
What to do
Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5.
Do you agree with this assessment?
R3 · Large Files3.9 / 10Weak✓ 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.
39 file(s) over 400 lines (counted as significant lines — blank lines excluded — over production source only, tests excluded), largest first: clients/dashboard/src/pages/audits.tsx (1333), clients/dashboard/src/pages/catalog/products.tsx (1332), clients/dashboard/src/pages/overview.tsx (1208), clients/dashboard/src/pages/catalog/product-detail.tsx (1089), clients/dashboard/src/pages/identity/role-detail.tsx (1041), clients/dashboard/src/pages/chat/message.tsx (970) (+33 more).
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.
What to do
Bump outdated dependencies to current versions to limit upgrade debt.
Do you agree with this assessment?
R6 · Tooling10.0 / 10Exemplary✓ Tool-verified
React / JS · Readiness — Whether the project wires up test, lint and typecheck — detected from each package.json script's COMMAND (eslint / tsc / vitest / jest / playwright), not just its name, and corroborated against CI-workflow invocations so a tool run only in CI still counts.
Method: package.json scanned for test/lint/typecheck script wiring. Deterministic presence check.
Do you agree with this assessment?
R7 · Dead Code8.4 / 10Exemplary✓ Tool-verified
React / JS · Code Health — Files unreachable from every application/tooling/test entry point, and exports nothing imports (module-graph reachability, D-386).
Method: Dead code: files unreachable from every application/tooling/test entry point plus exports nothing imports, via module-graph reachability. Deterministic, exhaustive over the import graph.
Unreachable from the 32 application, 6 tooling and 61 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, 6 tooling, 61 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 (×8) — clients/admin/src/components/auth/auth-shell.tsx, clients/admin/src/components/ui/table.tsx, clients/admin/src/components/ui/switch.tsx, …
no import path from any entry point (32 application, 6 tooling, 61 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (clients/admin/src/components/auth/auth-shell.tsx) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — clients/admin/src/components/brand-mark.tsx
Nothing imports this binding — it is safe to review for removal. (×26) — clients/admin/src/api/billing.ts:116, clients/admin/src/api/billing.ts:123, clients/admin/src/api/billing.ts:229, …
Nothing ultimately consumes this binding: its only referrer is the re-export in clients/admin/src/components/list/index.ts, whose re-exported name has no consumer either. Removing it is therefore not a one-file change — drop the re-export line in clients/admin/src/components/list/index.ts in the same commit, or the barrel will import a name that no longer exists. — clients/admin/src/components/list/form-shell.tsx:88
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.
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 · Security — Transport security, security headers, secure cookies, input validation, middleware order and crypto hygiene (presence, not runtime).
Other · Code Health — Whether the code avoids sync-over-async (deadlock-prone blocking on tasks) and async void.
Method: Roslyn syntax scan: async methods scanned for .Wait()/.GetAwaiter().GetResult() and async-void outside event handlers. Deterministic, hard fact per invocation.
Other · Code Health — Whether any branch is dead by construction — a switch arm whose label can never equal a case-normalised subject, or an `else if` whose predicate the arm above has already swallowed.
Method: Roslyn syntax + semantics: switch labels compared against the subject's own case normaliser, and if/else-if chains checked for a literal an earlier arm's containment test already swallows. Deterministic, provable per finding. Advisory.
Do you agree with this assessment?
X13 · Undrained process stream10.0 / 10Exemplary○ Nothing flagged
Other · Code Health — Whether a child process that has BOTH standard streams redirected drains both — reading one to the end while the other is never read deadlocks once the child fills the unread pipe.
Method: Roslyn syntax + semantics: ProcessStartInfo launches with both streams redirected, checked for a drain of each stream across the enclosing type. Deterministic, provable per finding. Advisory.
Other · Security — Whether a hand-rolled public/private IP check can be walked past — a method that unwraps IPv4-mapped IPv6 but returns the opposite verdict for the same host written as IPv4-compatible, 6to4 or NAT64.
Method: Roslyn syntax + semantics: methods that unwrap IPv4-mapped IPv6 and hand-roll IPv4 range carve-outs, checked for whether the IPv6 branch also accounts for the IPv4-compatible, 6to4 and NAT64 embeddings. Deterministic, provable per finding. Advisory.
Do you agree with this assessment?
X15 · Unvalidated length from an untrusted reader10.0 / 10Exemplary○ Nothing flagged
Other · Security — Whether a length read out of the stream being parsed is bounded before it is allocated or read — an unchecked count taken from the input lets the input choose the allocation.
Method: Roslyn syntax + semantics: integer lengths read from a BinaryReader and spent on a bulk read or an array allocation, checked for any comparison or bounding call on the value anywhere in the method. Deterministic, provable per finding. Advisory.
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. Deterministic, provable per finding. Advisory.
Do you agree with this assessment?
X17 · Uncapped recursion over a caller-supplied document10.0 / 10Exemplary○ Nothing flagged
Other · Security — Whether a walk that recurses through a JSON/XML tree handed in by its caller bounds how deep it will go — an uncapped walk lets the document's nesting choose the stack depth, and the resulting StackOverflowException cannot be caught.
Method: Roslyn syntax + semantics: methods that take a JSON/XML document node and call themselves with a child of it, reachable from an externally-callable member of the same type that accepts a document, checked for any depth parameter, descent counter or threaded arithmetic anywhere in the walk. Deterministic, provable per finding. Advisory.
Other · Code Health — Whether a type's disposal matches what it OWNS — releasing what it created, leaving alone what it was handed, and not declaring a finalizer for state that has nothing unmanaged to finalize.
Method: Roslyn syntax + semantics: every assignment to a disposable field is read to decide whether the type CREATED the value or was handed it, and the type's disposal is checked against that answer — an injected interface it disposes, a value it constructed and never releases, a finalizer on a type holding nothing unmanaged, and a disposable local whose every reference is a plain member read. A value handed to a container that disposes its contents (a parent control's `Controls` collection, a component `IContainer`) is released by that container and is not reported; generated code is out of population. 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. Deterministic, provable per finding. Advisory.
Other · Code Health — Whether async methods accept a CancellationToken so work can be cancelled (adoption curve).
Method: Roslyn scan: every async method (excluding framework-fixed overrides/Blazor handlers) checked for CancellationToken parameter presence. Deterministic, adoption percentage.
Only 470/491 async methods accept a CancellationToken, so in-flight work can't be stopped early when the caller gives up — whatever ends it in your host (shutdown signal, timeout, abandoned request, user cancel). Thread a token through the call chain and honour it at each await and loop; where a method genuinely cannot be interrupted, omitting it is a deliberate choice — judge against your hosting model.
No CancellationToken parameter — the body observes an ambient token instead (a field or a context object), so the work does stop on cancellation, but a caller cannot cancel this call independently of the owner that created that token. (×8) — src/BuildingBlocks/Quota/QuotaEnforcementMiddleware.cs:82, src/BuildingBlocks/Web/Realtime/AppHub.cs:159, src/BuildingBlocks/Web/Realtime/AppHub.cs:194, …
No CancellationToken parameter — this work can't be stopped early once started. (×13) — src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:401, src/Modules/Auditing/Modules.Auditing/Infrastructure/Http/AuditHttpMiddleware.cs:84, src/Modules/Identity/Modules.Identity/Services/IdentityService.cs:68, …
What to do
Thread a CancellationToken through async methods so work stops promptly on cancellation.
Other · Code Health — Whether an argument guard throws the exception its own condition describes — a guard that rejects a value for being EMPTY and reports it as `ArgumentNullException` tells the caller a parameter was null when it provably was not.
Method: Roslyn syntax: `throw new ArgumentNullException(nameof(p))` statements controlled by an `if`, whose condition is read for a test that is true of a NON-null `p` — an emptiness test that dereferences it (`p.Count == 0`, `!p.Any()`) or a BCL predicate documented true of the empty value (`string.IsNullOrEmpty(p)`). Deterministic, provable per finding. Advisory.
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.
Other · Code Health — Whether a method that TAKES a lock or semaphore and gives it back from a flag-guarded `finally` returns the value that flag implies — reporting success while the guard hands the primitive back admits a second caller the exclusion was there to keep out, and reporting failure while the guard keeps it leaves nothing to ever give it back.
Method: Roslyn syntax: `try` statements whose `finally` releases a synchronisation primitive under a bare local-bool guard, where the method also TOOK that same primitive before the `try`, checked for a `return` of a bool literal whose value disagrees with the flag state the method's own straight-line assignments put it in. Deterministic, provable per finding. Advisory.
Other · Code Health — Whether the work a diagnostic log line costs is paid only when that line is wanted — C# evaluates a call's arguments BEFORE the call, so a trace/debug message joined or projected out of a collection is built in full on every pass, and then discarded by a sink the shipped configuration leaves switched off.
Method: Roslyn syntax: log calls at a diagnostic level (a `Log`-prefixed method naming Trace/Debug/Verbose, or a bare `Debug`/`Trace`/`Verbose` on a receiver named for a logger), whose argument list is read for a call whose cost scales with a sequence — a LINQ operator, a materialisation, `string.Join`, a serializer — with no enclosing level check or conditional-compilation region. 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. Deterministic, provable per finding. Advisory.
Other · Code Health — Whether a value the caller is invited to supply is the value the type actually uses — a constructor parameter stored in a private field that nothing ever reads while the default it was given is spelled out a second time at the site that should have read it, a keyed lookup that falls back to a different setting than the one its key names while the same type falls back to the matching one for that same key, or a culture-sensitive parse given no format provider by a type that feeds its own settable culture to the same kind of parse elsewhere. Either way, every caller who supplies a value silently gets something else.
Method: Roslyn syntax: private instance fields of a non-partial type assigned in a constructor from one of its own parameters with a `??` fallback, checked for whether anything in the type body reads the field and whether that same fallback expression is spelled out again outside the constructor; and `??` fallbacks onto a member access from a lookup call carrying exactly one string literal, grouped by that key across the type and checked for a fallback member whose folded name disagrees with the key while a sibling site for the same key agrees with it. Deterministic, provable per finding. Advisory.
Other · Code Health — Whether a value handed from a callback to the body that waits on it crosses on something built to be crossed — a `Queue<T>`/`List<T>`/`Dictionary<K,V>` written inside an event handler and read back outside it is mutated by two flows at once, and the semaphore or completion source beside it orders how MANY items exist while leaving the collection's own head, tail and backing array unprotected.
Method: Roslyn syntax: method, accessor, local-function and lambda bodies that declare BOTH a non-thread-safe generic collection (`Queue`/`Stack`/`List`/`Dictionary`/`HashSet`/`Sorted*`/`LinkedList`) and a synchronisation primitive (`SemaphoreSlim`/`TaskCompletionSource`/`ManualResetEvent(Slim)`/`AutoResetEvent`/`CountdownEvent`) as locals, then read for a `+=`-registered lambda that raises that primitive while the body outside every lambda waits on it — and, in that scope, a mutating call on the collection inside the lambda paired with a mention of it outside. Any `lock` in the scope abstains it. Deterministic, provable per finding. Advisory.
Do you agree with this assessment?
X27 · Collection changed while being enumerated10.0 / 10Exemplary○ Nothing flagged
Other · Code Health — Whether a `foreach` leaves the collection it is walking alone — a body that adds to or removes from the very collection the loop is enumerating invalidates the enumerator it is holding, so the next `MoveNext` throws `InvalidOperationException` and the remaining items are never seen.
Method: Roslyn syntax + semantics: `foreach` statements whose body calls a structural mutator (`Add`/`Remove`/`Clear`/`Insert`/…) on the very expression the loop is enumerating. Two arms. ARM A — the source is a concrete fragile BCL collection, or a live `Keys`/`Values` view over one, and the mutator resolves to that same collection's own member; concurrent and immutable collections and arrays are outside the population by construction, since their enumerators survive a structural change. ARM B — the source is an argument-less accessor CALL on a receiver whose body is in source: the accessor must return a stored field VERBATIM and a sibling member must structurally change that same field, both read off the implementations rather than from the members' names. A mutation the loop provably exits immediately after (`break`/`return`/`throw`/`goto`), or one written inside a nested loop or a lambda, is counted and never reported. Deterministic, provable per finding. Advisory.
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. 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` 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/Tools/CLI/Infrastructure/NuGetClient.cs:55
What to do
Swallowed exception (caught, then discarded)
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?
X32 · Type resolved by simple name across every loaded assembly10.0 / 10Exemplary○ Nothing flagged
Other · Code Health — Whether a plugin lookup names the type it means — searching every assembly loaded into the process for a candidate whose SIMPLE name equals a string supplied at runtime, and taking the first one found, is decided by assembly LOAD ORDER rather than by this source, so the same name can resolve to a different type on the next run.
Method: Roslyn syntax only, no semantic model: every invocation of `First`/`FirstOrDefault`/`Single`/`SingleOrDefault` whose OWN expression subtree contains both a `GetAssemblies()` call and a `GetTypes()`/`GetExportedTypes()` call — a single-element pick out of every type loaded into the process. A nested selector in the same chain sees no `GetAssemblies()` in its own subtree and is outside the population, so one lookup counts once however many links its chain has. A finding additionally needs both remaining halves: the selector must be `First`/`FirstOrDefault` (`Single`/`SingleOrDefault` reports the ambiguity rather than resolving it, and is counted and never reported), and the chain must carry an `==` comparison of `<lambda parameter>.Name` against something that is not a literal. The receiver must be a plain identifier bound by one of the chain’s own lambdas, which places `assembly.GetName().Name == "X"` outside the rule by construction. One exemption: a `.Name` test joined by `&&` to a `FullName`/`AssemblyQualifiedName` test on the same identifier is spared; joined by `||` it is not. Deterministic, provable per finding. Advisory.
Other · Code Health — Whether log calls use message templates (queryable) rather than interpolated strings.
Method: Roslyn syntax scan: every log call-site counted; interpolated-string first-argument violations flagged. Population is all log calls, not estimated. Deterministic.
Other · Code Health — Whether nullable reference types are enabled and not undermined by heavy `!` suppression.
Method: Roslyn compiler-options scan: NullableContextOptions per project; null-forgiving (!) suppression density per 1k syntax nodes. Deterministic, adoption plus suppression penalty.
~0.6 `!` suppressions per 1k syntax nodes — 225 suppression(s) across the 363962 syntax node(s) in code where nullable warnings are ENABLED, which is the only code a `!` can suppress anything in (a `!` under `#nullable disable` is inert and is not counted, and its file's nodes are not in the denominator). Each one tells the compiler to trust you about null, suppressing the very safety NRTs provide.
What to do
Enable <Nullable>enable</Nullable> across all projects and resolve warnings rather than suppressing with `!`.
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 — 2 check(s) recorded observations but carry no score
These checks ran and found something, but they do not carry a score — either by design (an advisory check reports evidence rather than grading it) or because they could not be scored here. They are excluded from the score for that reason, not because there was nothing to see.
P12 CI test-gate honesty — 1 observation(s) recorded · Reported, not scored — this card publishes what the CI gate does with the test inventory rather than grading it. The findings above are its output.
X7 Silent fallback defaults — 1 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 1 control(s) we could not find positive evidence for
These checks grade a working control, and the repository shows no evidence of one. That is deliberately not scored as a zero: a repository cannot show an ops runbook, a database TTL or an infrastructure-side audit log, so absence of evidence here is not evidence the control is missing. It is also not a statement that the check is irrelevant to this codebase — the thing it grades applies; we just could not see it. Excluded from the score either way.
C5 Data-Subject Rights — Repo shows no corroborated data-subject-rights mechanism (erasure / export-portability / consent) tied to a subject id or GDPR vocabulary — absence of evidence is not evidence of a working control. Implement erasure, data export/portability and consent tracking over the subject's records.
Not included — 24 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.
AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
D11 Test Reliability — Test reliability not scored — polyglot repository, one half has no runner
D12 Dependency Hygiene — Dependency hygiene not measured — no packages were read
D18 Solution Shape — D18 scores the shape of a C#/VB .NET solution, but this repository's production source is mostly .ts, .tsx, which the C#/VB workspace does not load — the projects that loaded are an immaterial minority, so solution shape was not assessed for this repository. Not scored — this is a gap in the analyzer's reach, not a verdict about this repository.
D20 ADR Quality — N/A — this repo declares itself a template / kata / sample / demo; a formal ADR log is deferred to a real application built from it.
D25 ADR Conformance — no ADRs to check
D27 Navigability — Most of this repository's production source (.ts, .tsx) was not read by navigability analysis, so tracing effort was not assessed — whatever else resolved (another language's projects) is not this repository's navigability. Not scored — this is a gap in the analyzer's reach, not a verdict about this repository.
D36 Supply-chain Provenance & Signing — This is a dotnet-new template — it produces no released artifact to attest. Supply-chain provenance, signing and SBOM are deferred to the application you build from it (add SLSA provenance / cosign signing / an SBOM in your app's release pipeline).
D39 IL Efficiency — IL not measured — the analyzer's build of the target did not succeed
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.
D6 Cohesion (LCOM4) — Cohesion (LCOM4) is measured over a CS/VB/GO/SCALA/SWIFT/DART class graph, and this repository's production source is mostly .ts, .tsx, which this pass does not read, so cohesion was not assessed for this repository. Not scored — this is a gap in the analyzer, not a finding about this repository.
D7 Architectural Integrity — no checkable ADRs and no dependency cycles — architectural integrity not assessed
D8 Code Coverage — Coverage not measured — .NET and JavaScript/TypeScript suite
DM7 Repository granularity — no repository abstraction detected (e.g. uses a document session)
ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
P9 Domain vs controller coverage — no coverage report found on disk — produce a coverage report in a standard format (Cobertura — `dotnet test --collect:"XPlat Code Coverage"` with a `coverlet.collector` PackageReference) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures, or wire coverage collection into CI, to enable this cross-layer check
R11 Import Boundaries — No recognizable feature-sliced/layered src layout — boundary rules not applicable.
R4 Test Coverage — 61 test file(s) reach none of 251 production file(s) via imports — exercised outside the JS import graph (integration/bundled), not import-reachable
SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
X10 Duplicated predicate — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
X6 Hand-rolled structured-format parsing — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
X9 Subsumed condition operand — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
Appendix A — Findings (grouped)
The findings behind the scores, grouped by severity, then by dimension and kind. The high-severity issues are enumerated in full below; items per group are capped at 25 with any overflow stated explicitly per group, never silently truncated. The complete machine-readable list of every finding (all severities) is the companion findings.md in this report's bundle.
NoWarnInCsproj — 6 warning codes suppressed in one element src/Tests/Webhooks.Tests/Webhooks.Tests.csproj:8— A single <NoWarn> suppresses 6 warning codes (CA1515;CA1861;CA1707;CA1308;S2376;S4581) in one stroke — one team-wide decision, not 6 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 13 warning codes suppressed in one element src/Tests/Framework.Tests/Framework.Tests.csproj:8— A single <NoWarn> suppresses 13 warning codes (CA1515;CA1861;CA1707;CA2007;CA1062;CA1812;CA2227;CA1002;CA1819;S1144;CA1031;S2094;S3459) in one stroke — one team-wide decision, not 13 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 7 warning codes suppressed in one element src/BuildingBlocks/Web/Web.csproj:6— A single <NoWarn> suppresses 7 warning codes (CA1805;CA1307;CA1308;S1854;CA1812;CA1305;CA2000) in one stroke — one team-wide decision, not 7 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 7 warning codes suppressed in one element src/BuildingBlocks/Storage/Storage.csproj:6— A single <NoWarn> suppresses 7 warning codes (CA1031;CA1056;CA1002;CA2227;CA1812;CA1308;CA1062) in one stroke — one team-wide decision, not 7 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 6 warning codes suppressed in one element src/BuildingBlocks/Shared/Shared.csproj:6— A single <NoWarn> suppresses 6 warning codes (CA1716;CA1711;CA1019;CA1305;CA1002;CA2227) in one stroke — one team-wide decision, not 6 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 7 warning codes suppressed in one element src/Modules/Webhooks/Modules.Webhooks/Modules.Webhooks.csproj:5— A single <NoWarn> suppresses 7 warning codes (CA1031;CA1054;CA1056;CA1308;CA1812;CA1859;S3267) in one stroke — one team-wide decision, not 7 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 7 warning codes suppressed in one element src/Modules/Notifications/Modules.Notifications/Modules.Notifications.csproj:6— A single <NoWarn> suppresses 7 warning codes (CA1031;CA1711;CA1812;CA1859;CA1002;CA2227;S3267) in one stroke — one team-wide decision, not 7 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 10 warning codes suppressed in one element src/Modules/Multitenancy/Modules.Multitenancy/Modules.Multitenancy.csproj:5— A single <NoWarn> suppresses 10 warning codes (CA1031;CA1056;CA1008;CA1716;CA1812;S1135;S2139;S6667;S3267;S1172) in one stroke — one team-wide decision, not 10 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 11 warning codes suppressed in one element src/Modules/Identity/Modules.Identity/Modules.Identity.csproj:6— A single <NoWarn> suppresses 11 warning codes (CA1031;CA1812;CA2208;S3267;S3928;CA1062;CA1304;CA1308;CA1311;CA1862;CA2227) in one stroke — one team-wide decision, not 11 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 6 warning codes suppressed in one element src/Modules/Files/Modules.Files/Modules.Files.csproj:6— A single <NoWarn> suppresses 6 warning codes (CA1031;CA1812;CA1859;CA1002;CA2227;S3267) in one stroke — one team-wide decision, not 6 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj — 6 warning codes suppressed in one element src/Modules/Chat/Modules.Chat/Modules.Chat.csproj:6— A single <NoWarn> suppresses 6 warning codes (CA1031;CA1812;CA1859;CA1002;CA2227;S3267) in one stroke — one team-wide decision, not 6 independent debts. Review the set centrally rather than code-by-code; each code you can re-enable is one less blanket suppression. (Every code still counts toward the score and metrics.)
NoWarnInCsproj src/Tests/Multitenancy.Tests/Multitenancy.Tests.csproj:8— S125 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Multitenancy.Tests/Multitenancy.Tests.csproj:8— S3261 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Integration.Tests/Integration.Tests.csproj:15— CA1056 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Integration.Middleware.Tests/Integration.Middleware.Tests.csproj:14— CA1056 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Modules/Webhooks/Modules.Webhooks.Contracts/Modules.Webhooks.Contracts.csproj:5— CA1056 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Modules/Multitenancy/Modules.Multitenancy.Contracts/Modules.Multitenancy.Contracts.csproj:5— CA1056 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Modules/Identity/Modules.Identity.Contracts/Modules.Identity.Contracts.csproj:6— CA1056 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Directory.Build.props:23— CA1056 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Identity.Tests/Identity.Tests.csproj:8— CA1515 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Generic.Tests/Generic.Tests.csproj:8— CA1515 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Files.Tests/Files.Tests.csproj:8— CA1515 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Chat.Tests/Chat.Tests.csproj:8— CA1515 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Catalog.Tests/Catalog.Tests.csproj:8— CA1515 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
NoWarnInCsproj src/Tests/Caching.Tests/Caching.Tests.csproj:8— CA1515 — this warning is switched off for the WHOLE project, in every file it builds, including code written years from now: nothing at the call site records that the rule was ever silenced, so the next reader has no reason to look here. Fix what the rule is reporting and drop the code from the list, or — if some occurrences really are legitimate — narrow the suppression to those sites and give each one its reason, so the rule keeps protecting the rest of the project.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/AdjustTenantValidityTests.cs:1— #pragma warning disable S1144 // Unused private members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/ChangeTenantActivationValidationTests.cs:1— #pragma warning disable S1144 // Unused private members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/RenewTenantTests.cs:1— #pragma warning disable S1144 // Unused private members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/RetryTenantProvisioningTests.cs:1— #pragma warning disable S1144 // Unused private members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/TenantMigrationsTests.cs:1— #pragma warning disable S1144 // Unused private members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/TenantThemeTests.cs:1— #pragma warning disable S1144 // Unused private members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/AdjustTenantValidityTests.cs:2— #pragma warning disable S3459 // Unassigned members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/ChangeTenantActivationValidationTests.cs:2— #pragma warning disable S3459 // Unassigned members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/RenewTenantTests.cs:2— #pragma warning disable S3459 // Unassigned members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/RetryTenantProvisioningTests.cs:2— #pragma warning disable S3459 // Unassigned members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/TenantMigrationsTests.cs:2— #pragma warning disable S3459 // Unassigned members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/TenantThemeTests.cs:2— #pragma warning disable S3459 // Unassigned members — populated by JSON deserialization — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Multitenancy/MyTenantStatusTests.cs:1— #pragma warning disable S1144, S3459 — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Webhooks/WebhookDeliveryTests.cs:12— #pragma warning disable CA1707 // Test method names use underscores by convention — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Webhooks/WebhookDispatchJobTests.cs:12— #pragma warning disable CA1707 // Test method names use underscores by convention — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Webhooks/WebhookDispatchOutcomeTests.cs:9— #pragma warning disable CA1707 // Test method names use underscores by convention — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Webhooks/WebhookFanoutTests.cs:11— #pragma warning disable CA1707 // Test method names use underscores by convention — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Webhooks/WebhookSignatureTests.cs:10— #pragma warning disable CA1707 // Test method names use underscores by convention — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
FileScopedPragmaDisable src/Tests/Integration.Tests/Tests/Webhooks/WebhookSubscriptionDomainTests.cs:3— #pragma warning disable CA1707 // Test method names use underscores by convention — the disable has no matching restore anywhere in this file, so it does not end with the construct that needed it: it runs to the end of the file and silences the rule for everything written below, including code added years later that nobody weighed against it. Close it with the matching restore directive immediately after the construct it covers — that alone turns a standing exemption into a scoped one — or fix the cause and drop the directive entirely.
AnalyzerSeverityNone src/.editorconfig:259— CA2007 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:260— CA1034 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:261— CA1724 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:262— CA1819 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:263— CA1040 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:264— CA1848 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:265— CA1054 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:266— CA1056 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:267— MSG0005 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:270— CA1062 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
AnalyzerSeverityNone src/.editorconfig:271— CA1861 — this rule is switched off for every file the section matches, in every project under this directory, and the only record that it was ever switched off is this line: nothing at the sites it would have reported says so, so a reader of that code has no reason to look here, and code added years from now inherits the decision silently. Fix what the rule reports and delete the entry, or — where some sites really are legitimate — leave the rule on and suppress it at those sites with their reasons, so it keeps protecting the rest of the tree. If the rule is genuinely unwanted here, say why — on this line after the entry, or in the comment run directly above it: a comment that only repeats the rule's own title is read as no explanation at all and leaves this row in place.
DM3 · Integration-event coupling· Integration event couples to a producer-owned enum · ×5
Integration event couples to a producer-owned enum: BillingPlanDto.OverageRates src/Modules/Billing/Modules.Billing.Contracts/Dtos/BillingPlanDto.cs:11— `BillingPlanDto.OverageRates` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead.
Integration event couples to a producer-owned enum: InvoiceLineItemDto.Resource src/Modules/Billing/Modules.Billing.Contracts/Dtos/InvoiceLineItemDto.cs:8— `InvoiceLineItemDto.Resource` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead.
Integration event couples to a producer-owned enum: UsageSnapshotDto.Resource src/Modules/Billing/Modules.Billing.Contracts/Dtos/UsageSnapshotDto.cs:10— `UsageSnapshotDto.Resource` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead.
Integration event couples to a producer-owned enum: CreatePlanCommand.OverageRates src/Modules/Billing/Modules.Billing.Contracts/v1/Plans/CreatePlanCommand.cs:11— `CreatePlanCommand.OverageRates` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead.
Integration event couples to a producer-owned enum: UpdatePlanCommand.OverageRates src/Modules/Billing/Modules.Billing.Contracts/v1/Plans/UpdatePlanCommand.cs:10— `UpdatePlanCommand.OverageRates` exposes `QuotaResource`, a enum owned by the producer's domain assembly (`FSH.Framework.Shared`) — carry the enum as a string/int instead.
AC2 · Forms & labels· <input> without a programmatic label · ×4
<input> without a programmatic label clients/admin/src/components/webhooks/create-webhook-dialog.tsx:199— This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label htmlFor>, a wrapping <label>, or aria-label.
<input> without a programmatic label clients/dashboard/src/components/file/file-dropzone.tsx:111— This control has no associated label. Add a <label htmlFor> / wrapping <label> / aria-label / aria-labelledby so assistive tech can name it.
<input> without a programmatic label clients/dashboard/src/components/list/combobox.tsx:145— This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label htmlFor>, a wrapping <label>, or aria-label.
<input> without a programmatic label clients/dashboard/src/pages/catalog/products.tsx:274— This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label htmlFor>, a wrapping <label>, or aria-label.
NoWarnInCsproj repeated across 10 files src/Tests/Multitenancy.Tests/Multitenancy.Tests.csproj:8— The identical NoWarnInCsproj (`CA1707`) appears in 10 files (10 occurrences) — a single repo-wide policy (e.g. a Directory.Build.props decision or an idiomatic suppression), not 10 independent debts. Decide it once centrally rather than file-by-file. (Every occurrence still counts toward the score and metrics.)
NoWarnInCsproj repeated across 10 files src/Tests/Identity.Tests/Identity.Tests.csproj:8— The identical NoWarnInCsproj (`CA1861`) appears in 10 files (10 occurrences) — a single repo-wide policy (e.g. a Directory.Build.props decision or an idiomatic suppression), not 10 independent debts. Decide it once centrally rather than file-by-file. (Every occurrence still counts toward the score and metrics.)
NoWarnInCsproj repeated across 10 files src/Modules/Webhooks/Modules.Webhooks.Contracts/Modules.Webhooks.Contracts.csproj:5— The identical NoWarnInCsproj (`S2094`) appears in 10 files (10 occurrences) — a single repo-wide policy (e.g. a Directory.Build.props decision or an idiomatic suppression), not 10 independent debts. Decide it once centrally rather than file-by-file. (Every occurrence still counts toward the score and metrics.)
Dual write (no outbox): SendMessageCommandHandler.Handle src/Modules/Chat/Modules.Chat/Features/v1/Messages/SendMessage/SendMessageCommandHandler.cs:28— `SendMessageCommandHandler.Handle` writes to the database AND publishes to the message bus in the same flow, with no outbox referenced in this path. These two writes aren't atomic — a crash between them either loses the message (DB committed, publish failed) or emits a phantom event (publish succeeded, DB rolled back). Use the transactional outbox pattern — write the message to an outbox table in the SAME transaction as the state change, and dispatch it from there afterwards — or your platform's equivalent (a broker transaction, or an outbox library from your own ecosystem).
Dual write (no outbox): CreateTenantCommandHandler.Handle src/Modules/Multitenancy/Modules.Multitenancy/Features/v1/CreateTenant/CreateTenantCommandHandler.cs:23— `CreateTenantCommandHandler.Handle` writes to the database AND publishes to the message bus in the same flow, with no outbox referenced in this path. These two writes aren't atomic — a crash between them either loses the message (DB committed, publish failed) or emits a phantom event (publish succeeded, DB rolled back). Use the transactional outbox pattern — write the message to an outbox table in the SAME transaction as the state change, and dispatch it from there afterwards — or your platform's equivalent (a broker transaction, or an outbox library from your own ecosystem).
Dual write (no outbox): RenewTenantCommandHandler.Handle src/Modules/Multitenancy/Modules.Multitenancy/Features/v1/RenewTenant/RenewTenantCommandHandler.cs:19— `RenewTenantCommandHandler.Handle` writes to the database AND publishes to the message bus in the same flow, with no outbox referenced in this path. These two writes aren't atomic — a crash between them either loses the message (DB committed, publish failed) or emits a phantom event (publish succeeded, DB rolled back). Use the transactional outbox pattern — write the message to an outbox table in the SAME transaction as the state change, and dispatch it from there afterwards — or your platform's equivalent (a broker transaction, or an outbox library from your own ecosystem).
FunctionTooLong: user-detail.UserDetailPage clients/dashboard/src/pages/identity/user-detail.tsx:84— FunctionTooLong — UserDetailPage runs 534 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 434 over it, 5.34× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: create-tenant-dialog.CreateTenantDialog clients/admin/src/components/tenants/create-tenant-dialog.tsx:200— FunctionTooLong — CreateTenantDialog runs 347 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 247 over it, 3.47× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: command-palette-dialog.CommandPaletteDialog clients/dashboard/src/components/command-palette/command-palette-dialog.tsx:75— FunctionTooLong — CommandPaletteDialog runs 342 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 242 over it, 3.42× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: group-detail.GroupDetailPage clients/dashboard/src/pages/identity/group-detail.tsx:74— FunctionTooLong — GroupDetailPage runs 327 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 227 over it, 3.27× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: topups-list.TopupsListPage clients/admin/src/pages/billing/topups-list.tsx:96— FunctionTooLong — TopupsListPage runs 318 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 218 over it, 3.18× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: overview.OverviewPage clients/dashboard/src/pages/overview.tsx:942— FunctionTooLong — OverviewPage runs 288 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 188 over it, 2.88× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: invoices-list.InvoicesListPage clients/admin/src/pages/billing/invoices-list.tsx:82— FunctionTooLong — InvoicesListPage runs 276 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 176 over it, 2.76× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: reset-password.ResetPasswordPage clients/admin/src/pages/auth/reset-password.tsx:44— FunctionTooLong — ResetPasswordPage runs 265 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 165 over it, 2.65× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: detail.TenantDetailPage clients/admin/src/pages/tenants/detail.tsx:50— FunctionTooLong — TenantDetailPage runs 253 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 153 over it, 2.53× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: login.LoginPage clients/admin/src/pages/login.tsx:36— FunctionTooLong — LoginPage runs 242 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 142 over it, 2.42× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: products.ProductEditorDialog clients/dashboard/src/pages/catalog/products.tsx:811— FunctionTooLong — ProductEditorDialog runs 240 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 140 over it, 2.40× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: invoice-detail.InvoiceDetailPage clients/admin/src/pages/billing/invoice-detail.tsx:73— FunctionTooLong — InvoiceDetailPage runs 239 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 139 over it, 2.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.
FunctionTooLong: topbar.Topbar clients/dashboard/src/components/layout/topbar.tsx:149— FunctionTooLong — Topbar runs 229 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 129 over it, 2.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.
FunctionTooLong: plan-form-dialog.PlanFormDialog clients/admin/src/components/billing/plan-form-dialog.tsx:118— FunctionTooLong — PlanFormDialog runs 226 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 126 over it, 2.26× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: create-user-dialog.CreateUserDialog clients/admin/src/components/users/create-user-dialog.tsx:78— FunctionTooLong — CreateUserDialog runs 222 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 122 over it, 2.22× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: forgot-password.ForgotPasswordPage clients/admin/src/pages/auth/forgot-password.tsx:30— FunctionTooLong — ForgotPasswordPage runs 222 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 122 over it, 2.22× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: reset-password.ResetPasswordPage clients/dashboard/src/pages/auth/reset-password.tsx:71— FunctionTooLong — ResetPasswordPage runs 218 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 118 over it, 2.18× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: list.UsersListPage clients/admin/src/pages/users/list.tsx:29— FunctionTooLong — UsersListPage runs 216 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 116 over it, 2.16× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: audits.AuditsPage clients/dashboard/src/pages/audits.tsx:187— FunctionTooLong — AuditsPage runs 199 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 99 over it, 1.99× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: products.ProductsPage clients/dashboard/src/pages/catalog/products.tsx:175— FunctionTooLong — ProductsPage runs 197 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 97 over it, 1.97× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: channel-settings.ChannelSettingsDialog clients/dashboard/src/pages/chat/channel-settings.tsx:40— FunctionTooLong — ChannelSettingsDialog runs 192 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 92 over it, 1.92× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: login.LoginPage clients/dashboard/src/pages/login.tsx:27— FunctionTooLong — LoginPage runs 190 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 90 over it, 1.90× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: sessions.SessionsPage clients/dashboard/src/pages/system/sessions.tsx:51— FunctionTooLong — SessionsPage runs 190 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 90 over it, 1.90× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: list.AuditsListPage clients/admin/src/pages/audits/list.tsx:40— FunctionTooLong — AuditsListPage runs 188 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 88 over it, 1.88× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
FunctionTooLong: detail.PermissionEditor clients/admin/src/pages/roles/detail.tsx:237— FunctionTooLong — PermissionEditor runs 180 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 80 over it, 1.80× 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.
Hotspot: clients/dashboard/src/pages/chat/message.tsx clients/dashboard/src/pages/chat/message.tsx:54— clients/dashboard/src/pages/chat/message.tsx changed 20 times in last 90 days, max cyclomatic complexity 39 in Message at line 54. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/chat/message.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/tenants/detail.tsx clients/admin/src/pages/tenants/detail.tsx:50— clients/admin/src/pages/tenants/detail.tsx changed 9 times in last 90 days, max cyclomatic complexity 40 in TenantDetailPage at line 50. 2 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/tenants/detail.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/chat/composer.tsx clients/dashboard/src/pages/chat/composer.tsx:35— clients/dashboard/src/pages/chat/composer.tsx changed 13 times in last 90 days, max cyclomatic complexity 21 in Composer at line 35. 4 of those changes were fix/bug commits, and the other 9 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/chat/composer.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/billing/invoice-detail.tsx clients/admin/src/pages/billing/invoice-detail.tsx:73— clients/admin/src/pages/billing/invoice-detail.tsx changed 5 times in last 90 days, max cyclomatic complexity 41 in InvoiceDetailPage at line 73. 1 of those changes was a fix/bug commit, and the other 4 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/billing/invoice-detail.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/overview.tsx clients/dashboard/src/pages/overview.tsx:942— clients/dashboard/src/pages/overview.tsx changed 5 times in last 90 days, max cyclomatic complexity 40 in OverviewPage at line 942. 2 of those changes were fix/bug commits, and the other 3 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/overview.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/chat/channel-rail.tsx clients/dashboard/src/pages/chat/channel-rail.tsx:262— clients/dashboard/src/pages/chat/channel-rail.tsx changed 10 times in last 90 days, max cyclomatic complexity 18 in ChannelRow at line 262. 2 of those changes were fix/bug commits, and the other 8 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/chat/channel-rail.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/identity/user-detail.tsx clients/dashboard/src/pages/identity/user-detail.tsx:84— clients/dashboard/src/pages/identity/user-detail.tsx changed 3 times in last 90 days, max cyclomatic complexity 55 in UserDetailPage at line 84. 2 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/identity/user-detail.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/audits/list.tsx clients/admin/src/pages/audits/list.tsx:40— clients/admin/src/pages/audits/list.tsx changed 5 times in last 90 days, max cyclomatic complexity 33 in AuditsListPage at line 40. 2 of those changes were fix/bug commits, and the other 3 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/audits/list.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/components/file/file-preview-dialog.tsx clients/dashboard/src/components/file/file-preview-dialog.tsx:67— clients/dashboard/src/components/file/file-preview-dialog.tsx changed 7 times in last 90 days, max cyclomatic complexity 22 in FilePreviewDialog at line 67. 3 of those changes were fix/bug commits, and the other 4 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/components/file/file-preview-dialog.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/users/list.tsx clients/admin/src/pages/users/list.tsx:29— clients/admin/src/pages/users/list.tsx changed 5 times in last 90 days, max cyclomatic complexity 29 in UsersListPage at line 29. 2 of those changes were fix/bug commits, and the other 3 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/users/list.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/login.tsx clients/admin/src/pages/login.tsx:36— clients/admin/src/pages/login.tsx changed 8 times in last 90 days, max cyclomatic complexity 18 in LoginPage at line 36. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/login.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/catalog/products.tsx clients/dashboard/src/pages/catalog/products.tsx:811— clients/dashboard/src/pages/catalog/products.tsx changed 6 times in last 90 days, max cyclomatic complexity 23 in ProductEditorDialog at line 811. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/catalog/products.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/tenants/list.tsx clients/admin/src/pages/tenants/list.tsx:25— clients/admin/src/pages/tenants/list.tsx changed 6 times in last 90 days, max cyclomatic complexity 23 in TenantsListPage at line 25. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/tenants/list.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/lib/api-client.ts clients/dashboard/src/lib/api-client.ts:155— clients/dashboard/src/lib/api-client.ts changed 6 times in last 90 days, max cyclomatic complexity 22 in apiFetch at line 155. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/lib/api-client.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/impersonation/list.tsx clients/admin/src/pages/impersonation/list.tsx:38— clients/admin/src/pages/impersonation/list.tsx changed 6 times in last 90 days, max cyclomatic complexity 21 in ImpersonationListPage at line 38. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/impersonation/list.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/components/layout/topbar.tsx clients/dashboard/src/components/layout/topbar.tsx:149— clients/dashboard/src/components/layout/topbar.tsx changed 6 times in last 90 days, max cyclomatic complexity 18 in Topbar at line 149. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/components/layout/topbar.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/audits.tsx clients/dashboard/src/pages/audits.tsx:187— clients/dashboard/src/pages/audits.tsx changed 4 times in last 90 days, max cyclomatic complexity 26 in AuditsPage at line 187. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/audits.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/billing/invoices-list.tsx clients/admin/src/pages/billing/invoices-list.tsx:82— clients/admin/src/pages/billing/invoices-list.tsx changed 5 times in last 90 days, max cyclomatic complexity 20 in InvoicesListPage at line 82. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/billing/invoices-list.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:295— src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs changed 6 times in last 90 days, max cyclomatic complexity 16 in DemoSeeder.SeedUsersInTenantAsync at line 295. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs`: 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: clients/dashboard/src/pages/invoices.tsx clients/dashboard/src/pages/invoices.tsx:71— clients/dashboard/src/pages/invoices.tsx changed 5 times in last 90 days, max cyclomatic complexity 19 in InvoicesPage at line 71. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/invoices.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/login.tsx clients/dashboard/src/pages/login.tsx:27— clients/dashboard/src/pages/login.tsx changed 5 times in last 90 days, max cyclomatic complexity 18 in LoginPage at line 27. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/login.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/files/my-files.tsx clients/dashboard/src/pages/files/my-files.tsx:123— clients/dashboard/src/pages/files/my-files.tsx changed 6 times in last 90 days, max cyclomatic complexity 15 in MyFilesPage at line 123. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/files/my-files.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/admin/src/pages/auth/reset-password.tsx clients/admin/src/pages/auth/reset-password.tsx:44— clients/admin/src/pages/auth/reset-password.tsx changed 3 times in last 90 days, max cyclomatic complexity 29 in ResetPasswordPage at line 44. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/auth/reset-password.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/auth/reset-password.tsx clients/dashboard/src/pages/auth/reset-password.tsx:71— clients/dashboard/src/pages/auth/reset-password.tsx changed 3 times in last 90 days, max cyclomatic complexity 29 in ResetPasswordPage at line 71. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/auth/reset-password.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: clients/dashboard/src/pages/tickets/tickets.tsx clients/dashboard/src/pages/tickets/tickets.tsx:81— clients/dashboard/src/pages/tickets/tickets.tsx changed 4 times in last 90 days, max cyclomatic complexity 20 in TicketsPage at line 81. 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-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/pages/tickets/tickets.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
DM12 · Ambient inputs in the domain· Domain type reads the wall clock · ×27
Domain type reads the wall clock: BillingPlan src/Modules/Billing/Modules.Billing/Domain/BillingPlan.cs:39— `BillingPlan` reads `DateTime.UtcNow` inside `Create`, `Update`, `Deactivate` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: Brand src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:23— `Brand` reads `DateTime.UtcNow` inside `Restore`, `Create`, `Update` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: Category src/Modules/Catalog/Modules.Catalog/Domain/Category.cs:18— `Category` reads `DateTime.UtcNow` inside `Restore`, `Create`, `Update` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: ChannelMember src/Modules/Chat/Modules.Chat/Domain/ChannelMember.cs:16— `ChannelMember` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: ChatChannel src/Modules/Chat/Modules.Chat/Domain/ChatChannel.cs:46— `ChatChannel` reads `DateTime.UtcNow` inside `Archive`, `Restore`, `CreateChannel`, `CreateDirect` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: DomainEvent src/BuildingBlocks/Core/Domain/DomainEvent.cs:23— `DomainEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: FileAsset src/Modules/Files/Modules.Files/Domain/FileAsset.cs:40— `FileAsset` reads `DateTime.UtcNow` inside `CreatePending`, `MarkAvailable`, `Restore`, `ChangeVisibility` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: Invoice src/Modules/Billing/Modules.Billing/Domain/Invoice.cs:55— `Invoice` reads `DateTime.UtcNow` inside `CreateDraft`, `Issue`, `MarkPaid`, `Void` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: Message src/Modules/Chat/Modules.Chat/Domain/Message.cs:35— `Message` reads `DateTime.UtcNow` inside `Create`, `Edit`, `SoftDelete`, `Pin` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: MessageReaction src/Modules/Chat/Modules.Chat/Domain/MessageReaction.cs:18— `MessageReaction` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: Notification src/Modules/Notifications/Modules.Notifications/Domain/Notification.cs:33— `Notification` reads `DateTime.UtcNow` inside `Create`, `MarkRead` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: PasswordChangedEvent src/Modules/Identity/Modules.Identity/Domain/Events/PasswordChangedEvent.cs:15— `PasswordChangedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: Product src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:32— `Product` reads `DateTime.UtcNow` inside `Restore`, `Create`, `Update`, `ChangePrice` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: ProductImage src/Modules/Catalog/Modules.Catalog/Domain/ProductImage.cs:33— `ProductImage` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: SessionRevokedEvent src/Modules/Identity/Modules.Identity/Domain/Events/SessionRevokedEvent.cs:17— `SessionRevokedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: Subscription src/Modules/Billing/Modules.Billing/Domain/Subscription.cs:26— `Subscription` reads `DateTime.UtcNow` inside `Create`, `Suspend`, `Reactivate`, `Cancel` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: TenantTheme src/Modules/Multitenancy/Modules.Multitenancy/Domain/TenantTheme.cs:57— `TenantTheme` reads `DateTimeOffset.UtcNow` inside `Create`, `Update` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: Ticket src/Modules/Tickets/Modules.Tickets/Domain/Ticket.cs:41— `Ticket` reads `DateTime.UtcNow` inside `Restore`, `Create`, `Assign`, `Resolve` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: TicketComment src/Modules/Tickets/Modules.Tickets/Domain/TicketComment.cs:27— `TicketComment` reads `DateTime.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: TopupRequest src/Modules/Billing/Modules.Billing/Domain/TopupRequest.cs:21— `TopupRequest` reads `DateTime.UtcNow` inside `Create`, `MarkInvoiced`, `MarkCompleted`, `Reject` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: UsageSnapshot src/Modules/Billing/Modules.Billing/Domain/UsageSnapshot.cs:23— `UsageSnapshot` reads `DateTime.UtcNow` inside `Capture` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: UserActivatedEvent src/Modules/Identity/Modules.Identity/Domain/Events/UserActivatedEvent.cs:15— `UserActivatedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: UserDeactivatedEvent src/Modules/Identity/Modules.Identity/Domain/Events/UserDeactivatedEvent.cs:16— `UserDeactivatedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: UserRegisteredEvent src/Modules/Identity/Modules.Identity/Domain/Events/UserRegisteredEvent.cs:17— `UserRegisteredEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
Domain type reads the wall clock: UserRoleAssignedEvent src/Modules/Identity/Modules.Identity/Domain/Events/UserRoleAssignedEvent.cs:15— `UserRoleAssignedEvent` reads `DateTimeOffset.UtcNow` inside `Create` — while this repo already declares a clock seam that the rest of the code injects. This site bypasses it, so the rule it feeds still cannot be exercised at a chosen instant, and two reads within one operation can disagree. Take the instant through the seam the repo already has.
FileTooLong: catalog/products.tsx clients/dashboard/src/pages/catalog/products.tsx— FileTooLong — 1197 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 697 over it, 2.39× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: pages/audits.tsx clients/dashboard/src/pages/audits.tsx— FileTooLong — 1162 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 662 over it, 2.32× 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: pages/overview.tsx clients/dashboard/src/pages/overview.tsx— FileTooLong — 994 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 494 over it, 1.99× 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: catalog/product-detail.tsx clients/dashboard/src/pages/catalog/product-detail.tsx— FileTooLong — 985 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 485 over it, 1.97× 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: identity/role-detail.tsx clients/dashboard/src/pages/identity/role-detail.tsx— FileTooLong — 886 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 386 over it, 1.77× 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: chat/message.tsx clients/dashboard/src/pages/chat/message.tsx— FileTooLong — 783 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 283 over it, 1.57× 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: identity/user-detail.tsx clients/dashboard/src/pages/identity/user-detail.tsx— FileTooLong — 749 significant lines (blank, comment-only and punctuation-only lines excluded), about 71% of them inside a single declaration: UserDetailPage (84-722). The bar is 500 significant lines; this is 249 over it, 1.50× 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: tickets/ticket-detail.tsx clients/dashboard/src/pages/tickets/ticket-detail.tsx— 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: settings/security.tsx clients/dashboard/src/pages/settings/security.tsx— FileTooLong — 671 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 171 over it, 1.34× 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: catalog/categories.tsx clients/dashboard/src/pages/catalog/categories.tsx— FileTooLong — 602 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 102 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: identity/group-detail.tsx clients/dashboard/src/pages/identity/group-detail.tsx— FileTooLong — 592 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 92 over it, 1.18× 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: files/my-files.tsx clients/dashboard/src/pages/files/my-files.tsx— FileTooLong — 587 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 87 over it, 1.17× 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: pages/health.tsx clients/dashboard/src/pages/health.tsx— FileTooLong — 572 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 72 over it, 1.14× 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: tenants/detail.tsx clients/admin/src/pages/tenants/detail.tsx— FileTooLong — 556 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 56 over it, 1.11× 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: DemoSeed/DemoSeeder.cs src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs— FileTooLong — 553 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 53 over it, 1.11× 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: system/trash.tsx clients/dashboard/src/pages/system/trash.tsx— FileTooLong — 548 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 48 over it, 1.10× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: catalog/brands.tsx clients/dashboard/src/pages/catalog/brands.tsx— FileTooLong — 523 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 23 over it, 1.05× 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: chat/channel-rail.tsx clients/dashboard/src/pages/chat/channel-rail.tsx— FileTooLong — 521 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 21 over it, 1.04× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: chat/composer.tsx clients/dashboard/src/pages/chat/composer.tsx— FileTooLong — 519 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 19 over it, 1.04× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: tenants/create-tenant-dialog.tsx clients/admin/src/components/tenants/create-tenant-dialog.tsx— FileTooLong — 504 significant lines (blank, comment-only and punctuation-only lines excluded), about 69% of them inside a single declaration: CreateTenantDialog (200-612). The bar is 500 significant lines; this is 4 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.
Repeated repair: src/BuildingBlocks/Web/Realtime/AppHub.cs src/BuildingBlocks/Web/Realtime/AppHub.cs:77— src/BuildingBlocks/Web/Realtime/AppHub.cs changed 7 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 8 (its worst body is AppHub.OnConnectedAsync at line 77), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(realtime): stop logging benign mid-connect disconnects as hub errors”; “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “fix(chat): deliver live messages to channels joined after connect”; “fix(chat-5): live read receipts + scope presence broadcasts to tenant group”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/BuildingBlocks/Web/Realtime/AppHub.cs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: REDACTED REDACTED:52— REDACTED changed 6 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 12 (its worst body is NewCommand.ExecuteAsync at line 52), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “fix(cli,template): drop the unimplemented --db sqlserver option”; “fix(cli): correct update-check version comparison + support --version”; “fix(scaffold): no-frontend AppHost build + correct advertised health URL”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --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.
Repeated repair: clients/dashboard/src/auth/auth-context.tsx clients/dashboard/src/auth/auth-context.tsx:268— clients/dashboard/src/auth/auth-context.tsx changed 5 times in last 90 days and 5 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 5 (its worst body is (anonymous) at line 268), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(dashboard): tenant-deactivated page + safe impersonation exit”; “fix: dashboard UX, auditing, identity, chat, and platform fixes”; “fix(dashboard): end impersonation instantly on cross-app handoff”; “fix(dashboard): end impersonation logs out on a cross-app handoff”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/auth/auth-context.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: clients/dashboard/src/components/layout/nav-data.ts clients/dashboard/src/components/layout/nav-data.ts:151— clients/dashboard/src/components/layout/nav-data.ts changed 7 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 8 (its worst body is findSectionForPath at line 151), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(clients): permission-gate every nav surface to mirror server authorization”; “fix(dashboard): permission-gate the Recycle bin tabs and nav entry”; “fix(deploy+dashboard): unblock CI (S125) and hide identity-admin nav from Basic users”; “fix(dashboard): permission-gate admin-only nav items”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/dashboard/src/components/layout/nav-data.ts`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: src/BuildingBlocks/Web/Observability/OpenTelemetry/Extensions.cs src/BuildingBlocks/Web/Observability/OpenTelemetry/Extensions.cs:66— src/BuildingBlocks/Web/Observability/OpenTelemetry/Extensions.cs changed 4 times in last 90 days and 4 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 12 (its worst body is Extensions.ConfigureMetricsAndTracing at line 66), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(eventing): back off outbox retries and make dead-letters recoverable (#1336)”; “fix(observability): export OTLP metrics every 10s so the dashboard isn't empty for 60s after restart”; “fix(observability): adopt orchestrator OTEL_SERVICE_NAME so Aspire lists the process once”; “fix(observability): export OTLP to Aspire dashboard (traces, metrics, logs)”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/BuildingBlocks/Web/Observability/OpenTelemetry/Extensions.cs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: src/Host/FSH.Starter.DbMigrator/MigratorCommand.cs src/Host/FSH.Starter.DbMigrator/MigratorCommand.cs:40— src/Host/FSH.Starter.DbMigrator/MigratorCommand.cs changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 4 (its worst body is MigratorCommand.ExtractValue at line 40), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “chore: .NET 10 housekeeping and doc correctness fixes”; “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “fix(migrator): clear CI -warnaserror analyzer errors”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/Host/FSH.Starter.DbMigrator/MigratorCommand.cs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: clients/admin/src/pages/settings/security.tsx clients/admin/src/pages/settings/security.tsx:287— clients/admin/src/pages/settings/security.tsx changed 5 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 8 (its worst body is TwoFactorEnroll at line 287), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(dashboard): tenant-deactivated page + safe impersonation exit”; “fix(admin): UX/a11y/perf/correctness pass (#1249)”; “fix(admin): UX/a11y/perf/correctness pass”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/pages/settings/security.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: src/Modules/Webhooks/Modules.Webhooks/WebhooksModule.cs src/Modules/Webhooks/Modules.Webhooks/WebhooksModule.cs:30— src/Modules/Webhooks/Modules.Webhooks/WebhooksModule.cs changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is WebhooksModule.ConfigureServices at line 30), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(webhooks): block SSRF targets on outbound delivery (#1332)”; “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “fix(chat,tickets,webhooks): close pre-release Tier-1 gaps (membership loss, ticket lifecycle, webhook secrets+authz)”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/Modules/Webhooks/Modules.Webhooks/WebhooksModule.cs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: src/Modules/Identity/Modules.Identity/Services/UserPasswordService.cs src/Modules/Identity/Modules.Identity/Services/UserPasswordService.cs:26— src/Modules/Identity/Modules.Identity/Services/UserPasswordService.cs changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 3 (its worst body is UserPasswordService.ForgotPasswordAsync at line 26), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(identity): correct password-reset email link”; “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “fix(identity): close forgot-password user-enumeration leak”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/Modules/Identity/Modules.Identity/Services/UserPasswordService.cs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: src/Modules/Identity/Modules.Identity/Data/IdentityDbInitializer.cs src/Modules/Identity/Modules.Identity/Data/IdentityDbInitializer.cs:103— src/Modules/Identity/Modules.Identity/Data/IdentityDbInitializer.cs changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 12 (its worst body is IdentityDbInitializer.SeedSystemGroupsAsync at line 103), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(identity): stop seeding a default admin avatar URL”; “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “fix(billing,identity,multitenancy): close cross-tenant security holes + string-enum API contract”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/Modules/Identity/Modules.Identity/Data/IdentityDbInitializer.cs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: src/Modules/Catalog/Modules.Catalog/Data/Configurations/ProductImageConfiguration.cs src/Modules/Catalog/Modules.Catalog/Data/Configurations/ProductImageConfiguration.cs:9— src/Modules/Catalog/Modules.Catalog/Data/Configurations/ProductImageConfiguration.cs changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is ProductImageConfiguration.Configure at line 9), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “fix(catalog): drop partial unique index on ProductImages.IsThumbnail”; “fix(catalog): AddProductImage 500 — ProductImage.Id ValueGeneratedNever”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/Modules/Catalog/Modules.Catalog/Data/Configurations/ProductImageConfiguration.cs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: clients/admin/src/App.tsx clients/admin/src/App.tsx:12— clients/admin/src/App.tsx changed 4 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 1 (its worst body is App at line 12), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(admin,multitenancy): users/roles crash, health probes, toast, demo provisioning”; “fix(admin): UX/a11y/perf/correctness pass (#1249)”; “fix(admin): UX/a11y/perf/correctness pass”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- clients/admin/src/App.tsx`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: src/BuildingBlocks/Mailing/Extensions.cs src/BuildingBlocks/Mailing/Extensions.cs:10— src/BuildingBlocks/Mailing/Extensions.cs changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 2 (its worst body is Extensions.AddHeroMailing at line 10), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(mailing): fail loudly when SendGrid rejects a message (#1331)”; “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “perf,refactor: fix hot-path allocations, N+1, reflection, and dead code”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/BuildingBlocks/Mailing/Extensions.cs`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Repeated repair: src/BuildingBlocks/Eventing/InMemory/InMemoryEventBus.cs src/BuildingBlocks/Eventing/InMemory/InMemoryEventBus.cs:55— src/BuildingBlocks/Eventing/InMemory/InMemoryEventBus.cs changed 3 times in last 90 days and 3 of those changes were fix/bug commits, so repair is the majority of this file's churn. Its max cyclomatic complexity is 3 (its worst body is InMemoryEventBus.PublishSingleAsync at line 55), UNDER the 15 threshold, so this is deliberately not filed as a churn × complexity hotspot — the difficulty here is in the behaviour the file has to get right, not in its control flow, and refactoring it for complexity would be the wrong move. The repairs counted were: “fix(deploy): pin AWS region, fix migrator env/seed, drop chiseled image; trim comments repo-wide”; “fix(eventing): establish tenant context for background event dispatch; run a single outbox dispatcher”; “perf,refactor: fix hot-path allocations, N+1, reflection, and dead code”. Each one is a case this code did not handle. Before the next change lands here, check that every one of them is pinned by a test that fails without its fix; where the same area keeps coming back, the durable fix is usually at the interface that keeps being misused rather than at the line that was last corrected. Counted over 2026-05-10..2026-08-08, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-05-10 08:54:38 +05:30' --until='2026-08-08 08:54:38 +05:30' --full-history --no-merges -- src/BuildingBlocks/Eventing/InMemory/InMemoryEventBus.cs`: 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.
DM10 · One transaction, one aggregate· One operation mutates 2 aggregates · ×7
One operation mutates 2 aggregates: DemoSeeder.SeedTenantSubscriptionAsync src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:190— `DemoSeeder.SeedTenantSubscriptionAsync` saves `Subscription`, `Invoice` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event.
One operation mutates 2 aggregates: DemoSeeder.SeedTenantChatAsync src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:537— `DemoSeeder.SeedTenantChatAsync` saves `ChatChannel`, `Message` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event.
One operation mutates 2 aggregates: DemoSeeder.SeedChannelAsync src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:659— `DemoSeeder.SeedChannelAsync` saves `ChatChannel`, `Message` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event.
One operation mutates 2 aggregates: IdentityDbInitializer.SeedSystemGroupsAsync src/Modules/Identity/Modules.Identity/Data/IdentityDbInitializer.cs:103— `IdentityDbInitializer.SeedSystemGroupsAsync` saves `Group`, `GroupRole` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event.
One operation mutates 2 aggregates: CreateGroupCommandHandler.Handle src/Modules/Identity/Modules.Identity/Features/v1/Groups/CreateGroup/CreateGroupCommandHandler.cs:23— `CreateGroupCommandHandler.Handle` saves `GroupRole`, `Group` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event.
One operation mutates 2 aggregates: WebhookDeliveryService.DeliverAsync src/Modules/Webhooks/Modules.Webhooks/Services/WebhookDeliveryService.cs:14— `WebhookDeliveryService.DeliverAsync` saves `HttpHeaders`, `DbSet` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event.
One operation mutates 2 aggregates: WebhookDispatchJob.DispatchAsync src/Modules/Webhooks/Modules.Webhooks/Services/WebhookDispatchJob.cs:46— `WebhookDispatchJob.DispatchAsync` saves `HttpHeaders`, `DbSet` in a single operation. Each is its own consistency boundary, so committing them together makes the second's invariants depend on the first's transaction, holds a lock across both for the whole operation, and means the pair can no longer be separated — into different services, or different databases. Mutate one aggregate here and let the others follow from a domain event.
Duplicated block (7 lines × 2) src/Host/FSH.Starter.Migrations.PostgreSQL/Billing/20260420140335_InitialBilling.cs:72— src/Host/FSH.Starter.Migrations.PostgreSQL/Billing/20260420140335_InitialBilling.cs:72-78 | src/Host/FSH.Starter.Migrations.PostgreSQL/Billing/20260625190639_WhatsAppWalletTopup.cs:51-57 — these copies are in TOOL-SCAFFOLDED MIGRATIONS, so no extraction is available here: the migration tool regenerates these files verbatim from the model, and a migration that has already been applied must not be edited at all — its recorded history row would stop describing it. Treat the repetition as generated output rather than duplication to remove; if the SHAPE itself is what repeats, factor it in the MODEL (a shared base entity or configuration) so future migrations are scaffolded from one definition.
Duplicated block (7 lines × 2) src/Host/FSH.Starter.Migrations.PostgreSQL/Catalog/20260430033202_InitialCatalog.cs:26— src/Host/FSH.Starter.Migrations.PostgreSQL/Catalog/20260430033202_InitialCatalog.cs:26-32 | src/Host/FSH.Starter.Migrations.PostgreSQL/Catalog/20260430034535_AddProducts.cs:30-36 — these copies are in TOOL-SCAFFOLDED MIGRATIONS, so no extraction is available here: the migration tool regenerates these files verbatim from the model, and a migration that has already been applied must not be edited at all — its recorded history row would stop describing it. Treat the repetition as generated output rather than duplication to remove; if the SHAPE itself is what repeats, factor it in the MODEL (a shared base entity or configuration) so future migrations are scaffolded from one definition.
Duplicated block (7 lines × 2) src/Host/FSH.Starter.Migrations.PostgreSQL/Chat/20260512193158_InitialChat.cs:33— src/Host/FSH.Starter.Migrations.PostgreSQL/Chat/20260512193158_InitialChat.cs:33-39 | src/Host/FSH.Starter.Migrations.PostgreSQL/Files/20260512080750_CreateFileAssets.cs:37-43 — these copies are in TOOL-SCAFFOLDED MIGRATIONS, so no extraction is available here: the migration tool regenerates these files verbatim from the model, and a migration that has already been applied must not be edited at all — its recorded history row would stop describing it. Treat the repetition as generated output rather than duplication to remove; if the SHAPE itself is what repeats, factor it in the MODEL (a shared base entity or configuration) so future migrations are scaffolded from one definition.
Duplicated block (7 lines × 2) src/Modules/Identity/Modules.Identity/Services/SessionService.cs:96— src/Modules/Identity/Modules.Identity/Services/SessionService.cs:96-102 | src/Modules/Identity/Modules.Identity/Services/SessionService.cs:113-119 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Identity/Modules.Identity/Services/SessionService.cs:96` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/Modules/Identity/Modules.Identity/Services/SessionService.cs:113` calls `Include` and `src/Modules/Identity/Modules.Identity/Services/SessionService.cs:96` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (7 lines × 2) src/Modules/Identity/Modules.Identity/Features/v1/Roles/GetRoles/GetRolesQueryValidator.cs:9— src/Modules/Identity/Modules.Identity/Features/v1/Roles/GetRoles/GetRolesQueryValidator.cs:9-15 | src/Modules/Identity/Modules.Identity/Features/v1/Sessions/GetTenantSessions/GetTenantSessionsValidator.cs:9-15 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
Off the main sequence: Caching — Caching: abstractness 0.00, instability 0.07, distance 0.93 — zone of pain — concrete and depended on by 14 project(s), so it's rigid to change.
Off the main sequence: Shared — Shared: abstractness 0.13, instability 0.03, distance 0.83 — the shape a shared-kernel / building-block library has BY DESIGN — concrete and widely depended-on is what makes it useful, and this dimension does not penalise it (the distance is reported for completeness, not as a defect). Worth a look only if it has grown past one coherent kernel into an everything-bucket.
Off the main sequence: Mailing — Mailing: abstractness 0.13, instability 0.07, distance 0.81 — zone of pain — concrete and depended on by 14 project(s), so it's rigid to change.
Off the main sequence: Jobs — Jobs: abstractness 0.08, instability 0.13, distance 0.79 — zone of pain — concrete and depended on by 14 project(s), so it's rigid to change.
Off the main sequence: Quota — Quota: abstractness 0.18, instability 0.12, distance 0.70 — zone of pain — concrete and depended on by 15 project(s), so it's rigid to change.
AC2 · Forms & labels· <Select> field component without a label · ×4
<Select> field component without a label clients/admin/src/pages/audits/list.tsx:173— This UI-library field component has no label / aria-label / aria-labelledby / id / name — and neither does anything it renders — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
<Select> field component without a label clients/admin/src/pages/audits/list.tsx:180— This UI-library field component has no label / aria-label / aria-labelledby / id / name — and neither does anything it renders — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
<Select> field component without a label clients/admin/src/pages/impersonation/list.tsx:103— This UI-library field component is named only by a placeholder — a placeholder is not a label (it vanishes as soon as the user types, and many assistive technologies ignore it). Give it a real name whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
<Select> field component without a label clients/admin/src/pages/notifications/inbox.tsx:97— This UI-library field component has no label / aria-label / aria-labelledby / id / name — and neither does anything it renders — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed.
MethodTooLong: Initial.Up src/Host/FSH.Starter.Migrations.PostgreSQL/Identity/20251222232937_Initial.cs:13— MethodTooLong — Up runs 236 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 136 over it, 2.36× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: InitialChat.Up src/Host/FSH.Starter.Migrations.PostgreSQL/Chat/20260512193158_InitialChat.cs:12— MethodTooLong — Up 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.
MethodTooLong: InitialBilling.Up src/Host/FSH.Starter.Migrations.PostgreSQL/Billing/20260420140335_InitialBilling.cs:12— MethodTooLong — Up runs 133 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 33 over it, 1.33× 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: UserGroups.Up src/Host/FSH.Starter.Migrations.PostgreSQL/Identity/20251223042602_UserGroups.cs:12— MethodTooLong — Up 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.
Duplicated block (11 lines × 2) src/Modules/Auditing/Modules.Auditing.Contracts/IAuditEvent.cs:15— src/Modules/Auditing/Modules.Auditing.Contracts/IAuditEvent.cs:15-31 | src/Modules/Auditing/Modules.Auditing.Contracts/IAuditScope.cs:9-19 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (11 lines × 2) src/Modules/Billing/Modules.Billing/Features/v1/Wallets/ApproveTopupRequest/ApproveTopupRequestCommandHandler.cs:19— src/Modules/Billing/Modules.Billing/Features/v1/Wallets/ApproveTopupRequest/ApproveTopupRequestCommandHandler.cs:19-29 | src/Modules/Billing/Modules.Billing/Features/v1/Wallets/RejectTopupRequest/RejectTopupRequestCommandHandler.cs:19-29 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Billing/Modules.Billing/Features/v1/Wallets/ApproveTopupRequest/ApproveTopupRequestCommandHandler.cs:19` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `command` to `ApproveTopupRequestCommand` in one and `RejectTopupRequestCommand` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (11 lines × 2) src/Modules/Chat/Modules.Chat/Features/v1/Reactions/AddReaction/AddReactionCommandHandler.cs:37— src/Modules/Chat/Modules.Chat/Features/v1/Reactions/AddReaction/AddReactionCommandHandler.cs:37-47 | src/Modules/Chat/Modules.Chat/Features/v1/Reactions/RemoveReaction/RemoveReactionCommandHandler.cs:35-45 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Reactions/AddReaction/AddReactionCommandHandler.cs:37` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (11 lines × 2) src/Modules/Identity/Modules.Identity/Features/v1/Users/RegisterUser/RegisterUserEndpoint.cs:16— src/Modules/Identity/Modules.Identity/Features/v1/Users/RegisterUser/RegisterUserEndpoint.cs:16-26 | src/Modules/Identity/Modules.Identity/Features/v1/Users/SelfRegistration/SelfRegisterUserEndpoint.cs:17-27 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Identity/Modules.Identity/Features/v1/Users/SelfRegistration/SelfRegisterUserEndpoint.cs:17` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/Modules/Identity/Modules.Identity/Features/v1/Users/SelfRegistration/SelfRegisterUserEndpoint.cs:17` calls `FromHeader` and `src/Modules/Identity/Modules.Identity/Features/v1/Users/RegisterUser/RegisterUserEndpoint.cs:16` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Dead code: Promote src/Modules/Chat/Modules.Chat/Domain/ChannelMember.cs:31— Method Promote — Roslyn's SymbolFinder walked every project the solution loads, including Modules.Chat, and found no reference to it. That walk cannot see three kinds of caller, so check them before removing it: code outside the solution file (a solution is a curated list, not the repository — a sibling test tree with its own .sln is invisible), a call resolved by reflection or dependency injection from the symbol's name, and any project the workspace could not load. This is 'no caller found by this walk', not a verdict that the symbol is unused.
Dead code: CategoryRow src/Tests/Integration.Tests/Tests/Catalog/ProductImagesTests.cs:300— NamedType CategoryRow — Roslyn's SymbolFinder walked every project the solution loads, including Integration.Tests, and found no reference to it. That walk cannot see three kinds of caller, so check them before removing it: code outside the solution file (a solution is a curated list, not the repository — a sibling test tree with its own .sln is invisible), a call resolved by reflection or dependency injection from the symbol's name, and any project the workspace could not load. This is 'no caller found by this walk', not a verdict that the symbol is unused.
Dead code: CategoryRow src/Tests/Integration.Tests/Tests/Catalog/ProductsEndpointTests.cs:650— NamedType CategoryRow — Roslyn's SymbolFinder walked every project the solution loads, including Integration.Tests, and found no reference to it. That walk cannot see three kinds of caller, so check them before removing it: code outside the solution file (a solution is a curated list, not the repository — a sibling test tree with its own .sln is invisible), a call resolved by reflection or dependency injection from the symbol's name, and any project the workspace could not load. This is 'no caller found by this walk', not a verdict that the symbol is unused.
D4 · Code Duplication· Members sharing a duplicated core (4 members, 50+ identical tokens) · ×3
Members sharing a duplicated core (4 members, 50+ identical tokens) src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:19— src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:19-62 | src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetMyInvoices/GetMyInvoicesQueryHandler.cs:19-56 | src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetMyTopupRequests/GetMyTopupRequestsQueryHandler.cs:20-50 | src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetTopupRequests/GetTopupRequestsQueryHandler.cs:20-55 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
Members sharing a duplicated core (4 members, 50+ identical tokens) src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:61— src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:61-73 | src/Modules/Catalog/Modules.Catalog/Domain/Category.cs:60-72 | src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:227-239 | src/Modules/Chat/Modules.Chat/Domain/ChatChannel.cs:220-232 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
Members sharing a duplicated core (4 members, 50+ identical tokens) src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:22— src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:22-45 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:22-53 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListMessageReplies/ListMessageRepliesQueryHandler.cs:22-61 | src/Modules/Chat/Modules.Chat/Features/v1/Search/SearchMessagesQueryHandler.cs:23-75 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
Duplicated block (12 lines × 2) src/Modules/Billing/Modules.Billing/Services/BillingService.cs:222— src/Modules/Billing/Modules.Billing/Services/BillingService.cs:222-233 | src/Modules/Billing/Modules.Billing/Services/BillingService.cs:360-371 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Billing/Modules.Billing/Services/BillingService.cs:222` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
Duplicated block (12 lines × 2) src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:35— src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:35-46 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListMessageReplies/ListMessageRepliesQueryHandler.cs:42-53 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:35` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `ListChannelMessagesQuery` in one and `ListMessageRepliesQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListMessageReplies/ListMessageRepliesQueryHandler.cs:53` calls `Include` and `src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:46` does not — after which the two agree again for 5 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (12 lines × 2) src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditSummary/GetAuditSummaryQueryHandler.cs:117— src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditSummary/GetAuditSummaryQueryHandler.cs:117-128 | src/Modules/Auditing/Modules.Auditing/Features/v1/GetAudits/GetAuditsQueryHandler.cs:176-187 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (10 lines × 2) src/Modules/Chat/Modules.Chat/Features/v1/Channels/DiscoverChannels/DiscoverChannelsQueryHandler.cs:20— src/Modules/Chat/Modules.Chat/Features/v1/Channels/DiscoverChannels/DiscoverChannelsQueryHandler.cs:20-29 | src/Modules/Notifications/Modules.Notifications/Features/v1/ListNotifications/ListNotificationsQueryHandler.cs:19-28 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Channels/DiscoverChannels/DiscoverChannelsQueryHandler.cs:20` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `q` to `DiscoverChannelsQuery` in one and `ListNotificationsQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (10 lines × 2) src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:22— src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:22-31 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:22-31 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:22` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetPinnedMessagesQuery` in one and `ListChannelMessagesQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (10 lines × 2) src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:35— src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:35-44 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListMessageReplies/ListMessageRepliesQueryHandler.cs:51-60 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:35` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) src/Modules/Catalog/Modules.Catalog/Features/v1/Products/CreateProduct/CreateProductCommandValidator.cs:10— src/Modules/Catalog/Modules.Catalog/Features/v1/Products/CreateProduct/CreateProductCommandValidator.cs:10-14 | src/Modules/Catalog/Modules.Catalog/Features/v1/Products/UpdateProduct/UpdateProductCommandValidator.cs:10-14 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `src/Modules/Catalog/Modules.Catalog/Features/v1/Products/CreateProduct/CreateProductCommandValidator.cs:15` calls `RuleFor`, `GreaterThanOrEqualTo`, `NotEmpty` and `src/Modules/Catalog/Modules.Catalog/Features/v1/Products/UpdateProduct/UpdateProductCommandValidator.cs:15` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (5 lines × 2) src/Modules/Identity/Modules.Identity.Contracts/Services/IUserRegistrationService.cs:27— src/Modules/Identity/Modules.Identity.Contracts/Services/IUserRegistrationService.cs:27-50 | src/Modules/Identity/Modules.Identity.Contracts/Services/IUserService.cs:19-23 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (5 lines × 2) src/Modules/Auditing/Modules.Auditing/Features/v1/GetExceptionAudits/GetExceptionAuditsQueryValidator.cs:9— src/Modules/Auditing/Modules.Auditing/Features/v1/GetExceptionAudits/GetExceptionAuditsQueryValidator.cs:9-13 | src/Modules/Auditing/Modules.Auditing/Features/v1/GetSecurityAudits/GetSecurityAuditsQueryValidator.cs:9-13 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
Dead file (~8 LoC) clients/admin/src/components/layout/sidebar-content.tsx— no import path from any entry point (32 application, 6 tooling, 61 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 (~8 LoC) clients/admin/src/pages/roles/create.tsx— no import path from any entry point (32 application, 6 tooling, 61 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 (~8 LoC) clients/admin/src/pages/users/create.tsx— no import path from any entry point (32 application, 6 tooling, 61 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
reset-password.ResetPasswordPage (cyclomatic 29) clients/admin/src/pages/auth/reset-password.tsx:44— reset-password.ResetPasswordPage has cyclomatic complexity 29 (threshold 15). Of this number, 26 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
reset-password.ResetPasswordPage (cyclomatic 29) clients/dashboard/src/pages/auth/reset-password.tsx:71— reset-password.ResetPasswordPage has cyclomatic complexity 29 (threshold 15). Of this number, 26 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
use-file-upload.useFileUpload (cyclomatic 27) clients/admin/src/hooks/use-file-upload.ts:77— use-file-upload.useFileUpload has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 3 of the 27 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 94, 169, 154, …). 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.
use-file-upload.useFileUpload (cyclomatic 27) clients/dashboard/src/hooks/use-file-upload.ts:77— use-file-upload.useFileUpload has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 3 of the 27 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 94, 169, 154, …). 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.
login.LoginPage (cyclomatic 21) clients/admin/src/pages/login.tsx:36— login.LoginPage has cyclomatic complexity 21 (threshold 15). Of this number, 17 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
login.LoginPage (cyclomatic 21) clients/dashboard/src/pages/login.tsx:27— login.LoginPage has cyclomatic complexity 21 (threshold 15). Of this number, 17 points are the body's own statements and 4 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
api-client.apiFetch (cyclomatic 17) clients/admin/src/lib/api-client.ts:108— api-client.apiFetch 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.
api-client.apiFetch (cyclomatic 17) clients/dashboard/src/lib/api-client.ts:155— api-client.apiFetch 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.
BarePragmaDisable src/Tests/Integration.Tests/Tests/Catalog/ProductsEndpointTests.cs:649— #pragma warning disable S1144 — the disable is closed again below, so its scope is not the problem; what it records is no reason: there is nothing on the directive line, and no ordinary comment attached to it either side. A suppression is a decision somebody made, and without the reason the next reader cannot tell a considered exception from an unexamined one, so it is never revisited and it outlives the code it was written for. Put the reason on the directive line — what makes this site legitimately different — or fix what the rule is pointing at and delete the pair. A rationale in the member's documentation comment does not clear this row and is not meant to: it explains the member to its callers, and the next person to touch the suppression is not reading it for that.
BarePragmaDisable src/Tests/Integration.Tests/Tests/Webhooks/WebhookSignatureTests.cs:208— #pragma warning disable CA1308 — the disable is closed again below, so its scope is not the problem; what it records is no reason: there is nothing on the directive line, and no ordinary comment attached to it either side. A suppression is a decision somebody made, and without the reason the next reader cannot tell a considered exception from an unexamined one, so it is never revisited and it outlives the code it was written for. Put the reason on the directive line — what makes this site legitimately different — or fix what the rule is pointing at and delete the pair. A rationale in the member's documentation comment does not clear this row and is not meant to: it explains the member to its callers, and the next person to touch the suppression is not reading it for that.
reset-password.ResetPasswordPage (cognitive 35) clients/admin/src/pages/auth/reset-password.tsx:44— reset-password.ResetPasswordPage has cognitive complexity 35 (threshold 15). Drivers by points: ternaries 14 (26 pts), boolean chains 6, if/else 3 (nesting depth added 12). Of this number, 32 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.
reset-password.ResetPasswordPage (cognitive 35) clients/dashboard/src/pages/auth/reset-password.tsx:71— reset-password.ResetPasswordPage has cognitive complexity 35 (threshold 15). Drivers by points: ternaries 14 (26 pts), boolean chains 6, if/else 3 (nesting depth added 12). Of this number, 32 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.
use-file-upload.useFileUpload (cognitive 32) clients/admin/src/hooks/use-file-upload.ts:77— use-file-upload.useFileUpload has cognitive complexity 32 (threshold 15). Drivers by points: ternaries 11 (17 pts), boolean chains 6, if/else 5 (6 pts), error handling 3 (nesting depth added 7). Most of this is not in the body itself: 1 of the 32 points is its own statement and the rest belongs to 9 function literals inside it that branch (lines 94, 169, 154, …). 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.
use-file-upload.useFileUpload (cognitive 32) clients/dashboard/src/hooks/use-file-upload.ts:77— use-file-upload.useFileUpload has cognitive complexity 32 (threshold 15). Drivers by points: ternaries 11 (17 pts), boolean chains 6, if/else 5 (6 pts), error handling 3 (nesting depth added 7). Most of this is not in the body itself: 1 of the 32 points is its own statement and the rest belongs to 9 function literals inside it that branch (lines 94, 169, 154, …). 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.
login.LoginPage (cognitive 21) clients/admin/src/pages/login.tsx:36— login.LoginPage has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 10 (13 pts), boolean chains 5, if/else 2, error handling 1 (nesting depth added 3). Of this number, 14 points are the body's own statements and 7 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
login.LoginPage (cognitive 21) clients/dashboard/src/pages/login.tsx:27— login.LoginPage has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 10 (13 pts), boolean chains 5, if/else 2, error handling 1 (nesting depth added 3). Of this number, 14 points are the body's own statements and 7 belong to 2 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
api-client.apiFetch (cognitive 19) clients/admin/src/lib/api-client.ts:108— api-client.apiFetch has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (10 pts), ternaries 2 (4 pts), boolean chains 3, error handling 1 (2 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
api-client.apiFetch (cognitive 19) clients/dashboard/src/lib/api-client.ts:155— api-client.apiFetch has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (10 pts), ternaries 2 (4 pts), boolean chains 3, error handling 1 (2 pts) (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
forgot-password.ForgotPasswordPage (cognitive 17) clients/admin/src/pages/auth/forgot-password.tsx:30— forgot-password.ForgotPasswordPage has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 8 (14 pts), boolean chains 2, if/else 1 (nesting depth added 6). Of this number, 16 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
forgot-password.ForgotPasswordPage (cognitive 17) clients/dashboard/src/pages/auth/forgot-password.tsx:32— forgot-password.ForgotPasswordPage has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 8 (14 pts), boolean chains 2, if/else 1 (nesting depth added 6). Of this number, 16 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
Cross-context type FileAccessContext (Files → Catalog) — FileAccessContext (context Files) is exposed in Catalog's public surface via ProductFileAccessPolicy.CanReadAsync — couples the contexts.
Cross-context type FileAccessContext (Files → Catalog) — FileAccessContext (context Files) is exposed in Catalog's public surface via ProductFileAccessPolicy.CanDeleteAsync — couples the contexts.
Cross-context type FileAccessContext (Files → Chat) — FileAccessContext (context Files) is exposed in Chat's public surface via ChatChannelFileAccessPolicy.CanReadAsync — couples the contexts.
Cross-context type FileAccessContext (Files → Chat) — FileAccessContext (context Files) is exposed in Chat's public surface via ChatChannelFileAccessPolicy.CanDeleteAsync — couples the contexts.
D4 · Code Duplication· Members sharing a duplicated core (6 members, 50+ identical tokens) · ×2
Members sharing a duplicated core (6 members, 50+ identical tokens) src/Modules/Chat/Modules.Chat/Features/v1/Channels/AddChannelMembers/AddChannelMembersCommandHandler.cs:21— src/Modules/Chat/Modules.Chat/Features/v1/Channels/AddChannelMembers/AddChannelMembersCommandHandler.cs:21-61 | src/Modules/Chat/Modules.Chat/Features/v1/Channels/MarkChannelRead/MarkChannelReadCommandHandler.cs:20-55 | src/Modules/Chat/Modules.Chat/Features/v1/Channels/RemoveChannelMember/RemoveChannelMemberCommandHandler.cs:21-52 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:22-45 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:22-53 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/SendMessage/SendMessageCommandHandler.cs:29-135 — These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
Members sharing a duplicated core (6 members, 50+ identical tokens) src/Modules/Chat/Modules.Chat/Features/v1/Messages/DeleteMessage/DeleteMessageCommandHandler.cs:23— src/Modules/Chat/Modules.Chat/Features/v1/Messages/DeleteMessage/DeleteMessageCommandHandler.cs:23-58 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/EditMessage/EditMessageCommandHandler.cs:20-43 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/PinMessage/PinMessageCommandHandler.cs:20-42 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/UnpinMessage/UnpinMessageCommandHandler.cs:20-42 | src/Modules/Chat/Modules.Chat/Features/v1/Reactions/AddReaction/AddReactionCommandHandler.cs:20-51 | src/Modules/Chat/Modules.Chat/Features/v1/Reactions/RemoveReaction/RemoveReactionCommandHandler.cs:20-49 — These 6 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 6 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 6 times.
Duplicated block (21 lines × 2) src/BuildingBlocks/Quota/QuotaEnforcementMiddleware.cs:90— src/BuildingBlocks/Quota/QuotaEnforcementMiddleware.cs:90-110 | src/BuildingBlocks/Web/RateLimiting/Extensions.cs:150-170 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/BuildingBlocks/Quota/QuotaEnforcementMiddleware.cs:90` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (21 lines × 2) src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetMyTopupRequests/GetMyTopupRequestsQueryHandler.cs:30— src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetMyTopupRequests/GetMyTopupRequestsQueryHandler.cs:30-50 | src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetTopupRequests/GetTopupRequestsQueryHandler.cs:35-55 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetMyTopupRequests/GetMyTopupRequestsQueryHandler.cs:30` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetMyTopupRequestsQuery` in one and `GetTopupRequestsQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (14–16 lines × 2) src/BuildingBlocks/Quota/InMemoryQuotaService.cs:72— src/BuildingBlocks/Quota/InMemoryQuotaService.cs:72-85 | src/BuildingBlocks/Quota/RedisQuotaService.cs:94-109 — before extracting anything, compare `src/BuildingBlocks/Quota/InMemoryQuotaService.cs` and `src/BuildingBlocks/Quota/RedisQuotaService.cs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 44 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `src/BuildingBlocks/Quota/InMemoryQuotaService.cs:72` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (14–16 lines × 2) src/BuildingBlocks/Quota/InMemoryQuotaService.cs:122— src/BuildingBlocks/Quota/InMemoryQuotaService.cs:122-135 | src/BuildingBlocks/Quota/RedisQuotaService.cs:158-173 — before extracting anything, compare `src/BuildingBlocks/Quota/InMemoryQuotaService.cs` and `src/BuildingBlocks/Quota/RedisQuotaService.cs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 44 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (13 lines × 2) src/Host/FSH.Starter.Migrations.PostgreSQL/Identity/20251222232937_Initial.cs:27— src/Host/FSH.Starter.Migrations.PostgreSQL/Identity/20251222232937_Initial.cs:27-39 | src/Host/FSH.Starter.Migrations.PostgreSQL/Identity/20260807063015_DropIdentityOutbox.cs:73-85 — these copies are in TOOL-SCAFFOLDED MIGRATIONS, so no extraction is available here: the migration tool regenerates these files verbatim from the model, and a migration that has already been applied must not be edited at all — its recorded history row would stop describing it. Treat the repetition as generated output rather than duplication to remove; if the SHAPE itself is what repeats, factor it in the MODEL (a shared base entity or configuration) so future migrations are scaffolded from one definition.
Duplicated block (13 lines × 2) src/Modules/Files/Modules.Files/Features/v1/GetFileDownloadUrl/GetFileDownloadUrlQueryHandler.cs:24— src/Modules/Files/Modules.Files/Features/v1/GetFileDownloadUrl/GetFileDownloadUrlQueryHandler.cs:24-36 | src/Modules/Files/Modules.Files/Features/v1/GetFileMetadata/GetFileMetadataQueryHandler.cs:24-36 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Files/Modules.Files/Features/v1/GetFileDownloadUrl/GetFileDownloadUrlQueryHandler.cs:24` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `q` to `GetFileDownloadUrlQuery` in one and `GetFileMetadataQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (9 lines × 2) src/Modules/Billing/Modules.Billing/Data/Configurations/TopupRequestConfiguration.cs:13— src/Modules/Billing/Modules.Billing/Data/Configurations/TopupRequestConfiguration.cs:13-21 | src/Modules/Billing/Modules.Billing/Data/Configurations/WalletTransactionConfiguration.cs:15-23 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. Note first that the copies are not typed on the same thing: the declarations holding them bind `builder` to `EntityTypeBuilder<TopupRequest>` in one and `EntityTypeBuilder<WalletTransaction>` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/Modules/Billing/Modules.Billing/Data/Configurations/WalletTransactionConfiguration.cs:15` calls `Property`, `ValueGeneratedNever` and `src/Modules/Billing/Modules.Billing/Data/Configurations/TopupRequestConfiguration.cs:13` does not — after which the two agree again for 5 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (9 lines × 2) src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:29— src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:29-37 | src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetTopupRequests/GetTopupRequestsQueryHandler.cs:30-38 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetInvoicesQuery` in one and `GetTopupRequestsQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (6 lines × 2) src/Modules/Billing/Modules.Billing/Features/v1/Usage/CaptureUsageSnapshots/CaptureUsageSnapshotsCommandHandler.cs:29— src/Modules/Billing/Modules.Billing/Features/v1/Usage/CaptureUsageSnapshots/CaptureUsageSnapshotsCommandHandler.cs:29-44 | src/Modules/Billing/Modules.Billing/Features/v1/Usage/GetUsageSnapshots/GetUsageSnapshotsQueryHandler.cs:45-50 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Billing/Modules.Billing/Features/v1/Usage/CaptureUsageSnapshots/CaptureUsageSnapshotsCommandHandler.cs:29` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (6 lines × 2) src/Modules/Catalog/Modules.Catalog/Authorization/ProductFileAccessPolicy.cs:27— src/Modules/Catalog/Modules.Catalog/Authorization/ProductFileAccessPolicy.cs:27-32 | src/Modules/Chat/Modules.Chat/Authorization/ChatChannelFileAccessPolicy.cs:45-50 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
R10 · Code Duplication· Duplicated block with local edits (118 matched lines × 2 locations) · ×2
Duplicated block with local edits (118 matched lines × 2 locations) clients/admin/src/lib/api-client.ts:4— clients/admin/src/lib/api-client.ts:4 · clients/dashboard/src/lib/api-client.ts:5 — the two spans are one implementation copied and then locally edited — 789 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 (118 matched lines × 2 locations) clients/admin/src/pages/billing/invoices-list.tsx:29— clients/admin/src/pages/billing/invoices-list.tsx:29 · clients/admin/src/pages/billing/topups-list.tsx:45 — the two spans are one implementation copied and then locally edited — 718 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.
Wholesale file copy (82 identical lines × 2 files) clients/admin/src/auth/use-inactivity-timeout.ts:1— clients/admin/src/auth/use-inactivity-timeout.ts:1 · clients/dashboard/src/auth/use-inactivity-timeout.ts:1 — these 2 files are line-for-line copies of one another — 82 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
Wholesale file copy (82 identical lines × 2 files) clients/admin/src/components/auth/inactivity-dialog.tsx:1— clients/admin/src/components/auth/inactivity-dialog.tsx:1 · clients/dashboard/src/components/auth/inactivity-dialog.tsx:1 — these 2 files are line-for-line copies of one another — 82 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
Complex function ResetPasswordPage (cyclomatic 29, cognitive 26) clients/admin/src/pages/auth/reset-password.tsx:44— ResetPasswordPage has cyclomatic complexity 29 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 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 ResetPasswordPage (cyclomatic 29, cognitive 26) clients/dashboard/src/pages/auth/reset-password.tsx:71— ResetPasswordPage has cyclomatic complexity 29 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 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.
Stateful singleton: RabbitMqEventBus src/BuildingBlocks/Eventing/RabbitMq/RabbitMqEventBus.cs:13— `RabbitMqEventBus` is a singleton (one shared instance) but mutates instance state outside any lock (_channel, _connection; e.g. `_channel` at line 207).
message-list.MessageList (cyclomatic 92) clients/dashboard/src/pages/chat/message-list.tsx:60— message-list.MessageList has cyclomatic complexity 92 (threshold 15). Most of this is not in the body itself: 13 of the 92 points are its own statements and the rest belongs to 38 function literals inside it that branch (lines 377, 101, 444, …). 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.
user-detail.UserDetailPage (cyclomatic 69) clients/dashboard/src/pages/identity/user-detail.tsx:84— user-detail.UserDetailPage has cyclomatic complexity 69 (threshold 15). Of this number, 43 points are the body's own statements and 26 belong to 17 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
role-detail.RoleDetailPage (cyclomatic 63) clients/dashboard/src/pages/identity/role-detail.tsx:66— role-detail.RoleDetailPage has cyclomatic complexity 63 (threshold 15). Of this number, 35 points are the body's own statements and 28 belong to 15 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
composer.Composer (cyclomatic 52) clients/dashboard/src/pages/chat/composer.tsx:35— composer.Composer has cyclomatic complexity 52 (threshold 15). Of this number, 21 points are the body's own statements and 31 belong to 13 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
invoice-detail.InvoiceDetailPage (cyclomatic 42) clients/admin/src/pages/billing/invoice-detail.tsx:73— invoice-detail.InvoiceDetailPage has cyclomatic complexity 42 (threshold 15). Of this number, 40 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
detail.TenantDetailPage (cyclomatic 40) clients/admin/src/pages/tenants/detail.tsx:50— detail.TenantDetailPage has cyclomatic complexity 40 (threshold 15). Of this number, 33 points are the body's own statements and 7 belong to 3 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
message.Message (cyclomatic 39) clients/dashboard/src/pages/chat/message.tsx:54— message.Message has cyclomatic complexity 39 (threshold 15). Of this number, 38 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, 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.
list.AuditsListPage (cyclomatic 38) clients/admin/src/pages/audits/list.tsx:40— list.AuditsListPage has cyclomatic complexity 38 (threshold 15). Of this number, 24 points are the body's own statements and 14 belong to 8 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.
overview.OverviewPage (cyclomatic 38) clients/dashboard/src/pages/overview.tsx:942— overview.OverviewPage has cyclomatic complexity 38 (threshold 15). Of this number, 36 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
topups-list.TopupsListPage (cyclomatic 35) clients/admin/src/pages/billing/topups-list.tsx:96— topups-list.TopupsListPage has cyclomatic complexity 35 (threshold 15). Of this number, 22 points are the body's own statements and 13 belong to 6 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
group-detail.GroupDetailPage (cyclomatic 33) clients/dashboard/src/pages/identity/group-detail.tsx:74— group-detail.GroupDetailPage has cyclomatic complexity 33 (threshold 15). Of this number, 21 points are the body's own statements and 12 belong to 8 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
plan-form-dialog.PlanFormDialog (cyclomatic 32) clients/admin/src/components/billing/plan-form-dialog.tsx:118— plan-form-dialog.PlanFormDialog has cyclomatic complexity 32 (threshold 15). Of this number, 18 points are the body's own statements and 14 belong to 4 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
invoices-list.InvoicesListPage (cyclomatic 32) clients/admin/src/pages/billing/invoices-list.tsx:82— invoices-list.InvoicesListPage has cyclomatic complexity 32 (threshold 15). Of this number, 19 points are the body's own statements and 13 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
products.ProductEditorDialog (cyclomatic 30) clients/dashboard/src/pages/catalog/products.tsx:811— products.ProductEditorDialog has cyclomatic complexity 30 (threshold 15). Of this number, 23 points are the body's own statements and 7 belong to 3 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
audits.AuditsPage (cyclomatic 28) clients/dashboard/src/pages/audits.tsx:187— audits.AuditsPage has cyclomatic complexity 28 (threshold 15). Of this number, 19 points are the body's own statements and 9 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.
list.UsersListPage (cyclomatic 26) clients/admin/src/pages/users/list.tsx:29— list.UsersListPage has cyclomatic complexity 26 (threshold 15). Of this number, 23 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
detail.WebhookDetailPage (cyclomatic 26) clients/admin/src/pages/webhooks/detail.tsx:42— detail.WebhookDetailPage has cyclomatic complexity 26 (threshold 15). Of this number, 23 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, 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.
security.SecuritySettings (cyclomatic 26) clients/dashboard/src/pages/settings/security.tsx:95— security.SecuritySettings has cyclomatic complexity 26 (threshold 15). Most of this is not in the body itself: 8 of the 26 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 109, 204, 130, …). 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.
create-tenant-dialog.CreateTenantDialog (cyclomatic 25) clients/admin/src/components/tenants/create-tenant-dialog.tsx:200— create-tenant-dialog.CreateTenantDialog has cyclomatic complexity 25 (threshold 15). Of this number, 14 points are the body's own statements and 11 belong to 7 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
detail.PermissionEditor (cyclomatic 25) clients/admin/src/pages/roles/detail.tsx:237— detail.PermissionEditor has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 7 of the 25 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 377, 338, 279, …). 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.
list.ImpersonationListPage (cyclomatic 24) clients/admin/src/pages/impersonation/list.tsx:38— list.ImpersonationListPage has cyclomatic complexity 24 (threshold 15). Of this number, 19 points are the body's own statements and 5 belong to 4 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.
file-preview-dialog.FilePreviewDialog (cyclomatic 24) clients/dashboard/src/components/file/file-preview-dialog.tsx:67— file-preview-dialog.FilePreviewDialog has cyclomatic complexity 24 (threshold 15). Of this number, 19 points are the body's own statements and 5 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
detail.StepRow (cyclomatic 23) clients/admin/src/pages/tenants/detail.tsx:542— detail.StepRow 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.
file-dropzone.FileDropzone (cyclomatic 23) clients/dashboard/src/components/file/file-dropzone.tsx:27— file-dropzone.FileDropzone has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 10 of the 23 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 38, 32, 64, …). 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.
user-picker.UserPicker (cyclomatic 23) clients/dashboard/src/components/identity/user-picker.tsx:25— user-picker.UserPicker has cyclomatic complexity 23 (threshold 15). Of this number, 15 points are the body's own statements and 8 belong to 6 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
realtime-context.RealtimeProvider (cyclomatic 23) clients/dashboard/src/realtime/realtime-context.tsx:50— realtime-context.RealtimeProvider has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to 11 function literals inside it that branch (lines 159, 212, 252, …). 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.
auth-context.AuthProvider (cyclomatic 22) clients/dashboard/src/auth/auth-context.tsx:111— auth-context.AuthProvider 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 13 function literals inside it that branch (lines 160, 171, 268, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
sessions.SessionsPage (cyclomatic 22) clients/dashboard/src/pages/system/sessions.tsx:51— sessions.SessionsPage has cyclomatic complexity 22 (threshold 15). Of this number, 12 points are the body's own statements and 10 belong to 8 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.
categories.CategoryEditorDialog (cyclomatic 21) clients/dashboard/src/pages/catalog/categories.tsx:456— categories.CategoryEditorDialog has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 10 of the 21 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 528, 482, 495, …). 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.
my-files.MyFilesPage (cyclomatic 21) clients/dashboard/src/pages/files/my-files.tsx:123— my-files.MyFilesPage has cyclomatic complexity 21 (threshold 15). Of this number, 15 points are the body's own statements and 6 belong to 3 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
role-detail.PermissionGroupCard (cyclomatic 21) clients/dashboard/src/pages/identity/role-detail.tsx:779— role-detail.PermissionGroupCard has cyclomatic complexity 21 (threshold 15). Of this number, 19 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, 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.
image-input.ImageInput (cyclomatic 20) clients/dashboard/src/components/file/image-input.tsx:38— image-input.ImageInput has cyclomatic complexity 20 (threshold 15). Of this number, 15 points are the body's own statements and 5 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
image-input.ImageInput (cyclomatic 19) clients/admin/src/components/file/image-input.tsx:38— image-input.ImageInput has cyclomatic complexity 19 (threshold 15). Of this number, 14 points are the body's own statements and 5 belong to 2 function literals inside it that branch. To reduce it, 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.
detail.ProvisioningPanel (cyclomatic 19) clients/admin/src/pages/tenants/detail.tsx:406— detail.ProvisioningPanel 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.
group-detail.AddMembersDialog (cyclomatic 19) clients/dashboard/src/pages/identity/group-detail.tsx:508— group-detail.AddMembersDialog has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 7 of the 19 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 624, 565, 524, …). 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.
tenant-branding-card.TenantBrandingCard (cyclomatic 18) clients/admin/src/components/tenants/tenant-branding-card.tsx:35— tenant-branding-card.TenantBrandingCard has cyclomatic complexity 18 (threshold 15). Of this number, 13 points are the body's own statements and 5 belong to 5 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
list.TenantsListPage (cyclomatic 18) clients/admin/src/pages/tenants/list.tsx:25— list.TenantsListPage has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, 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.
combobox.Combobox (cyclomatic 18) clients/dashboard/src/components/list/combobox.tsx:34— combobox.Combobox has cyclomatic complexity 18 (threshold 15). Of this number, 13 points are the body's own statements and 5 belong to 5 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
products.StockDialog (cyclomatic 18) clients/dashboard/src/pages/catalog/products.tsx:1215— products.StockDialog has cyclomatic complexity 18 (threshold 15). Of this number, 11 points are the body's own statements and 7 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
chat-page.ActiveChannel (cyclomatic 18) clients/dashboard/src/pages/chat/chat-page.tsx:143— chat-page.ActiveChannel has cyclomatic complexity 18 (threshold 15). Of this number, 13 points are the body's own statements and 5 belong to 4 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
message.MentionPill (cyclomatic 18) clients/dashboard/src/pages/chat/message.tsx:545— message.MentionPill has cyclomatic complexity 18 (threshold 15). Of this number, 17 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, 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.
branding.BrandingSettings (cyclomatic 18) clients/dashboard/src/pages/settings/branding.tsx:39— branding.BrandingSettings has cyclomatic complexity 18 (threshold 15). Of this number, 13 points are the body's own statements and 5 belong to 5 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
profile.ProfileSettings (cyclomatic 18) clients/dashboard/src/pages/settings/profile.tsx:16— profile.ProfileSettings has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 7 of the 18 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 36, 50, 60, …). 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.
GetAuditsQueryHandler.Handle (cyclomatic 17) src/Modules/Auditing/Modules.Auditing/Features/v1/GetAudits/GetAuditsQueryHandler.cs:49— GetAuditsQueryHandler.Handle has cyclomatic complexity 17 (threshold 15). Of this number, 11 points are the body's own statements and 6 belong to 2 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
auth-context.AuthProvider (cyclomatic 17) clients/admin/src/auth/auth-context.tsx:63— auth-context.AuthProvider 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 9 function literals inside it that branch (lines 107, 118, 150, …). 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.
notification-bell.NotificationBell (cyclomatic 17) clients/admin/src/components/notifications/notification-bell.tsx:23— notification-bell.NotificationBell has cyclomatic complexity 17 (threshold 15). Of this number, 12 points are the body's own statements and 5 belong to 5 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
profile.ProfileSettings (cyclomatic 17) clients/admin/src/pages/settings/profile.tsx:21— profile.ProfileSettings has cyclomatic complexity 17 (threshold 15). Of this number, 15 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, 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.
brands.BrandEditorDialog (cyclomatic 17) clients/dashboard/src/pages/catalog/brands.tsx:409— brands.BrandEditorDialog has cyclomatic complexity 17 (threshold 15). Of this number, 9 points are the body's own statements and 8 belong to 4 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
categories.CategoriesPage (cyclomatic 17) clients/dashboard/src/pages/catalog/categories.tsx:102— categories.CategoriesPage has cyclomatic complexity 17 (threshold 15). Of this number, 11 points are the body's own statements and 6 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
products.PriceDialog (cyclomatic 17) clients/dashboard/src/pages/catalog/products.tsx:1087— products.PriceDialog has cyclomatic complexity 17 (threshold 15). Of this number, 12 points are the body's own statements and 5 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
channel-rail.ChannelRow (cyclomatic 17) clients/dashboard/src/pages/chat/channel-rail.tsx:262— channel-rail.ChannelRow 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.
invoices.InvoicesPage (cyclomatic 17) clients/dashboard/src/pages/invoices.tsx:71— invoices.InvoicesPage has cyclomatic complexity 17 (threshold 15). Of this number, 14 points are the body's own statements and 3 belong to 2 function literals inside it that branch. To reduce it, 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.
Extensions.AddHeroPlatform (cyclomatic 16) src/BuildingBlocks/Web/Extensions.cs:37— Extensions.AddHeroPlatform 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.
DemoSeeder.SeedUsersInTenantAsync (cyclomatic 16) src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:295— DemoSeeder.SeedUsersInTenantAsync 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.
renew-tenant-dialog.RenewTenantDialog (cyclomatic 16) clients/admin/src/components/tenants/renew-tenant-dialog.tsx:38— renew-tenant-dialog.RenewTenantDialog has cyclomatic complexity 16 (threshold 15). Of this number, 9 points are the body's own statements and 7 belong to 5 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
create-webhook-dialog.CreateWebhookDialog (cyclomatic 16) clients/admin/src/components/webhooks/create-webhook-dialog.tsx:44— create-webhook-dialog.CreateWebhookDialog has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 6 of the 16 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 202, 106, 87, …). 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.
page.HealthPage (cyclomatic 16) clients/admin/src/pages/health/page.tsx:12— page.HealthPage has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
list.RolesListPage (cyclomatic 16) clients/admin/src/pages/roles/list.tsx:19— list.RolesListPage has cyclomatic complexity 16 (threshold 15). Of this number, 11 points are the body's own statements and 5 belong to 3 function literals inside it that branch. To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
realtime-context.RealtimeProvider (cyclomatic 16) clients/admin/src/realtime/realtime-context.tsx:40— realtime-context.RealtimeProvider has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 9 function literals inside it that branch (lines 95, 79, 108, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
theme-provider.ThemeProvider (cyclomatic 16) clients/dashboard/src/components/theme/theme-provider.tsx:225— theme-provider.ThemeProvider has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to 10 function literals inside it that branch (lines 279, 227, 245, …). 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.
product-detail.StockDialog (cyclomatic 16) clients/dashboard/src/pages/catalog/product-detail.tsx:1021— product-detail.StockDialog has cyclomatic complexity 16 (threshold 15). Of this number, 10 points are the body's own statements and 6 belong to 5 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
channel-settings.ChannelSettingsDialog (cyclomatic 16) clients/dashboard/src/pages/chat/channel-settings.tsx:40— channel-settings.ChannelSettingsDialog has cyclomatic complexity 16 (threshold 15). Of this number, 12 points are the body's own statements and 4 belong to 4 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.
users.UsersPage (cyclomatic 16) clients/dashboard/src/pages/identity/users.tsx:78— users.UsersPage has cyclomatic complexity 16 (threshold 15). Of this number, 13 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
message-list.MessageList (cognitive 103) clients/dashboard/src/pages/chat/message-list.tsx:60— message-list.MessageList has cognitive complexity 103 (threshold 15). Drivers by points: if/else 53 (65 pts), ternaries 14 (20 pts), boolean chains 13, loops 5 (nesting depth added 18). Most of this is not in the body itself: 8 of the 103 points are its own statements and the rest belongs to 38 function literals inside it that branch (lines 377, 358, 101, …). 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.
user-detail.UserDetailPage (cognitive 67) clients/dashboard/src/pages/identity/user-detail.tsx:84— user-detail.UserDetailPage has cognitive complexity 67 (threshold 15). Drivers by points: ternaries 27 (33 pts), if/else 15 (17 pts), boolean chains 16, loops 1 (nesting depth added 8). Of this number, 40 points are the body's own statements and 27 belong to 17 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.
role-detail.RoleDetailPage (cognitive 64) clients/dashboard/src/pages/identity/role-detail.tsx:66— role-detail.RoleDetailPage has cognitive complexity 64 (threshold 15). Drivers by points: boolean chains 27, if/else 18 (21 pts), ternaries 8 (11 pts), loops 3, error handling 1, match/switch 1 (nesting depth added 6). Of this number, 34 points are the body's own statements and 30 belong to 15 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.
overview.OverviewPage (cognitive 58) clients/dashboard/src/pages/overview.tsx:942— overview.OverviewPage has cognitive complexity 58 (threshold 15). Drivers by points: ternaries 22 (47 pts), boolean chains 10, if/else 1 (nesting depth added 25). Of this number, 56 points are the body's own statements and 2 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.
composer.Composer (cognitive 57) clients/dashboard/src/pages/chat/composer.tsx:35— composer.Composer has cognitive complexity 57 (threshold 15). Drivers by points: if/else 22 (28 pts), boolean chains 16, ternaries 10 (12 pts), error handling 1 (nesting depth added 8). Of this number, 20 points are the body's own statements and 37 belong to 13 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.
invoice-detail.InvoiceDetailPage (cognitive 43) clients/admin/src/pages/billing/invoice-detail.tsx:73— invoice-detail.InvoiceDetailPage has cognitive complexity 43 (threshold 15). Drivers by points: ternaries 12 (23 pts), boolean chains 20 (nesting depth added 11). Of this number, 41 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
topups-list.TopupsListPage (cognitive 39) clients/admin/src/pages/billing/topups-list.tsx:96— topups-list.TopupsListPage has cognitive complexity 39 (threshold 15). Drivers by points: ternaries 15 (19 pts), boolean chains 13, if/else 5 (6 pts), loops 1 (nesting depth added 5). Of this number, 25 points are the body's own statements and 14 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.
my-files.MyFilesPage (cognitive 38) clients/dashboard/src/pages/files/my-files.tsx:123— my-files.MyFilesPage has cognitive complexity 38 (threshold 15). Drivers by points: ternaries 12 (30 pts), boolean chains 5, if/else 2, loops 1 (nesting depth added 18). Of this number, 32 points are the body's own statements and 6 belong to 3 function literals inside it that branch. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
group-detail.GroupDetailPage (cognitive 38) clients/dashboard/src/pages/identity/group-detail.tsx:74— group-detail.GroupDetailPage has cognitive complexity 38 (threshold 15). Drivers by points: ternaries 12 (17 pts), boolean chains 10, if/else 9 (10 pts), loops 1 (nesting depth added 6). Of this number, 25 points are the body's own statements and 13 belong to 8 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.
DemoSeeder.SeedUsersInTenantAsync (cognitive 35) src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:295— DemoSeeder.SeedUsersInTenantAsync has cognitive complexity 35 (threshold 15). Of this number, 34 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.
categories.CategoriesPage (cognitive 35) clients/dashboard/src/pages/catalog/categories.tsx:102— categories.CategoriesPage has cognitive complexity 35 (threshold 15). Drivers by points: ternaries 10 (28 pts), boolean chains 3, if/else 2 (3 pts), loops 1 (nesting depth added 19). Of this number, 24 points are the body's own statements and 11 belong to 5 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.
detail.StepRow (cognitive 34) clients/admin/src/pages/tenants/detail.tsx:542— detail.StepRow has cognitive complexity 34 (threshold 15). Drivers by points: ternaries 15 (28 pts), boolean chains 6 (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.
invoices.InvoicesPage (cognitive 34) clients/dashboard/src/pages/invoices.tsx:71— invoices.InvoicesPage has cognitive complexity 34 (threshold 15). Drivers by points: ternaries 11 (30 pts), boolean chains 3, if/else 1 (nesting depth added 19). Of this number, 32 points are the body's own statements and 2 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.
list.AuditsListPage (cognitive 33) clients/admin/src/pages/audits/list.tsx:40— list.AuditsListPage has cognitive complexity 33 (threshold 15). Drivers by points: boolean chains 19, ternaries 8, if/else 6. Of this number, 17 points are the body's own statements and 16 belong to 8 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.
plan-form-dialog.PlanFormDialog (cognitive 30) clients/admin/src/components/billing/plan-form-dialog.tsx:118— plan-form-dialog.PlanFormDialog has cognitive complexity 30 (threshold 15). Drivers by points: ternaries 11 (12 pts), boolean chains 8, if/else 6 (8 pts), loops 2 (nesting depth added 3). Most of this is not in the body itself: 14 of the 30 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 139, 202, 165, …). 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.
invoices-list.InvoicesListPage (cognitive 29) clients/admin/src/pages/billing/invoices-list.tsx:82— invoices-list.InvoicesListPage has cognitive complexity 29 (threshold 15). Drivers by points: ternaries 12 (13 pts), boolean chains 12, if/else 2 (3 pts), loops 1 (nesting depth added 2). Of this number, 17 points are the body's own statements and 12 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.
audits.AuditsPage (cognitive 28) clients/dashboard/src/pages/audits.tsx:187— audits.AuditsPage has cognitive complexity 28 (threshold 15). Drivers by points: ternaries 6 (15 pts), boolean chains 12, if/else 1 (nesting depth added 9). Of this number, 19 points are the body's own statements and 9 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.
message.Message (cognitive 28) clients/dashboard/src/pages/chat/message.tsx:54— message.Message has cognitive complexity 28 (threshold 15). Drivers by points: boolean chains 22, ternaries 5, if/else 1. Of this number, 27 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, 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.
sessions.SessionsPage (cognitive 28) clients/dashboard/src/pages/system/sessions.tsx:51— sessions.SessionsPage has cognitive complexity 28 (threshold 15). Drivers by points: ternaries 8 (15 pts), boolean chains 13 (nesting depth added 7). Of this number, 18 points are the body's own statements and 10 belong to 8 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.
detail.PermissionEditor (cognitive 27) clients/admin/src/pages/roles/detail.tsx:237— detail.PermissionEditor has cognitive complexity 27 (threshold 15). Drivers by points: ternaries 8 (11 pts), boolean chains 10, if/else 4 (5 pts), loops 1 (nesting depth added 4). Most of this is not in the body itself: 7 of the 27 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 377, 338, 279, …). 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.
group-detail.AddMembersDialog (cognitive 27) clients/dashboard/src/pages/identity/group-detail.tsx:508— group-detail.AddMembersDialog has cognitive complexity 27 (threshold 15). Drivers by points: ternaries 8 (18 pts), boolean chains 6, if/else 3 (nesting depth added 10). Most of this is not in the body itself: 9 of the 27 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 624, 555, 524, …). 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.
security.SecuritySettings (cognitive 27) clients/dashboard/src/pages/settings/security.tsx:95— security.SecuritySettings has cognitive complexity 27 (threshold 15). Drivers by points: boolean chains 13, ternaries 6 (10 pts), if/else 4 (nesting depth added 4). Most of this is not in the body itself: 9 of the 27 points are its own statements and the rest belongs to 4 function literals inside it that branch (lines 109, 204, 130, …). 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.
create-tenant-dialog.CreateTenantDialog (cognitive 26) clients/admin/src/components/tenants/create-tenant-dialog.tsx:200— create-tenant-dialog.CreateTenantDialog has cognitive complexity 26 (threshold 15). Drivers by points: ternaries 13 (14 pts), boolean chains 7, if/else 5 (nesting depth added 1). Of this number, 13 points are the body's own statements and 13 belong to 7 function literals inside it that branch. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
file-preview-dialog.FilePreviewDialog (cognitive 26) clients/dashboard/src/components/file/file-preview-dialog.tsx:67— file-preview-dialog.FilePreviewDialog has cognitive complexity 26 (threshold 15). Drivers by points: ternaries 12 (19 pts), boolean chains 6, if/else 1 (nesting depth added 7). Of this number, 21 points are the body's own statements and 5 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.
audits.RelatedEventsSection (cognitive 26) clients/dashboard/src/pages/audits.tsx:1279— audits.RelatedEventsSection has cognitive complexity 26 (threshold 15). Drivers by points: ternaries 7 (21 pts), boolean chains 5 (nesting depth added 14). Most of this is not in the body itself: 4 of the 26 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 1339, 1365). 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.
users.UsersPage (cognitive 26) clients/dashboard/src/pages/identity/users.tsx:78— users.UsersPage has cognitive complexity 26 (threshold 15). Drivers by points: ternaries 9 (21 pts), boolean chains 5 (nesting depth added 12). Of this number, 23 points are the body's own statements and 3 belong to one function literal inside it that branches. To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
sse-context.parseSseStream (cognitive 26) clients/dashboard/src/sse/sse-context.tsx:60— sse-context.parseSseStream has cognitive complexity 26 (threshold 15). Drivers by points: if/else 5 (11 pts), ternaries 2 (8 pts), loops 3 (6 pts), boolean chains 1 (nesting depth added 15). Of this number, 25 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.
detail.ProvisioningPanel (cognitive 25) clients/admin/src/pages/tenants/detail.tsx:406— detail.ProvisioningPanel has cognitive complexity 25 (threshold 15). Drivers by points: ternaries 11 (21 pts), boolean chains 4 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
brands.BrandsPage (cognitive 25) clients/dashboard/src/pages/catalog/brands.tsx:76— brands.BrandsPage has cognitive complexity 25 (threshold 15). Drivers by points: ternaries 8 (22 pts), boolean chains 3 (nesting depth added 14). 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, 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.
groups.GroupsPage (cognitive 25) clients/dashboard/src/pages/identity/groups.tsx:52— groups.GroupsPage has cognitive complexity 25 (threshold 15). Drivers by points: ternaries 9 (23 pts), boolean chains 2 (nesting depth added 14). 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, 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.
realtime-context.RealtimeProvider (cognitive 25) clients/dashboard/src/realtime/realtime-context.tsx:50— realtime-context.RealtimeProvider has cognitive complexity 25 (threshold 15). Drivers by points: if/else 14 (16 pts), boolean chains 3, loops 2 (3 pts), error handling 2, ternaries 1 (nesting depth added 3). Most of this is not in the body itself: 0 of the 25 points are its own statements and the rest belongs to 11 function literals inside it that branch (lines 159, 212, 127, …). 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.
products.ProductEditorDialog (cognitive 24) clients/dashboard/src/pages/catalog/products.tsx:811— products.ProductEditorDialog has cognitive complexity 24 (threshold 15). Drivers by points: boolean chains 12, ternaries 7 (8 pts), if/else 4 (nesting depth added 1). Of this number, 16 points are the body's own statements and 8 belong to 3 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
tickets.TicketsPage (cognitive 24) clients/dashboard/src/pages/tickets/tickets.tsx:81— tickets.TicketsPage has cognitive complexity 24 (threshold 15). Drivers by points: ternaries 7 (19 pts), boolean chains 5 (nesting depth added 12). Of this number, 23 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, 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.
sse-context.SseProvider (cognitive 24) clients/dashboard/src/sse/sse-context.tsx:99— sse-context.SseProvider has cognitive complexity 24 (threshold 15). Drivers by points: if/else 5 (12 pts), ternaries 3 (5 pts), loops 2 (3 pts), boolean chains 2, error handling 1 (2 pts) (nesting depth added 11). Most of this is not in the body itself: 0 of the 24 points are its own statements and the rest belongs to 3 function literals inside it that branch (lines 127, 116, 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.
MultitenancyModule.ConfigureMiddleware (cognitive 23) src/Modules/Multitenancy/Modules.Multitenancy/MultitenancyModule.cs:130— MultitenancyModule.ConfigureMiddleware has cognitive complexity 23 (threshold 15). Most of this is not in the body itself: 0 of the 23 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 161, 137). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
detail.TenantDetailPage (cognitive 22) clients/admin/src/pages/tenants/detail.tsx:50— detail.TenantDetailPage has cognitive complexity 22 (threshold 15). Drivers by points: boolean chains 19, if/else 2, ternaries 1. Of this number, 15 points are the body's own statements and 7 belong to 3 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
auth-context.AuthProvider (cognitive 22) clients/dashboard/src/auth/auth-context.tsx:111— auth-context.AuthProvider has cognitive complexity 22 (threshold 15). Drivers by points: if/else 12 (13 pts), error handling 4, boolean chains 3, ternaries 2 (nesting depth added 1). Most of this is not in the body itself: 0 of the 22 points are its own statements and the rest belongs to 13 function literals inside it that branch (lines 171, 160, 268, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
categories.CategoryEditorDialog (cognitive 22) clients/dashboard/src/pages/catalog/categories.tsx:456— categories.CategoryEditorDialog has cognitive complexity 22 (threshold 15). Drivers by points: boolean chains 9, ternaries 7 (8 pts), if/else 5 (nesting depth added 1). Most of this is not in the body itself: 10 of the 22 points are its own statements and the rest belongs to 7 function literals inside it that branch (lines 528, 482, 495, …). 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.
AuditableEntitySaveChangesInterceptor.UpdateAuditEntities (cognitive 21) src/BuildingBlocks/Persistence/Inteceptors/AuditableEntitySaveChangesInterceptor.cs:74— AuditableEntitySaveChangesInterceptor.UpdateAuditEntities has cognitive complexity 21 (threshold 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
file-dropzone.FileDropzone (cognitive 21) clients/dashboard/src/components/file/file-dropzone.tsx:27— file-dropzone.FileDropzone has cognitive complexity 21 (threshold 15). Drivers by points: boolean chains 11, if/else 7, ternaries 2, error handling 1. Most of this is not in the body itself: 8 of the 21 points are its own statements and the rest belongs to 5 function literals inside it that branch (lines 38, 32, 64, …). 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.
theme-provider.ThemeProvider (cognitive 21) clients/dashboard/src/components/theme/theme-provider.tsx:225— theme-provider.ThemeProvider has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 8 (14 pts), error handling 6, if/else 1 (nesting depth added 6). Most of this is not in the body itself: 0 of the 21 points are its own statements and the rest belongs to 10 function literals inside it that branch (lines 279, 227, 245, …). 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.
channel-rail.ChannelRail (cognitive 21) clients/dashboard/src/pages/chat/channel-rail.tsx:41— channel-rail.ChannelRail has cognitive complexity 21 (threshold 15). Drivers by points: ternaries 9 (16 pts), boolean chains 5 (nesting depth added 7). Of this number, 17 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.
plans-list.PlansListPage (cognitive 20) clients/admin/src/pages/billing/plans-list.tsx:40— plans-list.PlansListPage has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 10 (17 pts), boolean chains 2, if/else 1 (nesting depth added 7). Most of this is not in the body itself: 9 of the 20 points are its own statements and the rest belongs to 2 function literals inside it that branch (lines 137, 62). 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.
role-detail.PermissionGroupCard (cognitive 20) clients/dashboard/src/pages/identity/role-detail.tsx:779— role-detail.PermissionGroupCard has cognitive complexity 20 (threshold 15). Drivers by points: boolean chains 13, ternaries 4 (6 pts), if/else 1 (nesting depth added 2). Of this number, 18 points are the body's own statements and 2 belong to one function literal inside it that branches. To reduce it, 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.
user-detail.SessionsCard (cognitive 20) clients/dashboard/src/pages/identity/user-detail.tsx:766— user-detail.SessionsCard has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 7 (16 pts), boolean chains 4 (nesting depth added 9). Most of this is not in the body itself: 9 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 824). 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.
IdempotencyEndpointFilter.InvokeAsync (cognitive 19) REDACTED:31— IdempotencyEndpointFilter.InvokeAsync has cognitive complexity 19 (threshold 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
security.TwoFactorEnroll (cognitive 19) clients/admin/src/pages/settings/security.tsx:287— security.TwoFactorEnroll has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 7 (11 pts), if/else 5, boolean chains 2, error handling 1 (nesting depth added 4). Of this number, 11 points are the body's own statements and 8 belong to 6 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.
chat-page.ActiveChannel (cognitive 19) clients/dashboard/src/pages/chat/chat-page.tsx:143— chat-page.ActiveChannel has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (8 pts), ternaries 6 (8 pts), boolean chains 3 (nesting depth added 3). Of this number, 13 points are the body's own statements and 6 belong to 4 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
roles.RolesPage (cognitive 19) clients/dashboard/src/pages/identity/roles.tsx:54— roles.RolesPage has cognitive complexity 19 (threshold 15). Drivers by points: ternaries 7 (16 pts), boolean chains 2, if/else 1 (nesting depth added 9). Of this number, 17 points are the body's own statements and 2 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
OutboxDispatcher.DispatchAsync (cognitive 18) src/BuildingBlocks/Eventing/Outbox/OutboxDispatcher.cs:43— OutboxDispatcher.DispatchAsync has cognitive complexity 18 (threshold 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
DemoSeeder.SeedTenantChatAsync (cognitive 18) src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:537— DemoSeeder.SeedTenantChatAsync has cognitive complexity 18 (threshold 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
list.UsersListPage (cognitive 18) clients/admin/src/pages/users/list.tsx:29— list.UsersListPage has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 14, ternaries 2 (3 pts), if/else 1 (nesting depth added 1). 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, 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.
brands.BrandEditorDialog (cognitive 18) clients/dashboard/src/pages/catalog/brands.tsx:409— brands.BrandEditorDialog has cognitive complexity 18 (threshold 15). Drivers by points: boolean chains 7, ternaries 6 (7 pts), if/else 4 (nesting depth added 1). Of this number, 9 points are the body's own statements and 9 belong to 4 function literals inside it that branch. To reduce it, split the body: 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.
channel-rail.NewDmDialog (cognitive 18) clients/dashboard/src/pages/chat/channel-rail.tsx:455— channel-rail.NewDmDialog has cognitive complexity 18 (threshold 15). Drivers by points: ternaries 6 (12 pts), boolean chains 5, if/else 1 (nesting depth added 6). Of this number, 14 points are the body's own statements and 4 belong to 4 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.
DemoSeeder.SeedTenantTicketsAsync (cognitive 17) src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:469— DemoSeeder.SeedTenantTicketsAsync has cognitive complexity 17 (threshold 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
SendMessageCommandHandler.Handle (cognitive 17) src/Modules/Chat/Modules.Chat/Features/v1/Messages/SendMessage/SendMessageCommandHandler.cs:28— SendMessageCommandHandler.Handle has cognitive complexity 17 (threshold 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ConfigureJwtBearerOptions.Configure (cognitive 17) src/Modules/Identity/Modules.Identity/Authorization/Jwt/ConfigureJwtBearerOptions.cs:41— ConfigureJwtBearerOptions.Configure has cognitive complexity 17 (threshold 15). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to 3 function literals inside it that branch (lines 90, 156, 191). 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.
renew-tenant-dialog.RenewTenantDialog (cognitive 17) clients/admin/src/components/tenants/renew-tenant-dialog.tsx:38— renew-tenant-dialog.RenewTenantDialog has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 8 (10 pts), boolean chains 5, if/else 2 (nesting depth added 2). Of this number, 10 points are the body's own statements and 7 belong to 5 function literals inside it that branch. To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
realtime-context.RealtimeProvider (cognitive 17) clients/admin/src/realtime/realtime-context.tsx:40— realtime-context.RealtimeProvider has cognitive complexity 17 (threshold 15). Drivers by points: if/else 9 (10 pts), loops 2 (3 pts), boolean chains 2, error handling 1, ternaries 1 (nesting depth added 2). Most of this is not in the body itself: 0 of the 17 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 95, 79, 108, …). The decisions are inside those literals, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literals' work into a named function or method at the enclosing scope and have each literal call it, then reduce whichever part then reads as the largest.
user-picker.UserPicker (cognitive 17) clients/dashboard/src/components/identity/user-picker.tsx:25— user-picker.UserPicker has cognitive complexity 17 (threshold 15). Drivers by points: boolean chains 10, if/else 6, ternaries 1. Of this number, 10 points are the body's own statements and 7 belong to 6 function literals inside it that branch. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
products.StockDialog (cognitive 17) clients/dashboard/src/pages/catalog/products.tsx:1215— products.StockDialog has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 6 (9 pts), boolean chains 6, if/else 2 (nesting depth added 3). Of this number, 11 points are the body's own statements and 6 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.
channel-rail.ChannelRow (cognitive 17) clients/dashboard/src/pages/chat/channel-rail.tsx:262— channel-rail.ChannelRow has cognitive complexity 17 (threshold 15). Drivers by points: ternaries 10 (13 pts), boolean chains 4 (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.
Extensions.AddHeroPlatform (cognitive 16) src/BuildingBlocks/Web/Extensions.cs:37— Extensions.AddHeroPlatform has cognitive complexity 16 (threshold 15). 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.
DemoSeeder.SeedTenantSubscriptionAsync (cognitive 16) src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:190— DemoSeeder.SeedTenantSubscriptionAsync has cognitive complexity 16 (threshold 15). Of this number, 13 points are the body's own statements and 3 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
IdentityDbInitializer.SeedSystemGroupsAsync (cognitive 16) src/Modules/Identity/Modules.Identity/Data/IdentityDbInitializer.cs:103— IdentityDbInitializer.SeedSystemGroupsAsync has cognitive complexity 16 (threshold 15). Of this number, 13 points are the body's own statements and 3 belong to 3 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
auth-context.AuthProvider (cognitive 16) clients/admin/src/auth/auth-context.tsx:63— auth-context.AuthProvider has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (9 pts), boolean chains 3, error handling 3, ternaries 1 (nesting depth added 1). Most of this is not in the body itself: 0 of the 16 points are its own statements and the rest belongs to 9 function literals inside it that branch (lines 118, 107, 87, …). 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.
tenant-branding-card.TenantBrandingCard (cognitive 16) clients/admin/src/components/tenants/tenant-branding-card.tsx:35— tenant-branding-card.TenantBrandingCard has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 6, ternaries 6, if/else 4. Of this number, 11 points are the body's own statements and 5 belong to 5 function literals inside it that branch. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
list.ImpersonationListPage (cognitive 16) clients/admin/src/pages/impersonation/list.tsx:38— list.ImpersonationListPage has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 9, ternaries 7. Of this number, 13 points are the body's own statements and 3 belong to 4 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.
image-input.ImageInput (cognitive 16) clients/dashboard/src/components/file/image-input.tsx:38— image-input.ImageInput has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 8 (11 pts), boolean chains 4, if/else 1 (nesting depth added 3). Of this number, 15 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.
product-detail.StockDialog (cognitive 16) clients/dashboard/src/pages/catalog/product-detail.tsx:1021— product-detail.StockDialog has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 5 (8 pts), boolean chains 6, if/else 2 (nesting depth added 3). Of this number, 10 points are the body's own statements and 6 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.
products.PriceDialog (cognitive 16) clients/dashboard/src/pages/catalog/products.tsx:1087— products.PriceDialog has cognitive complexity 16 (threshold 15). Drivers by points: ternaries 7 (8 pts), boolean chains 6, if/else 2 (nesting depth added 1). Of this number, 11 points are the body's own statements and 5 belong to 3 function literals inside it that branch. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
channel-settings.ChannelSettingsDialog (cognitive 16) clients/dashboard/src/pages/chat/channel-settings.tsx:40— channel-settings.ChannelSettingsDialog has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 6, if/else 3 (5 pts), ternaries 3 (5 pts) (nesting depth added 4). Of this number, 10 points are the body's own statements and 6 belong to 4 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.
branding.BrandingSettings (cognitive 16) clients/dashboard/src/pages/settings/branding.tsx:39— branding.BrandingSettings has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 6, ternaries 6, if/else 4. Of this number, 11 points are the body's own statements and 5 belong to 5 function literals inside it that branch. To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
profile.ProfileSettings (cognitive 16) clients/dashboard/src/pages/settings/profile.tsx:16— profile.ProfileSettings has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 8, if/else 4, ternaries 4. Most of this is not in the body itself: 5 of the 16 points are its own statements and the rest belongs to 6 function literals inside it that branch (lines 36, 50, 60, …). 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.
D22 · Internal API Consistency· Inconsistent naming convention for audit writing methods. The methods use specific domain verbs (WriteEntityChange, WriteSecurity, WriteActivity, WriteException) rather than a unified verb like 'WriteAudit' or 'Record' with a payload type, or a consistent 'Log' prefix. While distinct, the lack of a common root verb makes the API surface feel fragmented compared to standard logging abstractions. · ×1
Inconsistent naming convention for audit writing methods. The methods use specific domain verbs (WriteEntityChange, WriteSecurity, WriteActivity, WriteException) rather than a unified verb like 'WriteAudit' or 'Record' with a payload type, or a consistent 'Log' prefix. While distinct, the lack of a common root verb makes the API surface feel fragmented compared to standard logging abstractions. — Consider unifying under a single method signature such as 'WriteAuditAsync(AuditEnvelope envelope)' or 'LogAsync(AuditEventType type, object payload)', allowing the caller to construct the envelope or payload directly. This reduces the number of methods and aligns with the 'Envelope' pattern already present in the contracts. (signatures: IAuditClient.WriteEntityChangeAsync(...) | IAuditClient.WriteSecurityAsync(...) | IAuditClient.WriteActivityAsync(...) | IAuditClient.WriteExceptionAsync(...))
D22 · Internal API Consistency· Duplication of intent between ISecurityAudit and IAuditClient.WriteSecurityAsync. ISecurityAudit provides specific, high-level methods for security events (Login, Token, Impersonation), while IAuditClient.WriteSecurityAsync provides a generic method that takes a SecurityAction enum. This forces implementers to either implement both interfaces or choose one, creating confusion about which is the primary entry point for security auditing. · ×1
Duplication of intent between ISecurityAudit and IAuditClient.WriteSecurityAsync. ISecurityAudit provides specific, high-level methods for security events (Login, Token, Impersonation), while IAuditClient.WriteSecurityAsync provides a generic method that takes a SecurityAction enum. This forces implementers to either implement both interfaces or choose one, creating confusion about which is the primary entry point for security auditing. — Remove ISecurityAudit and have its implementations delegate to IAuditClient.WriteSecurityAsync. Alternatively, remove WriteSecurityAsync from IAuditClient and keep only ISecurityAudit if the specific methods are preferred. Having both creates a redundant API surface for the same domain concept. (signatures: ISecurityAudit.LoginSucceededAsync(...) | ISecurityAudit.LoginFailedAsync(...) | ISecurityAudit.TokenIssuedAsync(...) | ISecurityAudit.TokenRevokedAsync(...) | ISecurityAudit.ImpersonationStartedAsync(...) | ISecurityAudit.ImpersonationEndedAsync(...))
Cross-context type TenantRenewedIntegrationEvent (Multitenancy → Billing) — TenantRenewedIntegrationEvent (context Multitenancy) is exposed in Billing's public surface via TenantRenewedIntegrationEventHandler.HandleAsync — couples the contexts.
Cross-context type TenantSubscribedIntegrationEvent (Multitenancy → Billing) — TenantSubscribedIntegrationEvent (context Multitenancy) is exposed in Billing's public surface via TenantSubscribedIntegrationEventHandler.HandleAsync — couples the contexts.
Cross-context type InvoiceIssuedIntegrationEvent (Billing → Notifications) — InvoiceIssuedIntegrationEvent (context Billing) is exposed in Notifications's public surface via InvoiceIssuedEmailHandler.HandleAsync — couples the contexts.
Cross-context type MentionedInChannelIntegrationEvent (Chat → Notifications) — MentionedInChannelIntegrationEvent (context Chat) is exposed in Notifications's public surface via MentionedInChannelIntegrationEventHandler.HandleAsync — couples the contexts.
Cross-context type TenantEnteredGraceIntegrationEvent (Multitenancy → Notifications) — TenantEnteredGraceIntegrationEvent (context Multitenancy) is exposed in Notifications's public surface via TenantEnteredGraceEmailHandler.HandleAsync — couples the contexts.
Cross-context type TenantExpiredIntegrationEvent (Multitenancy → Notifications) — TenantExpiredIntegrationEvent (context Multitenancy) is exposed in Notifications's public surface via TenantExpiredEmailHandler.HandleAsync — couples the contexts.
Cross-context type TenantNearingExpiryIntegrationEvent (Multitenancy → Notifications) — TenantNearingExpiryIntegrationEvent (context Multitenancy) is exposed in Notifications's public surface via TenantNearingExpiryEmailHandler.HandleAsync — couples the contexts.
ClassTooLong: DemoSeeder src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs— ClassTooLong — 506 significant lines (blank, comment-only and punctuation-only lines excluded), 19 methods. The bar is 400 significant lines; this is 106 over it, 1.27× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
D4 · Code Duplication· Members sharing a duplicated core (5 members, 50+ identical tokens) · ×1
Members sharing a duplicated core (5 members, 50+ identical tokens) src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/ListTrashedBrands/ListTrashedBrandsQueryHandler.cs:16— src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/ListTrashedBrands/ListTrashedBrandsQueryHandler.cs:16-48 | src/Modules/Catalog/Modules.Catalog/Features/v1/Categories/ListTrashedCategories/ListTrashedCategoriesQueryHandler.cs:16-46 | src/Modules/Catalog/Modules.Catalog/Features/v1/Products/ListTrashedProducts/ListTrashedProductsQueryHandler.cs:16-43 | src/Modules/Files/Modules.Files/Features/v1/ListTrashedFiles/ListTrashedFilesQueryHandler.cs:15-45 | src/Modules/Tickets/Modules.Tickets/Features/v1/Tickets/ListTrashedTickets/ListTrashedTicketsQueryHandler.cs:17-44 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
Duplicated block (34 lines × 2) src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditsByCorrelation/GetAuditsByCorrelationQueryHandler.cs:25— src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditsByCorrelation/GetAuditsByCorrelationQueryHandler.cs:25-58 | src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditsByTrace/GetAuditsByTraceQueryHandler.cs:25-58 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditsByCorrelation/GetAuditsByCorrelationQueryHandler.cs:25` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetAuditsByCorrelationQuery` in one and `GetAuditsByTraceQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (29 lines × 2) src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:34— src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:34-62 | src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetMyInvoices/GetMyInvoicesQueryHandler.cs:28-56 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:34` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetInvoicesQuery` in one and `GetMyInvoicesQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (27 lines × 2) src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditSummary/GetAuditSummaryQueryHandler.cs:88— src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditSummary/GetAuditSummaryQueryHandler.cs:88-114 | src/Modules/Auditing/Modules.Auditing/Features/v1/GetAudits/GetAuditsQueryHandler.cs:141-167 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetAuditSummaryQuery` in one and `GetAuditsQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (20–26 lines × 2) src/Modules/Files/Modules.Files/Features/v1/ChangeVisibility/ChangeFileVisibilityCommandHandler.cs:24— src/Modules/Files/Modules.Files/Features/v1/ChangeVisibility/ChangeFileVisibilityCommandHandler.cs:24-49 | src/Modules/Files/Modules.Files/Features/v1/DeleteFile/DeleteFileCommandHandler.cs:19-38 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Files/Modules.Files/Features/v1/ChangeVisibility/ChangeFileVisibilityCommandHandler.cs:24` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. Note first that the copies are not typed on the same thing: the declarations holding them bind `cmd` to `ChangeFileVisibilityCommand` in one and `DeleteFileCommand` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (12–19 lines × 2) src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditDetailDto.cs:16— src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditDetailDto.cs:16-34 | src/Modules/Auditing/Modules.Auditing/Persistence/AuditRecord.cs:10-21 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
Duplicated block (18 lines × 2) src/Modules/Files/Modules.Files/Jobs/PurgeDeletedFilesJob.cs:29— src/Modules/Files/Modules.Files/Jobs/PurgeDeletedFilesJob.cs:29-48 | src/Modules/Files/Modules.Files/Jobs/PurgeOrphanedFilesJob.cs:29-46 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Files/Modules.Files/Jobs/PurgeDeletedFilesJob.cs:29` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (14–17 lines × 2) src/Modules/Files/Modules.Files/Jobs/PurgeDeletedFilesJob.cs:65— src/Modules/Files/Modules.Files/Jobs/PurgeDeletedFilesJob.cs:65-78 | src/Modules/Files/Modules.Files/Jobs/PurgeOrphanedFilesJob.cs:46-62 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Files/Modules.Files/Jobs/PurgeDeletedFilesJob.cs:65` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (15–17 lines × 2) src/Modules/Identity/Modules.Identity/Features/v1/Groups/GetGroups/GetGroupsQueryHandler.cs:39— src/Modules/Identity/Modules.Identity/Features/v1/Groups/GetGroups/GetGroupsQueryHandler.cs:39-53 | src/Modules/Identity/Modules.Identity/Features/v1/Users/GetUserGroups/GetUserGroupsQueryHandler.cs:47-63 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Identity/Modules.Identity/Features/v1/Users/GetUserGroups/GetUserGroupsQueryHandler.cs:47` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (16 lines × 2) src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoiceById/GetInvoiceByIdQueryHandler.cs:18— src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoiceById/GetInvoiceByIdQueryHandler.cs:18-33 | src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoicePdf/GetInvoicePdfQueryHandler.cs:18-33 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoiceById/GetInvoiceByIdQueryHandler.cs:18` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetInvoiceByIdQuery` in one and `GetInvoicePdfQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (14–15 lines × 6) src/Modules/Chat/Modules.Chat/Features/v1/Messages/DeleteMessage/DeleteMessageCommandHandler.cs:23— src/Modules/Chat/Modules.Chat/Features/v1/Messages/DeleteMessage/DeleteMessageCommandHandler.cs:23-36 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/EditMessage/EditMessageCommandHandler.cs:20-34 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/PinMessage/PinMessageCommandHandler.cs:20-33 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/UnpinMessage/UnpinMessageCommandHandler.cs:20-33 | src/Modules/Chat/Modules.Chat/Features/v1/Reactions/AddReaction/AddReactionCommandHandler.cs:20-34 | src/Modules/Chat/Modules.Chat/Features/v1/Reactions/RemoveReaction/RemoveReactionCommandHandler.cs:20-33 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 6 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 6 times. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Messages/DeleteMessage/DeleteMessageCommandHandler.cs:23` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `cmd` to `DeleteMessageCommand` in one and `EditMessageCommand` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (15 lines × 2) src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditDetailDto.cs:12— src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditDetailDto.cs:12-26 | src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditSummaryDto.cs:9-23 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (11–15 lines × 2) src/Modules/Chat/Modules.Chat/Features/v1/Channels/ArchiveChannel/ArchiveChannelCommandHandler.cs:17— src/Modules/Chat/Modules.Chat/Features/v1/Channels/ArchiveChannel/ArchiveChannelCommandHandler.cs:17-31 | src/Modules/Chat/Modules.Chat/Features/v1/Channels/UpdateChannel/UpdateChannelCommandHandler.cs:17-27 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Channels/ArchiveChannel/ArchiveChannelCommandHandler.cs:17` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. Note first that the copies are not typed on the same thing: the declarations holding them bind `cmd` to `ArchiveChannelCommand` in one and `UpdateChannelCommand` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (14 lines × 3) src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/SearchBrands/SearchBrandsQueryHandler.cs:27— src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/SearchBrands/SearchBrandsQueryHandler.cs:27-40 | src/Modules/Catalog/Modules.Catalog/Features/v1/Categories/SearchCategories/SearchCategoriesQueryHandler.cs:32-45 | src/Modules/Catalog/Modules.Catalog/Features/v1/Products/SearchProducts/SearchProductsQueryHandler.cs:43-56 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/SearchBrands/SearchBrandsQueryHandler.cs:27` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `SearchBrandsQuery` in one and `SearchCategoriesQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/Modules/Catalog/Modules.Catalog/Features/v1/Products/SearchProducts/SearchProductsQueryHandler.cs:42` calls `ILike` and `src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/SearchBrands/SearchBrandsQueryHandler.cs:26` does not — after which the two agree again for 4 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (11–14 lines × 2) src/BuildingBlocks/Quota/RedisQuotaService.cs:75— src/BuildingBlocks/Quota/RedisQuotaService.cs:75-88 | src/BuildingBlocks/Quota/RedisQuotaService.cs:108-118 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/BuildingBlocks/Quota/RedisQuotaService.cs:75` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
Duplicated block (13 lines × 4) src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:61— src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:61-73 | src/Modules/Catalog/Modules.Catalog/Domain/Category.cs:60-72 | src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:227-239 | src/Modules/Chat/Modules.Chat/Domain/ChatChannel.cs:220-232 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 4 times.
Duplicated block (12–13 lines × 3) src/Modules/Catalog/Modules.Catalog/Features/v1/Products/ListTrashedProducts/ListTrashedProductsQueryHandler.cs:24— src/Modules/Catalog/Modules.Catalog/Features/v1/Products/ListTrashedProducts/ListTrashedProductsQueryHandler.cs:24-35 | src/Modules/Files/Modules.Files/Features/v1/ListTrashedFiles/ListTrashedFilesQueryHandler.cs:25-37 | src/Modules/Tickets/Modules.Tickets/Features/v1/Tickets/ListTrashedTickets/ListTrashedTicketsQueryHandler.cs:25-36 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Catalog/Modules.Catalog/Features/v1/Products/ListTrashedProducts/ListTrashedProductsQueryHandler.cs:24` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (12 lines × 3) src/Host/FSH.Starter.Migrations.PostgreSQL/Eventing/20260807062955_EventingSchema.cs:24— src/Host/FSH.Starter.Migrations.PostgreSQL/Eventing/20260807062955_EventingSchema.cs:24-35 | src/Host/FSH.Starter.Migrations.PostgreSQL/Identity/20251222232937_Initial.cs:25-36 | src/Host/FSH.Starter.Migrations.PostgreSQL/Identity/20260807063015_DropIdentityOutbox.cs:71-82 — these copies are in TOOL-SCAFFOLDED MIGRATIONS, so no extraction is available here: the migration tool regenerates these files verbatim from the model, and a migration that has already been applied must not be edited at all — its recorded history row would stop describing it. Treat the repetition as generated output rather than duplication to remove; if the SHAPE itself is what repeats, factor it in the MODEL (a shared base entity or configuration) so future migrations are scaffolded from one definition.
Duplicated block (10–12 lines × 2) src/BuildingBlocks/Quota/InMemoryQuotaService.cs:151— src/BuildingBlocks/Quota/InMemoryQuotaService.cs:151-160 | src/BuildingBlocks/Quota/RedisQuotaService.cs:191-202 — before extracting anything, compare `src/BuildingBlocks/Quota/InMemoryQuotaService.cs` and `src/BuildingBlocks/Quota/RedisQuotaService.cs` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 44 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. If that is what happened, the fix is to keep one copy and have the other call it (or delete it), which resolves this row and its siblings together — extracting one helper per block leaves the fork in place. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (10–11 lines × 5) src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/ListTrashedBrands/ListTrashedBrandsQueryHandler.cs:25— src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/ListTrashedBrands/ListTrashedBrandsQueryHandler.cs:25-34 | src/Modules/Catalog/Modules.Catalog/Features/v1/Categories/ListTrashedCategories/ListTrashedCategoriesQueryHandler.cs:23-32 | src/Modules/Catalog/Modules.Catalog/Features/v1/Products/ListTrashedProducts/ListTrashedProductsQueryHandler.cs:23-32 | src/Modules/Files/Modules.Files/Features/v1/ListTrashedFiles/ListTrashedFilesQueryHandler.cs:24-34 | src/Modules/Tickets/Modules.Tickets/Features/v1/Tickets/ListTrashedTickets/ListTrashedTicketsQueryHandler.cs:24-33 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 5 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 5 times. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/ListTrashedBrands/ListTrashedBrandsQueryHandler.cs:25` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/ListTrashedBrands/ListTrashedBrandsQueryHandler.cs:34` calls `Select`, `BrandDto` and `src/Modules/Catalog/Modules.Catalog/Features/v1/Products/ListTrashedProducts/ListTrashedProductsQueryHandler.cs:32` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (11 lines × 4) src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:44— src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:44-54 | src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetMyInvoices/GetMyInvoicesQueryHandler.cs:38-48 | src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetMyTopupRequests/GetMyTopupRequestsQueryHandler.cs:32-42 | src/Modules/Billing/Modules.Billing/Features/v1/Wallets/GetTopupRequests/GetTopupRequestsQueryHandler.cs:37-47 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Billing/Modules.Billing/Features/v1/Invoices/GetInvoices/GetInvoicesQueryHandler.cs:44` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetInvoicesQuery` in one and `GetMyInvoicesQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (11 lines × 3) src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditsByCorrelation/GetAuditsByCorrelationQueryHandler.cs:25— src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditsByCorrelation/GetAuditsByCorrelationQueryHandler.cs:25-35 | src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditsByTrace/GetAuditsByTraceQueryHandler.cs:25-35 | src/Modules/Auditing/Modules.Auditing/Features/v1/GetSecurityAudits/GetSecurityAuditsQueryHandler.cs:29-39 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditsByCorrelation/GetAuditsByCorrelationQueryHandler.cs:25` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `query` to `GetAuditsByCorrelationQuery` in one and `GetAuditsByTraceQuery` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (9–11 lines × 2) src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditSummary/GetAuditSummaryQueryValidator.cs:10— src/Modules/Auditing/Modules.Auditing/Features/v1/GetAuditSummary/GetAuditSummaryQueryValidator.cs:10-18 | src/Modules/Auditing/Modules.Auditing/Features/v1/GetAudits/GetAuditsQueryValidator.cs:13-23 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
Duplicated block (9 lines × 6) src/Modules/Chat/Modules.Chat/Features/v1/Channels/AddChannelMembers/AddChannelMembersCommandHandler.cs:21— src/Modules/Chat/Modules.Chat/Features/v1/Channels/AddChannelMembers/AddChannelMembersCommandHandler.cs:21-29 | src/Modules/Chat/Modules.Chat/Features/v1/Channels/MarkChannelRead/MarkChannelReadCommandHandler.cs:20-28 | src/Modules/Chat/Modules.Chat/Features/v1/Channels/RemoveChannelMember/RemoveChannelMemberCommandHandler.cs:21-29 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:22-30 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:22-30 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/SendMessage/SendMessageCommandHandler.cs:29-37 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 6 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 6 times. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Channels/AddChannelMembers/AddChannelMembersCommandHandler.cs:21` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `cmd` to `AddChannelMembersCommand` in one and `MarkChannelReadCommand` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/Modules/Chat/Modules.Chat/Features/v1/Messages/SendMessage/SendMessageCommandHandler.cs:28` calls `Handle` and `src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:21` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (7–9 lines × 2) src/Modules/Catalog/Modules.Catalog/Data/Configurations/BrandConfiguration.cs:12— src/Modules/Catalog/Modules.Catalog/Data/Configurations/BrandConfiguration.cs:12-20 | src/Modules/Catalog/Modules.Catalog/Data/Configurations/CategoryConfiguration.cs:12-18 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Note first that the copies are not typed on the same thing: the declarations holding them bind `builder` to `EntityTypeBuilder<Brand>` in one and `EntityTypeBuilder<Category>` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (8 lines × 4) src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:38— src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:38-45 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListChannelMessages/ListChannelMessagesQueryHandler.cs:46-53 | src/Modules/Chat/Modules.Chat/Features/v1/Messages/ListMessageReplies/ListMessageRepliesQueryHandler.cs:54-61 | src/Modules/Chat/Modules.Chat/Features/v1/Search/SearchMessagesQueryHandler.cs:68-75 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 4 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 4 times. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:38` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/Modules/Chat/Modules.Chat/Features/v1/Messages/GetPinnedMessages/GetPinnedMessagesQueryHandler.cs:38` calls `AsNoTracking` and `src/Modules/Chat/Modules.Chat/Features/v1/Search/SearchMessagesQueryHandler.cs:68` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (8 lines × 3) src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:429— src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:429-436 | src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:470-477 | src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:538-545 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `src/Host/FSH.Starter.DbMigrator/DemoSeed/DemoSeeder.cs:429` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (8 lines × 2) src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/SearchBrands/SearchBrandsQueryHandler.cs:55— src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/SearchBrands/SearchBrandsQueryHandler.cs:55-62 | src/Modules/Catalog/Modules.Catalog/Features/v1/Categories/SearchCategories/SearchCategoriesQueryHandler.cs:58-65 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `src/Modules/Catalog/Modules.Catalog/Features/v1/Brands/SearchBrands/SearchBrandsQueryHandler.cs:55` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note first that the copies are not typed on the same thing: the declarations holding them bind `q` to `IQueryable<Brand>` in one and `IQueryable<Category>` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (7 lines × 3) src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:10— src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:10-18 | src/Modules/Catalog/Modules.Catalog/Domain/Category.cs:10-16 | src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:16-22 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:30` calls `FirstOrDefault` and `src/Modules/Catalog/Modules.Catalog/Domain/Brand.cs:23` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (6 lines × 4) src/Modules/Catalog/Modules.Catalog.Contracts/Authorization/CatalogPermissions.cs:9— src/Modules/Catalog/Modules.Catalog.Contracts/Authorization/CatalogPermissions.cs:9-14 | src/Modules/Catalog/Modules.Catalog.Contracts/Authorization/CatalogPermissions.cs:19-24 | src/Modules/Catalog/Modules.Catalog.Contracts/Authorization/CatalogPermissions.cs:29-34 | src/Modules/Tickets/Modules.Tickets.Contracts/Authorization/TicketsPermissions.cs:9-14 — there are 4 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart.
Duplicated block (5 lines × 3) src/Modules/Catalog/Modules.Catalog/Data/Configurations/BrandConfiguration.cs:14— src/Modules/Catalog/Modules.Catalog/Data/Configurations/BrandConfiguration.cs:14-20 | src/Modules/Catalog/Modules.Catalog/Data/Configurations/CategoryConfiguration.cs:14-18 | src/Modules/Catalog/Modules.Catalog/Data/Configurations/ProductConfiguration.cs:20-28 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately. Note first that the copies are not typed on the same thing: the declarations holding them bind `builder` to `EntityTypeBuilder<Brand>` in one and `EntityTypeBuilder<Category>` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `src/Modules/Catalog/Modules.Catalog/Data/Configurations/ProductConfiguration.cs:17` calls `Property`, `IsRequired`, `HasMaxLength` and `src/Modules/Catalog/Modules.Catalog/Data/Configurations/BrandConfiguration.cs:13` does not — after which the two agree again for 3 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplication concentrated across 2 sibling directories (119 clone groups) clients/admin/src/components/tenants/tenant-branding-card.tsx:2— 119 duplicated blocks under clients/ have copies in at least two of the sibling directories admin, dashboard — 96 of them are reported below, and 23 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 119 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 119 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 119 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
Duplication concentrated across 7 sibling directories (24 clone groups) clients/dashboard/src/pages/system/sessions.tsx:58— 24 duplicated blocks under clients/dashboard/src/pages/ have copies in at least two of the sibling directories catalog, chat, files, identity, settings, system (+1 more sibling(s) not listed) — 15 of them are reported below, and 9 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 24 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 24 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 24 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
Duplication concentrated across 10 sibling directories (18 clone groups) clients/admin/src/pages/tenants/list.tsx:41— 18 duplicated blocks under clients/admin/src/pages/ have copies in at least two of the sibling directories audits, billing, health, impersonation, notifications, roles (+4 more sibling(s) not listed) — 11 of them are reported below, and 7 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 18 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 18 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 18 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
Duplication concentrated across 2 sibling directories (13 clone groups) clients/admin/src/components/sessions/user-sessions-card.tsx:182— 13 duplicated blocks under clients/admin/src/ have copies in at least two of the sibling directories components, pages — 6 of them are reported below, and 7 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 13 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 13 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 13 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
Duplication concentrated across 3 sibling directories (13 clone groups) clients/dashboard/src/components/list/entity-shell.tsx:136— 13 duplicated blocks under clients/dashboard/src/ have copies in at least two of the sibling directories components, lib, pages — 8 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 13 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 13 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 13 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on.
Duplication concentrated across 8 sibling directories (9 clone groups) clients/admin/src/components/list/select.tsx:10— 9 duplicated blocks under clients/admin/src/components/ have copies in at least two of the sibling directories billing, impersonation, list, roles, tenants, ui (+2 more sibling(s) not listed) — 6 of them are reported below, and 3 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 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 (331 matched lines × 2 locations) · ×1
Duplicated block with local edits (331 matched lines × 2 locations) clients/dashboard/src/pages/catalog/brands.tsx:66— clients/dashboard/src/pages/catalog/brands.tsx:66 · clients/dashboard/src/pages/catalog/categories.tsx:92 — the two spans are one implementation copied and then locally edited — 1849 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 (270 matched lines × 2 locations) · ×1
Duplicated block with local edits (270 matched lines × 2 locations) clients/dashboard/src/pages/catalog/product-detail.tsx:781— clients/dashboard/src/pages/catalog/product-detail.tsx:781 · clients/dashboard/src/pages/catalog/products.tsx:975 — the two spans are one implementation copied and then locally edited — 1544 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.
Wholesale file copy (263 identical lines × 2 files) clients/admin/src/components/tenants/tenant-branding-card.tsx:2— clients/admin/src/components/tenants/tenant-branding-card.tsx:2 · clients/dashboard/src/pages/settings/branding.tsx:2 — these 2 files are line-for-line copies of one another — 263 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication· Duplicated block with local edits (236 matched lines × 2 locations) · ×1
Duplicated block with local edits (236 matched lines × 2 locations) clients/admin/src/components/layout/topbar.tsx:44— clients/admin/src/components/layout/topbar.tsx:44 · clients/dashboard/src/components/layout/topbar.tsx:51 — the two spans are one implementation copied and then locally edited — 1065 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 (184 matched lines × 2 locations) · ×1
Duplicated block with local edits (184 matched lines × 2 locations) clients/dashboard/src/pages/catalog/categories.tsx:217— clients/dashboard/src/pages/catalog/categories.tsx:217 · clients/dashboard/src/pages/catalog/products.tsx:329 — the two spans are one implementation copied and then locally edited — 869 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.
Wholesale file copy (168 identical lines × 2 files) clients/admin/src/components/layout/sidebar.tsx:2— clients/admin/src/components/layout/sidebar.tsx:2 · clients/dashboard/src/components/layout/sidebar.tsx:2 — these 2 files are line-for-line copies of one another — 168 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
Wholesale file copy (162 identical lines × 2 files) clients/admin/src/hooks/use-file-upload.ts:1— clients/admin/src/hooks/use-file-upload.ts:1 · clients/dashboard/src/hooks/use-file-upload.ts:1 — these 2 files are line-for-line copies of one another — 162 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication· Duplicated block with local edits (162 matched lines × 2 locations) · ×1
Duplicated block with local edits (162 matched lines × 2 locations) clients/dashboard/src/pages/identity/roles.tsx:87— clients/dashboard/src/pages/identity/roles.tsx:87 · clients/dashboard/src/pages/identity/users.tsx:144 — the two spans are one implementation copied and then locally edited — 686 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 (161 matched lines × 2 locations) · ×1
Duplicated block with local edits (161 matched lines × 2 locations) clients/admin/src/pages/tenants/list.tsx:41— clients/admin/src/pages/tenants/list.tsx:41 · clients/admin/src/pages/users/list.tsx:79 — the two spans are one implementation copied and then locally edited — 880 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 (137 lines × 2 locations) clients/admin/src/pages/settings/layout.tsx:64— clients/admin/src/pages/settings/layout.tsx:64 · clients/dashboard/src/pages/settings/settings-layout.tsx:62 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another.
R10 · Code Duplication· Duplicated block with local edits (129 matched lines × 2 locations) · ×1
Duplicated block with local edits (129 matched lines × 2 locations) clients/dashboard/src/pages/identity/groups.tsx:191— clients/dashboard/src/pages/identity/groups.tsx:191 · clients/dashboard/src/pages/identity/roles.tsx:214 — the two spans are one implementation copied and then locally edited — 617 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.
Wholesale file copy (118 identical lines × 2 files) clients/admin/src/components/file/image-input.tsx:2— clients/admin/src/components/file/image-input.tsx:2 · clients/dashboard/src/components/file/image-input.tsx:2 — these 2 files are line-for-line copies of one another — 118 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication· Duplicated block with local edits (112 matched lines × 2 locations) · ×1
Duplicated block with local edits (112 matched lines × 2 locations) clients/admin/src/realtime/realtime-context.tsx:40— clients/admin/src/realtime/realtime-context.tsx:40 · clients/dashboard/src/realtime/realtime-context.tsx:50 — the 2 copies are spread across 2 files, and the CITED SPAN is inside a TYPE DECLARATION, not executable code. There is no function to extract and no call site to call one from, so do not read this as an extract-a-helper row: the collapse a type offers is a generic — name the shape once, parameterised over the part that varies, and have each copy instantiate it. First check what actually differs between the copies: where they are a MATRIX of cases (one entry per input, differing precisely in the case each one pins), the repetition IS the enumeration and collapsing it would delete cases rather than de-duplicate anything — leave those alone. Reported because the copies that are not a matrix drift apart the first time only one of them is edited.
R10 · Code Duplication· Duplicated block with local edits (110 matched lines × 2 locations) · ×1
Duplicated block with local edits (110 matched lines × 2 locations) clients/dashboard/src/pages/system/sessions.tsx:58— clients/dashboard/src/pages/system/sessions.tsx:58 · clients/dashboard/src/pages/tickets/tickets.tsx:89 — the two spans are one implementation copied and then locally edited — 627 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 (109 matched lines × 2 locations) · ×1
Duplicated block with local edits (109 matched lines × 2 locations) clients/dashboard/src/pages/identity/groups.tsx:52— clients/dashboard/src/pages/identity/groups.tsx:52 · clients/dashboard/src/pages/identity/roles.tsx:54 — the two spans are one implementation copied and then locally edited — 629 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 (101 matched lines × 2 locations) · ×1
Duplicated block with local edits (101 matched lines × 2 locations) clients/admin/src/pages/billing/invoices-list.tsx:254— clients/admin/src/pages/billing/invoices-list.tsx:254 · clients/admin/src/pages/billing/topups-list.tsx:271 — the two spans are one implementation copied and then locally edited — 620 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 (99 matched lines × 2 locations) · ×1
Duplicated block with local edits (99 matched lines × 2 locations) clients/admin/src/components/list/select.tsx:10— clients/admin/src/components/list/select.tsx:10 · clients/admin/src/components/ui/select.tsx:10 — the two spans are one implementation copied and then locally edited — 426 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 (98 matched lines × 2 locations) · ×1
Duplicated block with local edits (98 matched lines × 2 locations) clients/admin/src/components/roles/create-role-dialog.tsx:38— clients/admin/src/components/roles/create-role-dialog.tsx:38 · clients/admin/src/components/users/create-user-dialog.tsx:78 — the two spans are one implementation copied and then locally edited — 480 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.
Wholesale file copy (98 identical lines × 2 files) clients/admin/src/components/ui/dialog.tsx:1— clients/admin/src/components/ui/dialog.tsx:1 · clients/dashboard/src/components/ui/dialog.tsx:1 — these 2 files are line-for-line copies of one another — 98 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication· Duplicated block with local edits (94 matched lines × 2 locations) · ×1
Duplicated block with local edits (94 matched lines × 2 locations) clients/dashboard/src/pages/identity/roles.tsx:238— clients/dashboard/src/pages/identity/roles.tsx:238 · clients/dashboard/src/pages/tickets/tickets.tsx:340 — the two spans are one implementation copied and then locally edited — 442 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.
Wholesale file copy (89 identical lines × 2 files) clients/admin/src/api/files.ts:1— clients/admin/src/api/files.ts:1 · clients/dashboard/src/api/files.ts:1 — these 2 files are line-for-line copies of one another — 89 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication· Duplicated block with local edits (79 matched lines × 2 locations) · ×1
Duplicated block with local edits (79 matched lines × 2 locations) clients/admin/src/auth/auth-context.tsx:82— clients/admin/src/auth/auth-context.tsx:82 · clients/dashboard/src/auth/auth-context.tsx:134 — the two spans are one implementation copied and then locally edited — 429 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 (73 matched lines × 2 locations) · ×1
Duplicated block with local edits (73 matched lines × 2 locations) clients/dashboard/src/pages/catalog/brands.tsx:282— clients/dashboard/src/pages/catalog/brands.tsx:282 · clients/dashboard/src/pages/catalog/products.tsx:608 — the two spans are one implementation copied and then locally edited — 283 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.
Wholesale file copy (72 identical lines × 2 files) clients/admin/src/components/ui/avatar.tsx:1— clients/admin/src/components/ui/avatar.tsx:1 · clients/dashboard/src/components/ui/avatar.tsx:1 — these 2 files are line-for-line copies of one another — 72 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
R10 · Code Duplication· Duplicated block with local edits (72 matched lines × 2 locations) · ×1
Duplicated block with local edits (72 matched lines × 2 locations) clients/admin/src/pages/roles/list.tsx:62— clients/admin/src/pages/roles/list.tsx:62 · clients/admin/src/pages/users/list.tsx:109 — the two spans are one implementation copied and then locally edited — 361 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.
Wholesale file copy (71 identical lines × 2 files) clients/admin/src/components/ui/dropdown-menu.tsx:1— clients/admin/src/components/ui/dropdown-menu.tsx:1 · clients/dashboard/src/components/ui/dropdown-menu.tsx:1 — these 2 files are line-for-line copies of one another — 71 lines are identical, in the same order, in every one of them — so this is one fact about the file set, not a block to extract. An edit made to one file and not the others changes behaviour silently, which is the failure a wholesale copy guarantees. Pick one file as the single source and derive the others from it (re-export it, spread it into the local overrides each variant genuinely needs, or generate the copies at build time) — the few lines that differ between the files are exactly the part each variant should still own. Check first whether the copies are deliberately standalone deliverables (a translation file seeded from its sibling and waiting to be translated); where they are, the duplication is the design, and the honest move is to mark the seeded file as untranslated rather than to let it pass as done.
Duplicated block (71 lines × 2 locations) clients/admin/src/pages/login.tsx:206— clients/admin/src/pages/login.tsx:206 · clients/dashboard/src/pages/login.tsx:155 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another.
R10 · Code Duplication· Duplicated block with local edits (70 matched lines × 2 locations) · ×1
Duplicated block with local edits (70 matched lines × 2 locations) clients/admin/src/api/billing.ts:135— clients/admin/src/api/billing.ts:135 · clients/dashboard/src/api/billing.ts:33 — the two spans are one implementation copied and then locally edited — 467 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 (68 lines × 2 locations) clients/admin/src/components/ui/button.tsx:20— clients/admin/src/components/ui/button.tsx:20 · clients/dashboard/src/components/ui/button.tsx:12 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are.
R10 · Code Duplication· Duplicated block with local edits (63 matched lines × 2 locations) · ×1
Duplicated block with local edits (63 matched lines × 2 locations) clients/admin/src/components/layout/mobile-nav.tsx:76— clients/admin/src/components/layout/mobile-nav.tsx:76 · clients/dashboard/src/components/layout/mobile-nav.tsx:65 — the two spans are one implementation copied and then locally edited — 300 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one.
Complex function UserDetailPage (cyclomatic 55, cognitive 53) clients/dashboard/src/pages/identity/user-detail.tsx:84— UserDetailPage has cyclomatic complexity 55 and cognitive complexity 53; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive 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 InvoiceDetailPage (cyclomatic 41, cognitive 36) clients/admin/src/pages/billing/invoice-detail.tsx:73— InvoiceDetailPage has cyclomatic complexity 41 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 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 TenantDetailPage (cyclomatic 40, cognitive 35) clients/admin/src/pages/tenants/detail.tsx:50— TenantDetailPage has cyclomatic complexity 40 and cognitive complexity 35; 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 OverviewPage (cyclomatic 40, cognitive 34) clients/dashboard/src/pages/overview.tsx:942— OverviewPage has cyclomatic complexity 40 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
Complex function Message (cyclomatic 39, cognitive 33) clients/dashboard/src/pages/chat/message.tsx:54— Message has cyclomatic complexity 39 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 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 RoleDetailPage (cyclomatic 35, cognitive 34) clients/dashboard/src/pages/identity/role-detail.tsx:66— RoleDetailPage has cyclomatic complexity 35 and cognitive complexity 34; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes.
Complex function AuditsListPage (cyclomatic 33, cognitive 29) clients/admin/src/pages/audits/list.tsx:40— AuditsListPage has cyclomatic complexity 33 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 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 UserDetailPage (cyclomatic 33, cognitive 27) clients/admin/src/pages/users/detail.tsx:26— UserDetailPage has cyclomatic complexity 33 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 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 UsersListPage (cyclomatic 29, cognitive 22) clients/admin/src/pages/users/list.tsx:29— UsersListPage has cyclomatic complexity 29 and cognitive complexity 22; 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 WebhookDetailPage (cyclomatic 28, cognitive 25) clients/admin/src/pages/webhooks/detail.tsx:42— WebhookDetailPage has cyclomatic complexity 28 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 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 AuditsPage (cyclomatic 26, cognitive 24) clients/dashboard/src/pages/audits.tsx:187— AuditsPage has cyclomatic complexity 26 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 GroupDetailPage (cyclomatic 24, cognitive 24) clients/dashboard/src/pages/identity/group-detail.tsx:74— GroupDetailPage has cyclomatic complexity 24 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 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 TopupsListPage (cyclomatic 24, cognitive 23) clients/admin/src/pages/billing/topups-list.tsx:96— TopupsListPage has cyclomatic complexity 24 and cognitive complexity 23; 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 apiFetch (cyclomatic 23, cognitive 24) clients/admin/src/lib/api-client.ts:108— apiFetch has cyclomatic complexity 23 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 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 StepRow (cyclomatic 23, cognitive 21) clients/admin/src/pages/tenants/detail.tsx:542— StepRow has cyclomatic complexity 23 and cognitive complexity 21; 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 TenantsListPage (cyclomatic 23, cognitive 18) clients/admin/src/pages/tenants/list.tsx:25— TenantsListPage has cyclomatic complexity 23 and cognitive complexity 18; 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 ProductEditorDialog (cyclomatic 23, cognitive 17) clients/dashboard/src/pages/catalog/products.tsx:811— ProductEditorDialog has cyclomatic complexity 23 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 apiFetch (cyclomatic 22, cognitive 23) clients/dashboard/src/lib/api-client.ts:155— apiFetch has cyclomatic complexity 22 and cognitive complexity 23; 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.
Dead file (~107 LoC) clients/admin/src/components/auth/auth-shell.tsx— no import path from any entry point (32 application, 6 tooling, 61 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 (~77 LoC) clients/admin/src/components/ui/table.tsx— no import path from any entry point (32 application, 6 tooling, 61 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 (~68 LoC) clients/admin/src/components/brand-mark.tsx— no import path from any entry point (32 application, 6 tooling, 61 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (clients/admin/src/components/auth/auth-shell.tsx) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it
Dead file (~51 LoC) clients/admin/src/components/ui/switch.tsx— no import path from any entry point (32 application, 6 tooling, 61 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 (~26 LoC) clients/admin/src/components/theme/theme-toggle.tsx— no import path from any entry point (32 application, 6 tooling, 61 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 (~11 LoC) clients/admin/src/pages/tenants/create.tsx— no import path from any entry point (32 application, 6 tooling, 61 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
Swallowed exception (caught, then discarded) src/Tools/CLI/Infrastructure/NuGetClient.cs:55— `catch` takes every exception and records none of it — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch and only the substituted value survives. Log it through whatever this codebase already uses to report problems, narrow the catch to the exception this call can actually raise, or say in a comment on the catch why the failure genuinely cannot matter.
Minor — 145 finding(s)
DM2 · Strongly-typed ids· Primitive id on a domain type · ×40
Primitive id on a domain type: DomainEvent.EventId src/BuildingBlocks/Core/Domain/DomainEvent.cs:11— `DomainEvent.EventId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: DomainEvent.CorrelationId src/BuildingBlocks/Core/Domain/DomainEvent.cs:13— `DomainEvent.CorrelationId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: DomainEvent.TenantId src/BuildingBlocks/Core/Domain/DomainEvent.cs:14— `DomainEvent.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: IDomainEvent.EventId src/BuildingBlocks/Core/Domain/IDomainEvent.cs:14— `IDomainEvent.EventId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: IDomainEvent.CorrelationId src/BuildingBlocks/Core/Domain/IDomainEvent.cs:24— `IDomainEvent.CorrelationId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: IDomainEvent.TenantId src/BuildingBlocks/Core/Domain/IDomainEvent.cs:29— `IDomainEvent.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: BillingPlan.Key src/Modules/Billing/Modules.Billing/Domain/BillingPlan.cs:19— `BillingPlan.Key` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: Invoice.TenantId src/Modules/Billing/Modules.Billing/Domain/Invoice.cs:15— `Invoice.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: InvoiceLineItem.InvoiceId src/Modules/Billing/Modules.Billing/Domain/InvoiceLineItem.cs:13— `InvoiceLineItem.InvoiceId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: Subscription.TenantId src/Modules/Billing/Modules.Billing/Domain/Subscription.cs:13— `Subscription.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: Subscription.PlanId src/Modules/Billing/Modules.Billing/Domain/Subscription.cs:14— `Subscription.PlanId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: TopupRequest.TenantId src/Modules/Billing/Modules.Billing/Domain/TopupRequest.cs:8— `TopupRequest.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: TopupRequest.InvoiceId src/Modules/Billing/Modules.Billing/Domain/TopupRequest.cs:12— `TopupRequest.InvoiceId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: UsageSnapshot.TenantId src/Modules/Billing/Modules.Billing/Domain/UsageSnapshot.cs:13— `UsageSnapshot.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: Wallet.TenantId src/Modules/Billing/Modules.Billing/Domain/Wallet.cs:10— `Wallet.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: WalletTransaction.WalletId src/Modules/Billing/Modules.Billing/Domain/WalletTransaction.cs:8— `WalletTransaction.WalletId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: WalletTransaction.TenantId src/Modules/Billing/Modules.Billing/Domain/WalletTransaction.cs:9— `WalletTransaction.TenantId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: WalletTransaction.ReferenceId src/Modules/Billing/Modules.Billing/Domain/WalletTransaction.cs:13— `WalletTransaction.ReferenceId` is a raw `String` — give it a strongly-typed id: a dedicated single-field type wrapping the `String`, in whatever form your language spells that.
Primitive id on a domain type: Category.ParentCategoryId src/Modules/Catalog/Modules.Catalog/Domain/Category.cs:10— `Category.ParentCategoryId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: Product.BrandId src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:12— `Product.BrandId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: Product.CategoryId src/Modules/Catalog/Modules.Catalog/Domain/Product.cs:13— `Product.CategoryId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: ProductImage.ProductId src/Modules/Catalog/Modules.Catalog/Domain/ProductImage.cs:24— `ProductImage.ProductId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: ProductImage.FileAssetId src/Modules/Catalog/Modules.Catalog/Domain/ProductImage.cs:25— `ProductImage.FileAssetId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: ProductCreatedDomainEvent.ProductId src/Modules/Catalog/Modules.Catalog/Domain/Events/ProductCreatedDomainEvent.cs:6— `ProductCreatedDomainEvent.ProductId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
Primitive id on a domain type: ProductPriceChangedDomainEvent.ProductId src/Modules/Catalog/Modules.Catalog/Domain/Events/ProductPriceChangedDomainEvent.cs:6— `ProductPriceChangedDomainEvent.ProductId` is a raw `Guid` — give it a strongly-typed id: a dedicated single-field type wrapping the `Guid`, in whatever form your language spells that.
+ 15 more in this group — see findings.md.
ED3 · Event naming· Event not named in past tense · ×40
Event not named in past tense: ActivityEventPayload src/Modules/Auditing/Modules.Auditing.Contracts/ActivityEventPayload.cs:3— `ActivityEventPayload` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditEventType src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:8— `AuditEventType` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditSeverity src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:20— `AuditSeverity` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: SecurityAction src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:34— `SecurityAction` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: EntityOperation src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:53— `EntityOperation` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: ActivityKind src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:66— `ActivityKind` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: ExceptionArea src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:79— `ExceptionArea` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: BodyCapture src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:92— `BodyCapture` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditTag src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnums.cs:105— `AuditTag` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditEnvelope src/Modules/Auditing/Modules.Auditing.Contracts/AuditEnvelope.cs:9— `AuditEnvelope` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditHttpOptions src/Modules/Auditing/Modules.Auditing.Contracts/AuditHttpOptions.cs:3— `AuditHttpOptions` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditingContractsMarker src/Modules/Auditing/Modules.Auditing.Contracts/AuditingContractsMarker.cs:4— `AuditingContractsMarker` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditRetentionOptions src/Modules/Auditing/Modules.Auditing.Contracts/AuditRetentionOptions.cs:10— `AuditRetentionOptions` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: EntityChangeEventPayload src/Modules/Auditing/Modules.Auditing.Contracts/EntityChangeEventPayload.cs:3— `EntityChangeEventPayload` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: ExceptionEventPayload src/Modules/Auditing/Modules.Auditing.Contracts/ExceptionEventPayload.cs:3— `ExceptionEventPayload` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: ExceptionSeverityClassifier src/Modules/Auditing/Modules.Auditing.Contracts/ExceptionSeverityClassifier.cs:3— `ExceptionSeverityClassifier` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: MaskingResult src/Modules/Auditing/Modules.Auditing.Contracts/IAuditMaskingService.cs:10— `MaskingResult` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: NoAuditAttribute src/Modules/Auditing/Modules.Auditing.Contracts/NoAuditAttribute.cs:26— `NoAuditAttribute` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: NoAuditEndpointExtensions src/Modules/Auditing/Modules.Auditing.Contracts/NoAuditEndpointExtensions.cs:8— `NoAuditEndpointExtensions` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: NumericEnumConverter src/Modules/Auditing/Modules.Auditing.Contracts/NumericEnumConverter.cs:15— `NumericEnumConverter` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: PropertyChange src/Modules/Auditing/Modules.Auditing.Contracts/PropertyChange.cs:6— `PropertyChange` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: SecurityEventPayload src/Modules/Auditing/Modules.Auditing.Contracts/SecurityEventPayload.cs:3— `SecurityEventPayload` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditingPermissions src/Modules/Auditing/Modules.Auditing.Contracts/Authorization/AuditingPermissions.cs:5— `AuditingPermissions` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditTrails src/Modules/Auditing/Modules.Auditing.Contracts/Authorization/AuditingPermissions.cs:7— `AuditTrails` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Event not named in past tense: AuditDetailDto src/Modules/Auditing/Modules.Auditing.Contracts/Dtos/AuditDetailDto.cs:6— `AuditDetailDto` reads as an instruction, not a fact that happened. Events describe something that already occurred — name them in the past tense (e.g. `OrderPlaced`, `PaymentCaptured`) so the ubiquitous language stays clear.
Documentation: no installation or build instructions README.md— No installation, build or setup instructions for the .NET 10 starter kit. Add a one-line 'dotnet new fsh' command and a short prerequisites section.
Documentation: no usage examples README.md— No usage examples of the two React apps (dashboard/admin) or the CLI tools. Write a brief 'Run everything through Aspire' example for each app, plus a one-line CLI command for dbmigrator.
Documentation: no contributor guidance README.md— No guidance on contributing (new module registration, architecture tests). Add a 'Contributing' section covering new-module registration and the four-place footgun check.
Fat interface: IJobService (17 members) src/BuildingBlocks/Jobs/Services/IJobService.cs:5— `IJobService` declares 17 members under just 4 distinct name(s): `Delete`, `Delete`, `Enqueue`, `Enqueue`, `Enqueue`, `Enqueue`, `Enqueue`, `Requeue`, `Requeue`, `Schedule`, `Schedule`, `Schedule`, `Schedule`, `Schedule`, `Schedule`, `Schedule`, `Schedule`. Counted as the author wrote them — a property is ONE member and its get/set accessors are not counted separately, and an event counts once. That is an OVERLOAD SET, not 17 separate responsibilities: a caller binds to 4 operation(s) and uses the overload it selected, so the Interface-Segregation harm does NOT apply on the caller's side and splitting this into role-interfaces would scatter one operation without relieving anything. The burden that does remain is the IMPLEMENTER's — all 17 signatures must be written and kept in step. Reduce it by collapsing overloads (optional or default parameters, or an options object) rather than by segregating the interface.
Fat interface: IUserService (22 members) src/Modules/Identity/Modules.Identity.Contracts/Services/IUserService.cs:7— `IUserService` declares 22 members: `ExistsWithNameAsync`, `ExistsWithEmailAsync`, `ExistsWithPhoneNumberAsync`, `GetListAsync`, `GetCountAsync`, `GetAsync`, `ToggleStatusAsync`, `GetOrCreateFromPrincipalAsync`, `RegisterAsync`, `UpdateAsync`, `DeleteAsync`, `ConfirmEmailAsync`, `AdminConfirmEmailAsync`, `ResendConfirmationEmailAsync`, `ConfirmPhoneNumberAsync`, `HasPermissionAsync`, `ForgotPasswordAsync`, `ResetPasswordAsync`, `GetPermissionsAsync`, `ChangePasswordAsync`, `AssignRolesAsync`, `GetUserRolesAsync`. Counted as the author wrote them — a property is ONE member and its get/set accessors are not counted separately, and an event counts once. A wide interface forces every implementer and caller to depend on methods they don't use (the Interface-Segregation 'I' in SOLID). Split it into focused role-interfaces.
R7 · Dead Code· Unused export 'DialogTrigger' · ×2
Unused export 'DialogTrigger' clients/admin/src/components/ui/dialog.tsx:26— Nothing imports this binding — it is safe to review for removal.
Unused export 'DialogTrigger' clients/dashboard/src/components/ui/dialog.tsx:24— Nothing imports this binding — it is safe to review for removal.
Unused export 'SheetClose' clients/admin/src/components/ui/dialog.tsx:208— Nothing imports this binding — it is safe to review for removal.
Unused export 'SheetClose' clients/dashboard/src/components/ui/dialog.tsx:192— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'DropdownMenuGroup' · ×2
Unused export 'DropdownMenuGroup' clients/admin/src/components/ui/dropdown-menu.tsx:17— Nothing imports this binding — it is safe to review for removal.
Unused export 'DropdownMenuGroup' clients/dashboard/src/components/ui/dropdown-menu.tsx:17— Nothing imports this binding — it is safe to review for removal.
AC7 · A11y enforcement· Accessibility enforcement below the top rung · ×1
Accessibility enforcement below the top rung — An a11y linter is configured (Documented) but there's no automated a11y test or CI gate. Add @axe-core/playwright to verify at runtime, then gate it in CI. What was searched, so you can tell an absence from a miss: the 190 markup file(s) this pass actually assessed, the linter configuration checked in beside them, and this repository's test and CI files — matched by name against the accessibility checkers this dimension carries. An audit run outside the repository, a hosted scanner, or a check whose name is not one of those, is not seen here.
Off-boarding risk: anonymized user #1 — If anonymized user #1 becomes unavailable, 117 significant file(s) lose their only recent owner: REDACTED, src/Modules/Identity/Modules.Identity/Services/UserRegistrationService.cs, src/Host/FSH.Starter.Migrations.PostgreSQL/Identity/20251222232937_Initial.cs, src/BuildingBlocks/Storage/S3/S3StorageService.cs, src/Modules/Multitenancy/Modules.Multitenancy/Services/TenantThemeService.cs, src/Modules/Multitenancy/Modules.Multitenancy/MultitenancyModule.cs, src/Modules/Identity/Modules.Identity/Services/IdentityService.cs, src/Modules/Identity/Modules.Identity/IdentityModule.cs (+109 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 (118 single-owned of 217 analysed files in total, counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated and example/demo trees and test files identified by path convention, largest first; 217 of the 1292 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.
D21 · Naming Consistency· The term 'Area' is used in the query DTO to represent what is likely a correlation identifier or scope context, while the main audit envelope type is named 'AuditEnvelope'. In the context of auditing, 'Area' is ambiguous and inconsistent with the standard 'CorrelationId' or 'Scope' terminology used elsewhere (e.g., `HttpAuditScope.CorrelationId`). · ×1
The term 'Area' is used in the query DTO to represent what is likely a correlation identifier or scope context, while the main audit envelope type is named 'AuditEnvelope'. In the context of auditing, 'Area' is ambiguous and inconsistent with the standard 'CorrelationId' or 'Scope' terminology used elsewhere (e.g., `HttpAuditScope.CorrelationId`). — Rename 'Area' to 'CorrelationId' or 'Scope' to align with the domain concept of tracing audit events. (symbols: FSH.Modules.Auditing.Contracts.AuditEnvelope, FSH.Modules.Auditing.Contracts.v1.GetExceptionAudits.GetExceptionAuditsQuery.Area)
D26 · Project Cohesion· Projects may be oversized for their cohesion · ×1
Projects may be oversized for their cohesion — 1 of 50 project(s) overshoot their size bounds, lowering Project Cohesion to 9.6/10. The most over is `Modules.Identity` (9078 LoC, 197 public types across 62 namespaces). Review these for cohesion — split a project that spans unrelated responsibilities.
D28 · Secrets (history)· Rotate the exposed credentials · ×1
Mutable entity: TenantTheme src/Modules/Multitenancy/Modules.Multitenancy/Domain/TenantTheme.cs:5— `TenantTheme` exposes publicly writable state (PrimaryColor, SecondaryColor, TertiaryColor, BackgroundColor, SurfaceColor, ErrorColor, and 22 more).
DM8 · Value-object opportunities· Primitive data clump · ×1
Primitive data clump: [authoruserid, channelid, eventid, messageid] src/Modules/Chat/Modules.Chat/Domain/Events/MessageDeletedDomainEvent.cs:5— The parameters [authoruserid, channelid, eventid, messageid] travel together across 4 signatures — that's a missing value object. Extracting them into one type (e.g. `Address`, `Money`, `Coordinate`) removes repetition, prevents argument-order mistakes, and gives the concept a home for its rules.
DM9 · Scattered domain decisions· Rule about [Status, TenantId] decided in 4 places · ×1
Rule about [Status, TenantId] decided in 4 places — FSH.Modules.Billing.Domain.Subscription's [Status, TenantId] are judged in FSH.Modules.Billing.Features.v1.Subscriptions.AssignSubscription.AssignSubscriptionCommandHandler, FSH.Modules.Billing.Features.v1.Subscriptions.GetSubscription.GetSubscriptionQueryHandler, FSH.Modules.Billing.IntegrationEventHandlers.TenantSubscriptionMaintenance, FSH.Modules.Billing.Services.BillingService — the same decision, restated. Every copy is a chance to drift, and copies drift silently because each one looks correct on its own. Move the judgement onto the type that owns the members and let the call sites ask it.
DM9 · Scattered domain decisions· Rule about [ChannelId, DeletedAtUtc] decided in 2 places · ×1
Rule about [ChannelId, DeletedAtUtc] decided in 2 places — FSH.Modules.Chat.Domain.Message's [ChannelId, DeletedAtUtc] are judged in FSH.Modules.Chat.Features.v1.Channels.GetChannelById.GetChannelByIdQueryHandler, FSH.Modules.Chat.Features.v1.Channels.ListMyChannels.ListMyChannelsQueryHandler — the same decision, restated. Every copy is a chance to drift, and copies drift silently because each one looks correct on its own. Move the judgement onto the type that owns the members and let the call sites ask it.
DM9 · Scattered domain decisions· Rule about [ClaimType, RoleId] decided in 2 places · ×1
Rule about [ClaimType, RoleId] decided in 2 places — Microsoft.AspNetCore.Identity.IdentityRoleClaim<string>'s [ClaimType, RoleId] are judged in FSH.Modules.Identity.Authorization.RolePermissionSyncer, FSH.Modules.Identity.Features.v1.Roles.RoleService — the same decision, restated. Every copy is a chance to drift, and copies drift silently because each one looks correct on its own. Move the judgement onto the type that owns the members and let the call sites ask it.
DM9 · Scattered domain decisions· Rule about [ReadAtUtc, UserId] decided in 2 places · ×1
Rule about [ReadAtUtc, UserId] decided in 2 places — FSH.Modules.Notifications.Domain.Notification's [ReadAtUtc, UserId] are judged in FSH.Modules.Notifications.Features.v1.GetUnreadCount.GetUnreadCountQueryHandler, FSH.Modules.Notifications.Features.v1.MarkAllNotificationsRead.MarkAllNotificationsReadCommandHandler — the same decision, restated. Every copy is a chance to drift, and copies drift silently because each one looks correct on its own. Move the judgement onto the type that owns the members and let the call sites ask it.
Disabled test src/Tests/Integration.Tests/Tests/Chat/ChatSendMessageTests.cs:74— A test is skipped ("Idempotency replay does not engage in the test environment — IDistributedCache (probe) and HybridCache (write-through) are wired to separate in-process stores, so the second call never sees the cached response. Same caveat as IdempotencyFilterTests.cs: 'full replay-with-matching-body coverage is not yet possible'. Backlog item 2.4b tracks the fix.") — coverage that looks present but never runs in any gate. If it's an opt-in suite, document how it runs; otherwise re-enable or delete it.
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.
P10 · Library API & versioning· Large public API surface · ×1
Large public API surface — 1358/1666 types (82%) are public. For a library, every public type is a stability contract — make internal-by-default and expose only the intended API.
P12 · CI test-gate honesty· Sleep-based test synchronization · ×1
Sleep-based test synchronization — 68 Task.Delay/Thread.Sleep call(s) in test code synchronize with background work by sleeping — a known flakiness precursor on slow runners. Prefer polling with a deadline or completion signals.
Logging is not universal — Only 19/24 service-like projects use logging (pure contract/DTO projects are excluded — they have nothing to log). Of those 24, 4 ship a process this repository operates; the rest are libraries their consumer hosts, where the logging decision belongs to the host.
No release approval gate — Deployment is automated and no gate that pauses it for a human is DECLARED IN THIS REPOSITORY'S PIPELINE FILES. What was read: every file under `.github/workflows/`, `.forgejo/workflows/`, `.gitea/workflows/`, `.azuredevops/` and `.azure-pipelines/`, plus `.gitlab-ci*` and `azure-pipelines*` — with comment text stripped, so documenting a gate is not declaring one. What would have counted: GitLab's `when: manual`, CircleCI's `type: approval`, an Azure `ManualValidation@` task or an `approvals:` block, a Jenkins `input` step, a `uses:` step naming an approval action, an `environment:` paired with `reviewers` / `required_reviewers` / `protection` / `wait-timer` / `deployment_branch_policy`, a draft-release step, a `workflow_dispatch` promotion, or a release-event gate. ★ What this cannot see, because none of it is a file: a GitHub environment whose required reviewers are configured in repo SETTINGS, a branch protection rule, or an organisation deployment policy — all of them real, enforced gates that live outside the repository. If yours is one of those, this row is wrong and nothing in the tree could have told us. Otherwise: whatever reaches the release trigger goes to production unreviewed, so a mistaken merge or tag is live before anyone can stop it.
PF1 · Benchmark discipline· No performance benchmarks · ×1
No performance benchmarks — No benchmark suite was found by the two searches this check runs. FIRST, a BenchmarkDotNet package reference in any project file — every project the workspace loaded, plus a walk of project files on disk that never loaded, because a benchmark suite is exactly the project a partial load drops. SECOND, a script harness: a file whose name contains `benchmark` and ends `.py`, `.sh`, `.ps1`, `.bash`, `.rb`, `.js` or `.mjs`, credited ONLY when this repository's CI text also mentions benchmarks — a harness no pipeline runs is read as a fixture, deliberately. Neither search can see a benchmark suite in another ecosystem's idiom (a Go `testing.B` file, a JMH or criterion project, a pytest-benchmark run), so this is 'no benchmark found by those two searches', not a verdict that the repository has none. Where code is performance-sensitive, a benchmark guards against silent regressions — but it's a bonus here, not a deduction.
R7 · Dead Code· Unused export 'getSubscription' · ×1
Unused export 'getSubscription' clients/admin/src/api/billing.ts:116— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'assignSubscription' · ×1
Unused export 'assignSubscription' clients/admin/src/api/billing.ts:123— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'generateInvoices' · ×1
Unused export 'generateInvoices' clients/admin/src/api/billing.ts:229— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'getFileDownloadUrl' · ×1
Unused export 'getFileDownloadUrl' clients/admin/src/api/files.ts:82— Nothing imports this binding — it is safe to review for removal.
Unused export 'FormActions' clients/admin/src/components/list/form-shell.tsx:88— Nothing ultimately consumes this binding: its only referrer is the re-export in clients/admin/src/components/list/index.ts, whose re-exported name has no consumer either. Removing it is therefore not a one-file change — drop the re-export line in clients/admin/src/components/list/index.ts in the same commit, or the barrel will import a name that no longer exists.
Unused export 'DialogClose' clients/admin/src/components/ui/dialog.tsx:28— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'DropdownMenuRow' · ×1
Unused export 'DropdownMenuRow' clients/admin/src/components/ui/dropdown-menu.tsx:117— Nothing imports this binding — it is safe to review for removal.
R7 · Dead Code· Unused export 'ALL_PERMISSION_NAMES' · ×1
Unused export 'ALL_PERMISSION_NAMES' clients/admin/src/lib/permissions.ts:188— Nothing imports this binding — it is safe to review for removal.
Unused export 'useSse' clients/dashboard/src/sse/sse-context.tsx:230— Nothing imports this binding — it is safe to review for removal.
X2 · Cancellation propagation· Not all async methods take a CancellationToken · ×1
Not all async methods take a CancellationToken — Only 470/491 async methods accept a CancellationToken, so in-flight work can't be stopped early when the caller gives up — whatever ends it in your host (shutdown signal, timeout, abandoned request, user cancel). Thread a token through the call chain and honour it at each await and loop; where a method genuinely cannot be interrupted, omitting it is a deliberate choice — judge against your hosting model.
Null-forgiving operator (`!`) suppressions reduce the NRT score — ~0.6 `!` suppressions per 1k syntax nodes — 225 suppression(s) across the 363962 syntax node(s) in code where nullable warnings are ENABLED, which is the only code a `!` can suppress anything in (a `!` under `#nullable disable` is inert and is not counted, and its file's nodes are not in the denominator). Each one tells the compiler to trust you about null, suppressing the very safety NRTs provide.
Silent fallback default on parse failure src/BuildingBlocks/Quota/RedisQuotaService.cs:154— `GetCurrentAsync` falls back to `0` when `value.TryParse(out long parsed)` is false, with no log or throw — a malformed value silently becomes that default. Log the input or fail validation. If that constant is the correct answer to the test rather than a stand-in for a value that could not be read, this is not a silent default: say so in a comment on the member and the row stops firing.
Skipped (documented): SendMessage_Should_Replay_Same_Response_When_Idempotency_Key_Reused src/Tests/Integration.Tests/Tests/Chat/ChatSendMessageTests.cs:74— Skipped with a documented reason — a deferral, not lazy debt: Idempotency replay does not engage in the test environment — IDistributedCache (probe) and HybridCache (write-through) are wired to separate in-process stores, so the second call never sees the cached response. Same caveat as IdempotencyFilterTests.cs: 'full replay-with-matching-body coverage is not yet possible'. Backlog item 2.4b tracks the fix.
Webhooks: 2 contract type(s) expose producer-owned ids/enums — In Webhooks, 2 contract type(s) (DeleteWebhookSubscriptionCommand, TestWebhookSubscriptionCommand) expose strong-typed ids/value objects (DeleteWebhookSubscriptionCommand, TestWebhookSubscriptionCommand); a serialized contract could expose the underlying primitive instead. Advisory — a deliberate strong-ID style is fine.
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.
nuget: not applicable — nuget: the solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan
provenance: not applicable — This is a dotnet-new template — it produces no released artifact to attest. Supply-chain provenance, signing and SBOM are deferred to the application you build from it (add SLSA provenance / cosign signing / an SBOM in your app's release pipeline).
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.
nuget: not applicable — nuget: the solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan
Run 01a0c38a-ebbf-75d6-abac-27a7e376ea9b · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.
Appendix C — Personal-data map
Every field, property and record parameter whose name is conventional personal data — 42 field(s) across 3 categories, each with an exact repo-relative file:line. This is the data inventory a compliance review starts from — right-to-erasure, retention, minimisation. Detected by NAME, from the C# syntax tree, with a deliberately specific identifier classifier — the same one the C1–C5 compliance cards use to decide whether personal data is present, so CardDefinition or FileName don't trip. Two caveats stated rather than glossed: those cards additionally require corroboration (a persistence/account signal, or two distinct PII categories) that this inventory deliberately does not, so it lists more than they gate on; and D32 Data Compliance shares nothing with it — that dimension is a separate semgrep ruleset for personal data leaking into logs, URLs and browser storage, and a clean D32 result says nothing about this list. Informational — it feeds no score.
Issues: 205 · Warnings: 578 · Recommendations: 145 · Info: 54 — Appendix A · all findings · full markdown report.
Generated by Watchdog — deterministic code-health analysis. 21-09-2026 @ 10:37 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.