Public report of productdevbook/port-killer, published 14 November 2026. It has the same score, grades and number of
findings as the full report. The details of security findings (where they are in the code, which known
vulnerabilities and which passwords or keys were found) are left out, so nobody can use them against the project.
Public
Executive reportMeasured under the Code Assurance Index, an open standard for code quality, using its published scoring rules (rubric version 2026.11.4). Assert signed this survey and filed it in the standard's public register, where anyone can look it up by its survey ID. Check this survey →
Signed and filed in the standard's public register, 14 November 2026, 21:49 UTC · Survey ID cd_e1b0497076104370a8c15566eac7c5be
productdevbook/port-killer
Measured 14 November 2026, 21:49 UTC, at code version 2209b0f
CAI scoreAdequate
CriticalWeakAdequateStrongExemplary
Up 6 since the last survey
The score is built from these lenses. Each lens grades one area of the code, such as how easy it is to change or how well it is protected. The weakest lens counts most, so one weak area pulls the score down instead of being averaged away.
A medium codebase: 21,235 lines of product code in 1 project, tests not counted · Estimated rebuild effort: about 0.2 person-years · Weakest lens: Performance, 60
Findings by how serious they are
47 critical157 serious28 minor
17 dimensions are left out of the score. For each one, we either couldn't measure it in this code, or found no evidence of the safeguard we look for, such as a tested backup restore. They count neither for nor against the score, and Limitations lists each one with its reason.
This survey was produced by
Canine Code Analyzer
Producer
Canine Development
Analyzer
Canine Code Analyzer engine 1.0.0
Measured
14 November 2026, 21:49 UTC
A measurement, not a certificate. The Code Assurance Index records a number
together with the evidence it was worked out from, so anyone can recalculate it, but it doesn't certify or guarantee
the code. The standard was written by Canine Development, which also builds the Canine Code Analyzer. It is open to any tool that
implements it, and today the Canine Code Analyzer is the only one that does.
The score is deterministic, which means the same code always gets the same score. We work it out with tools that follow published rules, and an AI model never decides it, so anyone who applies the same rules to the same code gets the same number. How it is done is explained under Methodology ▸
43of 43 dimensions measured by tools.
221of 232 findings point to an exact file and line, so you can open each one in the code. The other 11 concern the repository as a whole, such as missing documentation.
43dimensions across 6 lenses, read from 21,235 lines of product code in 1 project.
productdevbook/port-killer falls short of our standard for production, held back most by its Performance lens, the way the code guards its speed and its use of resources. It scores 63 out of 100 and is rated Adequate, and 36 of its 47 critical findings are security problems.
Performance, at 60, is the weakest lens, level with Production Readiness, and counts most in the score. The best first step is removing the blocking calls, worth about 3 points. Automating dependency updates comes next, worth about 2 points. Raising Performance to 70 would lift the score to about 65.
Twenty-eight pipeline tools are referenced by a changeable name, so the build pipeline can be tampered with. Four known security holes in the packages the code depends on can be used by attackers, and eleven errors are caught and ignored, so failures can go unnoticed. Pinning each tool to an exact version, updating the vulnerable packages and handling or logging the ignored errors would close these risks. Passing outside input through environment variables would fix the pipeline step that puts outside input straight into a shell command, and the pipeline step that runs a download without checking it needs each download checked against a known checksum first.
The product code is 21,235 lines, about €32,000 to rebuild.
A lens is capped at Adequate while one of its dimensions scores below 4 out of 10, however well the rest of the lens does. That way a serious problem in one place always shows in the lens's rating.
How the score is built: what each lens counts forThe lenses don't count equally. The weakest lens counts most, the next weakest a little less, and so on, so a weak area pulls the score down instead of being averaged away. In the bar below, each part's width shows how much that lens counts and its colour shows its rating. Improving the widest part moves the score most, and as that lens improves, it counts for less, because another lens becomes the weakest.
We compare every finding with the previous survey's. A finding that has only moved to another line in the same file counts as the same finding, so only new findings appear here. Advisory notes from the AI model are left out, because the model words them afresh in every survey.
Fixed since the last survey: 20 findings
These 20 critical or serious findings were in the previous survey, on 28 October 2026, and are gone from this one.
Code Duplication · Edited copy of a member (9 corresponding lines) platforms/windows/PortKiller/MainWindow.xaml.cs
Code Duplication · Members sharing a duplicated core (4 members, 50+ identical tokens) platforms/macos/Sources/Services/PortGroupingService.swift
Cancellation propagation · Async method without CancellationToken: StopButton_Click platforms/windows/PortKiller/CloudflareTunnelsView.xaml.cs
Cancellation propagation · Async method without CancellationToken: StopAllButton_Click platforms/windows/PortKiller/CloudflareTunnelsView.xaml.cs
Cancellation propagation · Async method without CancellationToken: StopAllTunnels_Click platforms/windows/PortKiller/MainWindow.xaml.cs
Cancellation propagation · Async method without CancellationToken: TunnelStop_Click platforms/windows/PortKiller/MainWindow.xaml.cs
Cancellation propagation · Async method without CancellationToken: StopTunnel_Click platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs
Cancellation propagation · Async method without CancellationToken: StopAllTunnelsAsync platforms/windows/PortKiller/Services/TunnelService.cs
Cancellation propagation · Async method without CancellationToken: StopTunnelAsync platforms/windows/PortKiller/ViewModels/TunnelViewModel.cs
Cancellation propagation · Async method without CancellationToken: StopAllTunnelsAsync platforms/windows/PortKiller/ViewModels/TunnelViewModel.cs
Rebuild cost: about €32,000 · Estimate
Cost to rebuild
€11,000 to €54,000, for 178 to 567 hours of work, about 0.2 person-years for one engineer
Difficulty of the problem
Standard, judged from the kind of software and how it is built. Code that solves a harder problem, such as payments or medical bookings, costs more per line to write.
Quality factor
×0.9 at a score of 63. Better code takes more work to write, so the factor is ×1.0 at a score of 70, lower below it and higher above it.
Size
Medium: 21,235 lines of product code
Comment lines
The estimate prices 20,782 lines. Comment lines count towards the size of 21,235 lines but aren't priced as work.
What it is not
Not a quotation: nobody has offered to build it for that. Not a valuation: it says nothing about what the business is worth. Not a certified figure: no professional has signed it as one.
How the estimate is made: We price the hours a team would need to write this code again, at €60 to €95 an hour. Declarations and boilerplate are priced at a fast rate and logic at a slower one, and the logic is then multiplied by the difficulty of the problem and by the quality factor. The estimate can be about 30% off either way, and it moves most with the hourly rate and the difficulty.
Top priorities
The three actions that raise the score most for the work they take. The full ranked list is in the Roadmap.
1
Swift: await instead of blocking — `try await Task.sleep(for:)` for Thread.sleep/sleep, a checked continuation instead of a DispatchSemaphore or DispatchGroup wait, the async Process and URLSession APIs; never park a thread waiting on a Task — the cooperative pool cannot guarantee it progress.
Resolve the 1 No ADRs found finding(s) in ADR Quality — start with PortKiller.csproj.
Raises the score by about 0.9 points · Low effort · ADR Quality
Diagnosis: what the measurements show together
Each conclusion below combines several dimensions into one point that no single dimension shows, and lists the measurements it rests on.
Where the investment is most exposed · Value at risk
This code would cost about €32,000 to build again, about 0.2 person-years of work. Its weakest lens is Performance, at 60 (Adequate). Performance is about whether the code is written and measured with speed in mind. Because the weakest lens counts most in the score, work on Performance also moves the score most.
Based on: the rebuild estimate · the Performance grade · how much each lens counts
What to do: Start with the Performance actions in Top priorities.
If you do one thing first · First action
Swift: await instead of blocking — `try await Task.sleep(for:)` for Thread.sleep/sleep, a checked continuation instead of a DispatchSemaphore or DispatchGroup wait, the async Process and URLSession APIs; never park a thread waiting on a Task — the cooperative pool cannot guarantee it progress. Of all the actions in this report, it raises the score most for the work it takes: about 3 points for medium effort. The next survey will show the change in the score.
Based on: the ranked actions in Top priorities, by score gain and effort
Architecture: which parts of the code depend on which
The code is divided into modules, groups of code that each handle one part of the product, and a module depends on another when it uses code from it. The table lists the modules both down the side and across the top, in an order where each module should only use modules listed above it. A number in a cell means the module on that row uses the module in that column, and it counts the pairs of building blocks (types) that connect them. The one thing to look for is a mark above the diagonal line. It means two or more modules use each other in a loop (a dependency cycle), so none of them can be changed, tested or released on its own.
29 modules, with 33 dependencies between them. Every module uses only modules listed above it, so there are no loops.
Which modules use which. The module on each row uses the module in each column, and the number counts the pairs of types that connect them. A cell above the diagonal is part of a loop.
PortKiller.Services uses PortKiller.Models, so a change to PortKiller.Models can break PortKiller.Services, while a change to PortKiller.Services can't break PortKiller.Models.
Position
Below the diagonal: PortKiller.Services uses a module listed above it, which is the healthy direction.
33 pairs of types, where a type in platforms~macos~Models uses a type in platforms~macos~Extensions. Showing 25 of them; the rest are in namespace-graph.json in this report's bundle.
platforms~macos~Models uses platforms~macos~Extensions, so a change to platforms~macos~Extensions can break platforms~macos~Models, while a change to platforms~macos~Models can't break platforms~macos~Extensions.
Position
Below the diagonal: platforms~macos~Models uses a module listed above it, which is the healthy direction.
portkiller_core uses portkiller_core.scanner, so a change to portkiller_core.scanner can break portkiller_core, while a change to portkiller_core can't break portkiller_core.scanner.
Position
Below the diagonal: portkiller_core uses a module listed above it, which is the healthy direction.
portkiller_core.process.linux uses portkiller_core.process, so a change to portkiller_core.process can break portkiller_core.process.linux, while a change to portkiller_core.process.linux can't break portkiller_core.process.
Position
Below the diagonal: portkiller_core.process.linux uses a module listed above it, which is the healthy direction.
portkiller_core.scanner.linux uses portkiller_core.models, so a change to portkiller_core.models can break portkiller_core.scanner.linux, while a change to portkiller_core.scanner.linux can't break portkiller_core.models.
Position
Below the diagonal: portkiller_core.scanner.linux uses a module listed above it, which is the healthy direction.
portkiller_core.scanner.linux uses portkiller_core.scanner, so a change to portkiller_core.scanner can break portkiller_core.scanner.linux, while a change to portkiller_core.scanner.linux can't break portkiller_core.scanner.
Position
Below the diagonal: portkiller_core.scanner.linux uses a module listed above it, which is the healthy direction.
PortKiller.ViewModels uses PortKiller.Models, so a change to PortKiller.Models can break PortKiller.ViewModels, while a change to PortKiller.ViewModels can't break PortKiller.Models.
Position
Below the diagonal: PortKiller.ViewModels uses a module listed above it, which is the healthy direction.
PortKiller.ViewModels uses PortKiller.Services, so a change to PortKiller.Services can break PortKiller.ViewModels, while a change to PortKiller.ViewModels can't break PortKiller.Services.
Position
Below the diagonal: PortKiller.ViewModels uses a module listed above it, which is the healthy direction.
platforms~macos~Protocols uses platforms~macos~Extensions, so a change to platforms~macos~Extensions can break platforms~macos~Protocols, while a change to platforms~macos~Protocols can't break platforms~macos~Extensions.
Position
Below the diagonal: platforms~macos~Protocols uses a module listed above it, which is the healthy direction.
platforms~macos~Protocols uses platforms~macos~Models, so a change to platforms~macos~Models can break platforms~macos~Protocols, while a change to platforms~macos~Protocols can't break platforms~macos~Models.
Position
Below the diagonal: platforms~macos~Protocols uses a module listed above it, which is the healthy direction.
PortKiller uses PortKiller.ViewModels, so a change to PortKiller.ViewModels can break PortKiller, while a change to PortKiller can't break PortKiller.ViewModels.
Position
Below the diagonal: PortKiller uses a module listed above it, which is the healthy direction.
platforms~macos~Services uses platforms~macos~Extensions, so a change to platforms~macos~Extensions can break platforms~macos~Services, while a change to platforms~macos~Services can't break platforms~macos~Extensions.
Position
Below the diagonal: platforms~macos~Services uses a module listed above it, which is the healthy direction.
platforms~macos~Services uses platforms~macos~Models, so a change to platforms~macos~Models can break platforms~macos~Services, while a change to platforms~macos~Services can't break platforms~macos~Models.
Position
Below the diagonal: platforms~macos~Services uses a module listed above it, which is the healthy direction.
platforms~macos~Services uses platforms~macos~Protocols, so a change to platforms~macos~Protocols can break platforms~macos~Services, while a change to platforms~macos~Services can't break platforms~macos~Protocols.
Position
Below the diagonal: platforms~macos~Services uses a module listed above it, which is the healthy direction.
platforms~macos~State uses platforms~macos~Extensions, so a change to platforms~macos~Extensions can break platforms~macos~State, while a change to platforms~macos~State can't break platforms~macos~Extensions.
Position
Below the diagonal: platforms~macos~State uses a module listed above it, which is the healthy direction.
platforms~macos~State uses platforms~macos~Models, so a change to platforms~macos~Models can break platforms~macos~State, while a change to platforms~macos~State can't break platforms~macos~Models.
Position
Below the diagonal: platforms~macos~State uses a module listed above it, which is the healthy direction.
platforms~macos~State uses platforms~macos~Protocols, so a change to platforms~macos~Protocols can break platforms~macos~State, while a change to platforms~macos~State can't break platforms~macos~Protocols.
Position
Below the diagonal: platforms~macos~State uses a module listed above it, which is the healthy direction.
platforms~macos~Managers uses platforms~macos~Extensions, so a change to platforms~macos~Extensions can break platforms~macos~Managers, while a change to platforms~macos~Managers can't break platforms~macos~Extensions.
Position
Below the diagonal: platforms~macos~Managers uses a module listed above it, which is the healthy direction.
platforms~macos~Managers uses platforms~macos~Models, so a change to platforms~macos~Models can break platforms~macos~Managers, while a change to platforms~macos~Managers can't break platforms~macos~Models.
Position
Below the diagonal: platforms~macos~Managers uses a module listed above it, which is the healthy direction.
platforms~macos~Managers uses platforms~macos~Protocols, so a change to platforms~macos~Protocols can break platforms~macos~Managers, while a change to platforms~macos~Managers can't break platforms~macos~Protocols.
Position
Below the diagonal: platforms~macos~Managers uses a module listed above it, which is the healthy direction.
platforms~macos~Managers uses platforms~macos~Services, so a change to platforms~macos~Services can break platforms~macos~Managers, while a change to platforms~macos~Managers can't break platforms~macos~Services.
Position
Below the diagonal: platforms~macos~Managers uses a module listed above it, which is the healthy direction.
platforms~macos uses platforms~macos~Extensions, so a change to platforms~macos~Extensions can break platforms~macos, while a change to platforms~macos can't break platforms~macos~Extensions.
Position
Below the diagonal: platforms~macos uses a module listed above it, which is the healthy direction.
platforms~macos uses platforms~macos~Models, so a change to platforms~macos~Models can break platforms~macos, while a change to platforms~macos can't break platforms~macos~Models.
Position
Below the diagonal: platforms~macos uses a module listed above it, which is the healthy direction.
platforms~macos uses platforms~macos~Protocols, so a change to platforms~macos~Protocols can break platforms~macos, while a change to platforms~macos can't break platforms~macos~Protocols.
Position
Below the diagonal: platforms~macos uses a module listed above it, which is the healthy direction.
platforms~macos uses platforms~macos~State, so a change to platforms~macos~State can break platforms~macos, while a change to platforms~macos can't break platforms~macos~State.
Position
Below the diagonal: platforms~macos uses a module listed above it, which is the healthy direction.
platforms~macos uses platforms~macos~Managers, so a change to platforms~macos~Managers can break platforms~macos, while a change to platforms~macos can't break platforms~macos~Managers.
Position
Below the diagonal: platforms~macos uses a module listed above it, which is the healthy direction.
114 pairs of types, where a type in platforms~macos~Views uses a type in platforms~macos~DesignSystem. Showing 25 of them; the rest are in namespace-graph.json in this report's bundle.
platforms~macos~Views uses platforms~macos~DesignSystem, so a change to platforms~macos~DesignSystem can break platforms~macos~Views, while a change to platforms~macos~Views can't break platforms~macos~DesignSystem.
Position
Below the diagonal: platforms~macos~Views uses a module listed above it, which is the healthy direction.
48 pairs of types, where a type in platforms~macos~Views uses a type in platforms~macos~Extensions. Showing 25 of them; the rest are in namespace-graph.json in this report's bundle.
platforms~macos~Views uses platforms~macos~Extensions, so a change to platforms~macos~Extensions can break platforms~macos~Views, while a change to platforms~macos~Views can't break platforms~macos~Extensions.
Position
Below the diagonal: platforms~macos~Views uses a module listed above it, which is the healthy direction.
74 pairs of types, where a type in platforms~macos~Views uses a type in platforms~macos~Models. Showing 25 of them; the rest are in namespace-graph.json in this report's bundle.
platforms~macos~Views uses platforms~macos~Models, so a change to platforms~macos~Models can break platforms~macos~Views, while a change to platforms~macos~Views can't break platforms~macos~Models.
Position
Below the diagonal: platforms~macos~Views uses a module listed above it, which is the healthy direction.
platforms~macos~Views uses platforms~macos~Services, so a change to platforms~macos~Services can break platforms~macos~Views, while a change to platforms~macos~Views can't break platforms~macos~Services.
Position
Below the diagonal: platforms~macos~Views uses a module listed above it, which is the healthy direction.
platforms~macos~Views uses platforms~macos~Managers, so a change to platforms~macos~Managers can break platforms~macos~Views, while a change to platforms~macos~Views can't break platforms~macos~Managers.
Position
Below the diagonal: platforms~macos~Views uses a module listed above it, which is the healthy direction.
platforms~macos~Views uses platforms~macos, so a change to platforms~macos can break platforms~macos~Views, while a change to platforms~macos~Views can't break platforms~macos.
Position
Below the diagonal: platforms~macos~Views uses a module listed above it, which is the healthy direction.
Findings mapped to OWASP categories; the specific CVEs/secrets are in the Security dimension cards below and findings.md (redacted only on the public version of this report).
OWASP category
Findings
Severity
A05:2025 — Injection
35
High / Critical
A03:2025 — Software Supply Chain Failures
14
High / Critical
Roadmap
Top priorities: Swift: await instead of blocking — `try await Task.sleep(for:)` for Thread.sleep/sleep, a checked continuation instead of a DispatchSemaphore or DispatchGroup wait, the async Process and URLSession APIs; never park a thread waiting on a Task — the cooperative pool cannot guarantee it progress; Enable Dependabot/Renovate or a dependency-review gate; Nothing pauses a release for a human: publish as a draft release (or gate the release job on a protected tag/manual dispatch) so a bad build can be stopped before users can download it.
Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.
Do this
Helps
Effort
Dimension
Swift: await instead of blocking — `try await Task.sleep(for:)` for Thread.sleep/sleep, a checked continuation instead of a DispatchSemaphore or DispatchGroup wait, the async Process and URLSession APIs; never park a thread waiting on a Task — the cooperative pool cannot guarantee it progress.
Nothing pauses a release for a human: publish as a draft release (or gate the release job on a protected tag/manual dispatch) so a bad build can be stopped before users can download it.
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 — 47
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 — 157
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 — 28
Recorded, with no effect on how the codebase functions.
Present so the survey is complete, not because it needs doing.
Could not be resolved — 17
Something this survey could not settle
from the outside, and which could be critical or serious. Either a control was required and no
positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves
nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean
result. These are excluded from the score rather than awarded a pass, so the number on the cover neither
rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each
one is named under Limitations.
Methodology & how to trust this report
This survey is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. All 43 evaluated dimensions are computed by tools and static analysis; no language model sets or judges any of them. Overall confidence is 0.9, the weighted average across measured dimensions.
Every figure here is one of two kinds, and we label which: ✓ Measured — a deterministic fact (LoC, complexity, coverage); ~ Modeled — an estimate from a stated model (cost, effort, value-at-risk), always a range with its assumptions, never a precise fact. We never present a modelled estimate as if it were measured. Perfect or absent scores carry their provenance too (ADR-0011): ✓ Tool-verified means the property itself was measured across the surface; ○ Nothing flagged means the probes came back clean — a claim bounded by what a repository can show; ⊘ Not evidenced means a working control (a tested restore, an automated rollback) showed no positive evidence — absence of evidence is not evidence of a control, so it's excluded from the score rather than awarded a spurious 10.
What we checked — 43 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, 221 of 232 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line. (Every path in this report is repo-relative by construction: paths are normalized at the producer and the report is rejected if any rooted path leaks through.)
Is there a tool behind the number? Every score below names the method that produced it: Roslyn, git or a scanner, not a narrative.
Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.
This report answers yes to all three. That's the bar to hold any assessment to.
Tools & methods
The actual versions used this run (captured at analysis time) — re-run on the same commit for the identical score.
Method
Backs
Version
Evaluator
Roslyn static analysis
Complexity, cohesion, coupling, dead code, API surface, layering
What ran differently this time — a tool absent, degraded, or that fell back to an estimate. Named openly, not folded silently into the scores. A degraded run also records its exact cause in diagnostics.md.
D8 Code Coverage — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Coverage NOT MEASURED: test source is present (.swift, .py, .rs) but the built-in coverage collector has no runner for this repository's ecosystem — so this suite was never executed by it. Not scored — this is a gap in the analyzer's language coverage, not a defect in the repo.
D10 Test Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. The 97 test(s) behind this row are the ones the code-model census could read, and this repository also carries at least 2 test source file(s) (.py, .rs) that it cannot: it reads the test types the .swift frontend declared, so a suite in any other language 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 — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Test source is present (.swift, .py, .rs) and this repository declares a SwiftPM test suite (PortKiller), but it was not re-run: the analyzer environment could not run it. Not scored — this is a gap in the analyzer's language coverage, not a finding about this repository.
D12 Dependency Hygiene — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. `dotnet list package` did not return usable output (restore or query failed); no outdated/vulnerable/deprecated data to assess. The tool said: `dotnet list package` exited 1 with no output.
D14 License Compliance — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This repository declares package.json, but the licence verdict published here was taken over its NuGet package dependencies. Nothing was read about its npm dependencies' licensing in either direction, and a clean score on this card must not be read as covering them.
D14 License Compliance — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This repository declares a Cargo manifest, but the licence verdict published here was taken over its NuGet package dependencies. Nothing was read about its Cargo dependencies' licensing in either direction, and a clean score on this card must not be read as covering them.
D16 Bus Factor — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. Single-maintainer repository — bus factor is not applicable (17 contributor(s) across 239 commit(s) sampled, automation and bot accounts excluded). One of them holds 88% of the history; the other 16 hold 0.8% each on average, below the 5% at which there is somebody to hand the work to. That is a single maintainer with drive-by contributors, not a team whose knowledge has concentrated — so the bus factor is not applicable and there is nothing here for the owner to act on.
D17 Explicit Debt — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. The 11 deducted marker(s) and the 2.7/KLoC density on this row were taken over this repository's .NET projects ALONE: .swift (14,962 lines, 70% 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.
D19 Documentation Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Each ecosystem's manifests (what makes a folder runnable or a published package) need their own proof before D19 judges its units. Until then those folders' READMEs are judged only as documents (boilerplate, structure), never counted as complete.
D19 Documentation Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This kind did not reach the 95 % precision gate in three adjudicated runs (docs/plans/deterministic-engine/adjudication/D19-sample3-v3.md), so by the pre-registered fallback it publishes no row until a re-measurement shows it does. The candidates are counted here, not reported as findings, and the score does not include them.
D22 Internal API Consistency — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. D22's deterministic call-shape rules are gated on C# first (docs/plans/deterministic-engine.md, P5): each other language is switched on only after its own concept suite and A/B gate pass. This says nothing about whether that surface is consistent.
D24 Comment Value — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Each source language's comment syntax, and the code a comment annotates in it, needs its own proof before D24 judges it. Until then those comments are left unread, not counted as clean.
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) — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. `platforms/macos/Sources/Managers/NamedTunnelManager.swift`, `platforms/macos/Sources/Services/PortForwardOutputParser.swift`, `platforms/macos/Sources/Views/Settings/ShortcutsSection.swift` 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.
AXB1 Runtime evidence locked — no reproducible boot — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Subject: a native UI project (platforms/windows/PortKiller/App.xaml). The Runtime Evidence tier boots an app only via docker-compose, an Aspire AppHost, a Dockerfile, an npm dev script, a web service's own toolchain entry point (cargo, go, dotnet, Python, Spring Boot), or an Android app's own Gradle wrapper (run on an emulator); an Apple or Flutter app needs a host it lacks. None applied, so no live runtime a11y/egress/header evidence was collected. You can widen what we reach: add a docker-compose.yml (or an Aspire AppHost) that brings the app up with its dependencies. We then boot it in an isolated sandbox and gathers real runtime evidence — you change nothing in your pipeline (no CI step, no SDK).
IC1 Incompleteness & stubs — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
M4 Documentation accuracy — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. M4 checks only the claim kinds adjudicated at or above 95 % precision: links and versions (PREREGISTRATION version 9), and artefact counts an order of magnitude off. Paths, command arguments, installs, environment variables, settings, projects, packages, routes, cd targets, infrastructure products and removed modules are read but not checked, and none of them is reported or counted.
P5 DR & Backup — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. No backup/snapshot/replication config, RTO/RPO or restore-procedure documentation was found — and no production persistence was detected either (no data-access packages, no data-store services, no database resources), so there is nothing in this repository whose loss a DR control would recover. If this system's data lives in a platform or ops repo we can't see, that's where the DR evidence belongs.
X1 Async correctness — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X12 Unreachable branch — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X13 Undrained process stream — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X16 Unfloored truncation loop — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X18 Disposal-pattern correctness — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X2 Cancellation propagation — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X21 Side-effecting pattern guard — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X27 Collection changed while being enumerated — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X29 Per-element action decided by a fixed element — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
X3 Exception handling — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check's reader does not cover most of the languages this repository's product is written in. What it read is kept, but it is too small a share to grade the product by. That is a gap in this analyzer's language reach — not a finding about this repository.
Repo exclusion declarations (.gitattributes linguist-generated/vendored, .editorconfig generated_code): none declared — every source file was scored.
Limitations & what we did not check
We assess the repository exactly as committed, and only the repository. By design we do not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.
Per-dimension blind spots
For each dimension that was measured, what a static, repo-only scan structurally cannot see — the honest edge of the measurement, not a failure of it.
D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
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 Secret Scanning: Secret detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
D14 License Compliance: License compatibility is checked against declared package metadata and a policy — mislabelled or missing license metadata, and obligations that depend on how you distribute, are not resolved here.
D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
D19 Documentation Quality: Documentation quality publishes two things only: a runnable or packaged unit with no example, and a multi-project root README that maps none of its parts. It does not judge clarity, and its other checks (overview, licence, boilerplate, structure, empty sections, XML-doc coverage) are withheld after adjudication: their candidates are counted in the card's gaps, not shown as rows. A false statement in a document is M4's; units are .NET projects only.
D20 ADR Quality: ADR quality checks the structure of the decision records present: it cannot know about decisions made and never recorded, and it does not judge how well a record argues its case. Records in a language the section lexicon does not cover are not evaluated.
D24 Comment Value: Comment value is measured as redundancy only: a comment that repeats its code's words is found, but a paraphrase in other words, a vague comment, or one the code contradicts is not, and whether a comment is valuable is not claimed. Comments in other scripts or languages, and outside C#, are not judged.
D27 Navigability: Indirection/navigability is structural — it measures hops to follow a call, not whether that indirection buys real flexibility or just ceremony.
D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
D43 Malicious Dependencies: Only packages some vulnerability database has already NAMED as malicious are seen — a compromise published in the last hours, or never reported at all, is invisible here, and this dimension reading 10 is not evidence that a dependency is trustworthy. There is no typosquat or dependency-confusion analysis: a package nobody has reported is simply absent from the feeds. Coverage is the dependency scan's: an ecosystem that could not be scanned is disclosed as unmeasured, never as clean.
D44 Platform End-of-Life: The support table is FROZEN, so it goes out of date by losing RECALL: a release that ended support after the table was written is missed until the table is refreshed, and this dimension reading 10 is not evidence that a platform is current. Only platforms the repository DECLARES in a place this pass reads are seen — a runtime named only in a Dockerfile (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (go.mod, a Gemfile ruby directive) is invisible here, which is why a repository declaring none of them abstains rather than scoring. Only frameworks with a PUBLISHED support policy are tracked: React, Flask and Express publish none, so their age cannot be judged and their absence from a report is not a statement that they are supported.
AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
AX9 CQS / query purity: Handlers are found by interface/name convention — a query handler using neither is not seen. Mutation is a resolved write/publish invocation (SaveChanges/repository/bus), so a write hidden behind a hand-rolled wrapper, reflection, or a string-keyed service locator resolves to a non-persistence type and isn't flagged; it detects that a query writes state, not whether the write is a legitimate read-side cache update. Clean means "no resolved write/publish in a query body", not a proof of CQS purity.
M4 Documentation accuracy: Documentation accuracy checks links, versions and artefact counts against the tree: other claims (paths, commands, settings, routes) are read but not checked, and it cannot run the onboarding or measure how long a real new joiner takes.
P4 Deployment & Rollback: Approval/branch-protection rules live in repository settings the scan cannot see — only their in-repo evidence (config files, workflows) is checked, so a control enforced purely in the host's settings reads as "not evidenced".
P6 Release Hygiene: Rollback/observability controls are inferred from repo artefacts (pipelines, dashboards-as-code) — controls configured in external tooling, with no in-repo trace, cannot be credited.
What it measures: How tangled the control flow is — methods with many branches are hard to test and change.
Method: Cyclomatic complexity per method (1 + decision points), computed exhaustively across production source; test projects separated by convention. Deterministic.
+ 1 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Bring the 6 bodies over 15 down to 15 or less in Cyclomatic Complexity — start with MenuBarWindow.render_list (cyclomatic 27), PortForwardManager.checkConnections (cyclomatic 24), PortFilter.matches (cyclomatic 19). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 6 together lifts Cyclomatic Complexity from 8.9 to about 10.0/10, projected with the scoring formula itself and assuming each lands exactly at 15.
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.
+ 17 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Bring the 25 bodies over 15 down to 15 or less in Cognitive Complexity — start with MenuBarWindow.render_list (cognitive 44), PortForwardManager.checkConnections (cognitive 43), LinuxScanner::parse_ss_output (cognitive 35). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 25 together lifts Cognitive Complexity from 6.8 to about 10.0/10, projected with the scoring formula itself and assuming each lands exactly at 15.
Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D3 · God Classes9.4 / 10Stronggated by 3 serious findings✓ Tool-verified
What it measures: Over-large classes that try to do too much ("god classes").
Method: God-class detection by line and method-count thresholds per logical type (partial classes unified), filtered for generated code and registration/contract false positives. Deterministic.
Resolve the 2 MethodTooLong finding(s) in God Classes — start with SettingsView.swift, ConnectionInfoSection.swift. — One of this dimension's main actionable groups (2 warning-level).
Resolve the 1 TooManyMethods finding(s) in God Classes — start with MainWindow.xaml.cs. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: How much of the production code is copy-pasted: the share of production lines inside a reported copy (every copy of a duplicated block or of an edited member, each line once), 10 at none and 0 at a quarter of the lines.
Method: Code duplication via token-stream sliding windows with type-aware normalization (locals masked, type names preserved), scored on the share of production lines inside a reported copy (each line once; 10 at none, 0 at a quarter). Deterministic.
50 duplicated block group(s) detected. 9.5 % of the production lines (2,012 of 21,235) are in a reported copy. A further 30 rows report members as variants of one another; the share counts each copied line once, however many rows cite it.
Edited copy of a member (9 corresponding lines) · ×3platforms/windows/PortKiller/MainWindow.xaml.cs:404
Edited copy of a member (14 corresponding lines) · ×3platforms/macos/Sources/Managers/PortForwardProcessManager+Kubernetes.swift:22
Edited copy of a member (17 corresponding lines) · ×3platforms/macos/Sources/Views/CloudflareTunnels/NamedTunnelDetailView.swift:276
+ 48 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 6 Duplicated block (9 lines × 2) finding(s) in Code Duplication — start with PortGroupingService.swift (2), PortForwarderToolbar.swift, CloudflaredSettingsSection.swift. — One of this dimension's main actionable groups (6 warning-level).
Resolve the 4 Duplicated block (10 lines × 2) finding(s) in Code Duplication — start with ConnectionEditSection.swift (2), PortScanner.swift, PermissionService.swift. — One of this dimension's main actionable groups (4 warning-level).
Resolve the 3 Edited copy of a member (9 corresponding lines) finding(s) in Code Duplication — start with CloudflareTunnelsView.xaml.cs (2), MainWindow.xaml.cs. — One of this dimension's main actionable groups (3 warning-level).
Detailed fixes: d4_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D5 · Coupling10.0 / 10Exemplary✓ Tool-verified
What it measures: Whether volatile projects sit underneath others that depend on them (so their churn ripples upward), and whether project dependencies form cycles. A widely-depended-on but stable shared/kernel project is healthy, not penalised.
Method: Dependency cycles via elementary-DFS over real .csproj references, plus Martin instability (afferent/efferent) per project. Exhaustive over the reference graph, deterministic.
Coverage: Exhaustive · type-level: afferent/efferent coupling + cycles computed over every production type — the population is all types, not a name convention.
What it measures: Whether a class's methods are focused on a single responsibility.
Method: LCOM4 cohesion per production class with at least two methods: connected components of methods sharing state or calls, computed syntactically. Deterministic, not a proxy.
Coverage: Exhaustive · type-level: LCOM4 cohesion computed over every production class — the population is all types, not a name convention.
Resolve the 2 Low cohesion finding(s) in Cohesion (LCOM4) — start with PortKillerApp.swift, PortForwardProcessManager.swift. — One of this dimension's main actionable groups (2 warning-level).
Detailed fixes: d6_recommendation.md · top locations in Appendix A, every location in findings.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.
0 skipped, 0 zero-assertion, no mocking-framework packages referenced (hand-written doubles or no mocking) across 97 tests. Measured on the .swift suite only — at least 2 test source file(s) (.py, .rs) 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 88 packages use a banned license. ★ DEPTH: this repository's MSBuild projects declare 5 direct `PackageReference`(s), and 83 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. ★ COVERAGE OF THIS VERDICT: it grades this repository's NuGet package dependencies and nothing else. The repository also declares package.json and a Cargo manifest, and the licences of those dependency graphs were NOT read by this pass — a gap in this engine's coverage, not a statement about them. So this result says the graded closure carries no banned licence; it does NOT say this repository's licensing is clear.
What it measures: Files that change often and are also complex — the riskiest hotspots.
Method: Per production file churn times cyclomatic complexity over a rolling window, computed from git and Roslyn/JS/Razor analysis. Exhaustive, deterministic per commit date.
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.
11 deducted debt markers + 16 dead symbols across 3562 LoC in the .NET projects (2.7/KLoC) → score 4.6. Measured on the .NET source only: .swift (70% of production source) was not read, and carries at least 0 uncounted task marker(s) in 0 file(s).
Dead code: EnableGlassBlur · ×16platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:115
What to do
Resolve the 16 Dead code finding(s) in Explicit Debt — start with ProcessKillerService.cs (3), SettingsService.cs (3), WindowBlurHelper.cs (2). — One of this dimension's main actionable groups (16 warning-level).
Resolve the 11 EmptyCatchBlock finding(s) in Explicit Debt — start with NotificationService.cs (3), SettingsService.cs (3), TunnelService.cs (3). — One of this dimension's main actionable groups (11 issue-level).
Detailed fixes: d17_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether the project's documentation is clear, complete, and useful.
Method: Every README, docs/ document and root guide parsed by its markup and measured in Unicode letters. Published: a runnable or packaged .NET project whose README (or a document it links, or a root guide) shows no example, and a root README naming none of three or more projects. Overview, licence, boilerplate, wall-of-text, empty-section and XML-doc rows are measured and withheld (counted in gaps) after adjudication. Deterministic, exhaustive, advisory.
1 of 1 documentation facets pass in full. 3 document(s) read across 2 unit(s).
✓ On the Gold path — maintain.
Detailed fixes: d19_recommendation.md.
Do you agree with this assessment?
D20 · ADR Quality0.0 / 10Critical✓ Tool-verified
What it measures: Whether architecture decisions are recorded well (context, decision, consequences).
Method: Every ADR read by its section structure: nine located rules (a missing Decision, Context or Consequences section, a stale status, two records deciding the same question, a dangling supersede link, a number-only title, a single option, no named cost, no status where the log uses one, no enforcement field where the log adopted one), each a fixed deduction from 10; the score is the mean over evaluated records. Deterministic, no model. Advisory.
No ADRs foundplatforms/windows/PortKiller/PortKiller.csproj:3
What to do
Resolve the 1 No ADRs found finding(s) in ADR Quality — start with PortKiller.csproj. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d20_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether comments are worth it — explaining WHY (valuable) rather than WHAT (redundant).
Method: Every inline C# comment compared word by word with the identifiers, literals and constructs of the code it annotates (taken from the syntax); a comment whose words that code already contains is redundant, as are closing-brace labels and generator template text. Comments giving a reason or a reference are kept; other scripts and languages are not judged. Deterministic, exhaustive, advisory.
doc comments repeat the namesplatforms/windows/PortKiller/Services/TunnelService.cs:143
What to do
Resolve the 8 redundant comment finding(s) in Comment Value — start with MainWindow.xaml.cs (3), MiniPortKillerWindow.xaml.cs (3), MainViewModel.cs. — One of this dimension's main actionable groups (8 recommendation-level).
Detailed fixes: d24_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: How far you must trace to follow a call — low indirection and co-located slices read easier.
Method: Call indirection (interface hops, cross-namespace calls, slice-locality scaled) over a sampled set of method invocations, size-aware baseline. Sampled; confidence discounted by symbol-resolution gaps. C# also names each pass-through layer (a class whose every public method only forwards its own parameters to one collaborator) as a located finding; the score is not affected.
Coverage: Slice locality from the first namespace segments, SAMPLED (≤400 methods) — not exhaustive.
29 % of calls cross a namespace and 4 % go through an interface, but 100 % of collaborators are co-located — so a call's collaborators sit together and tracing stays easy. Baseline: small — navigation cost is tolerated.
What it measures: Whether any secrets were ever committed — scanned across the full git history, not just now.
Method: Secret scan via TWO gitleaks detect passes in an isolated checkout — the full git history, then a second --no-git pass over the working tree as it stands — merged and de-duplicated by (rule, file, line); each match flagged High. Both invocations are recorded in the audit trail. Exhaustive; when the tool is absent, or when its output cannot be parsed into the expected shape, the dimension is WITHHELD as an explicit measurement gap on our side — unscored and excluded from the lens, never a hedged middling score.
What it measures: Real static-analysis (SAST) findings — likely security bugs in the code, any language.
Method: Polyglot static analysis via semgrep across the repo using the pinned, image-baked p/security-audit + p/owasp-top-ten rulesets (no scan-time registry fetch); severity rules (ERROR/WARNING/INFO) map to a full-band severity-weighted score. Exhaustive, deterministic; degrades on parse failure.
Coverage: semgrep pattern rules over all files — exhaustive for the rule set, blind to classes of bug without a rule (clean = no rule matched).
35 finding(s): 0 critical, 32 high, 3 medium, 0 low. 28 unpinned-GitHub-Actions row(s) are reported here but scored by D36 (supply-chain provenance), which measures that posture as `pinned_actions` — one pinning decision is charged once, not once per lens. Separately, one or more rules could not re-parse an embedded snippet in 2 file(s) (e.g. a workflow `run:` block read as shell). Those files WERE scanned and their other rows are unaffected; only those rules' view of those snippets is missing.
REDACTED
REDACTED
REDACTED
REDACTED
REDACTED
+ 1 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
No action in Static Analysis (SAST) — all 28 REDACTED finding(s) are reported here at file:line but scored by D36 (supply-chain provenance), so none is charged to this dimension. — One of this dimension's main actionable groups (28 issue-level, 0 of them charged here).
Detailed fixes: d29_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether any dependency has a known published vulnerability (CVE), direct or transitive, in ANY ecosystem the repository declares — Dart pub, Elixir and Erlang via Hex, Go modules, Java and Kotlin via Maven/Gradle, JavaScript/npm, .NET/NuGet, PHP/Composer, Python/PyPI, RubyGems, Rust/Cargo and Swift.
Method: Dependency-CVE scan across every ecosystem the repository declares, scored ONCE. Three sources are unioned and deduplicated by advisory identity (rule id + alias closure, CVE<->GHSA) scoped to package+version, keeping the worst severity: `osv-scanner --recursive` over osv.dev for Dart pub, Elixir/Hex (and Erlang, whose `rebar.lock` syft first converts to a CycloneDX SBOM the scanner reads, with rows attributed back to the lock), Go, Java and Kotlin via Maven/Gradle (and Scala, whose sbt build's pinned direct declarations are written into a CycloneDX SBOM the scanner reads, with rows attributed back to the build file), npm, PHP/Composer, Python/PyPI, RubyGems, Rust/Cargo and Swift; `trivy fs --scanners vuln` for npm lockfiles; and `dotnet list package --vulnerable --include-transitive` for NuGet (with per-advisory collapse of the project x target-framework fan-out), plus a DECLARED-dependency arm that resolves a published gem's gemspec against rubygems.org where no Gemfile.lock is committed. `SeverityScore(c,h,m,l, normalizer 8.0)`. NotApplicable only when NO ecosystem is readable; if any applicable ecosystem could not be scanned the findings are REPORTED and the score is withheld. Supersedes the npm and OSV arms, retired 2026-09-05. Advisory since rubric-2026.11.2 (CAI decision 0006): every row is a match against a vulnerability database that changes daily, so the reading is shown and never moves a scored dimension, lens or the headline.
6 finding(s): 0 critical, 4 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 4 High CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (4). — One of this dimension's main actionable groups (4 issue-level).
Resolve the 2 Medium 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.
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 15 of the 20 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 build pipeline provides supply-chain integrity — generated provenance/attestation, signed artifacts (cosign/sigstore), an SBOM, and pinned build actions. Presence of the configuration, not a runtime guarantee.
Method: Supply-chain provenance/signing read deterministically from CI/build config (.github/workflows, .gitlab-ci.yml, azure-pipelines, Jenkinsfile, .circleci) + the release surface: four signals — generated provenance/attestation (SLSA/in-toto/actions-attest), artifact signing (cosign/sigstore/gitsign), an SBOM (syft/sbom-action/*.spdx.json/*.cdx.json), and SHA-pinned build actions — scored 10·present/denom. NotApplicable without a build pipeline. Detects configuration presence, not runtime enforcement.
+ 2 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 2 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED, REDACTED. — One of this dimension's main actionable groups (2 warning-level).
Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 REDACTED finding(s) in Supply-chain Provenance & Signing — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d36_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether any dependency the repository declares is published as MALICIOUS rather than merely vulnerable — a package that is an attacker's work, in any ecosystem osv-scanner reads. Reported apart from D30 because the answer is binary: there is no safe version to upgrade to, and the fix is to remove the package and rotate every credential it could have read.
Method: The same dependency scan D30 reads, partitioned on the scanner's own classification rather than rescanned: a row is MALICIOUS when its id is in the `MAL-` space (the ossf/malicious-packages feed) OR its `database_specific.cwe_ids` carries `CWE-506` ("Embedded Malicious Code"). Both channels are structural; the summary text is deliberately NOT read, because a malicious-package record whose summary says only "Critical severity vulnerability" is a real shape ([GHSA redacted]) and a text matcher misses it. Scored BINARY: any surviving row is 0, whatever its severity and however many CVEs sit beside it — a hostile dependency is not a quantity. Applicability and degradation are D30's: NotApplicable only when no ecosystem is readable, and an unscannable ecosystem degrades rather than reading clean. Advisory since rubric-2026.11.2 (CAI decision 0006): the malicious-package feed is a database that changes daily, so the reading is shown and never moves a scored dimension, lens or the headline.
What it measures: Whether anyone still ships security patches for the platform this repository RUNS ON — the runtime it pins and the framework majors its own constraints hold it to. Separate from D12 because the question differs: a current Django on an end-of-life Python is perfectly up to date and completely unsupported, and the fix is a migration rather than a version bump. What the repository says it merely SUPPORTS is never charged.
Method: End-of-life PLATFORM read from the repository's own declarations and graded against a FROZEN, dated table of vendor support dates — no network, no feed, no API, so this dimension answers identically inside a closed scan fence. Two subjects: a RUNTIME the project pins (a single or all-end-of-life TargetFramework, a .nvmrc or .python-version, a requires-python CAP) and a FRAMEWORK major a dependency constraint cannot move off (a caret, tilde or exact version; `vue@^2.7.16` pins Vue 2). A FLOOR is deliberately never charged — `requires-python = ">=3.8"` states what a package SUPPORTS, not what it runs on — and a multi-target project is charged only when EVERY target is out of support. Runtime 4.0/product capped 8.0, framework 1.5 capped 4.5. The table is safe to freeze because a statement about support that ended in the past cannot become false: it loses recall as it ages, never precision, and a test asserts every entry predates the freeze date. Disjoint from D31 (a container image's OS layer) and D29 (the toolchain a CI workflow installs). Abstains when the repository declares no platform this pass reads — never scores it clean.
0 end-of-life runtime(s) and 0 end-of-life framework(s), read from 1 platform declaration(s) and 1 dependency declaration(s). This dimension reads what the repository says about ITSELF — a pinned target framework, a version file, a capped requires-python, a Rust toolchain pin, a framework major a constraint cannot move off. A FLOOR is deliberately never charged: `requires-python = ">=3.8"` states what the package SUPPORTS, not what it runs on, and a well-maintained library declares exactly that while running its own CI on a current release. The end-of-life facts are FROZEN and dated, so this dimension needs no network and answers identically inside a closed scan fence; as the table ages it loses recall and never precision, because a statement about support that ended in the past cannot become false. The OS layer of a container image is D31's question and the toolchain a CI workflow installs is D29's; this row is neither.
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.
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.
`NotificationService` is a singleton (one shared instance) but mutates instance state outside any lock (_isInitialized; e.g. `_isInitialized` at line 25). — platforms/windows/PortKiller/Services/NotificationService.cs:9
`TunnelService` is a singleton (one shared instance) but mutates instance state outside any lock (_processes, _urlHandlers, _errorHandlers; e.g. `_processes` at line 122). — platforms/windows/PortKiller/Services/TunnelService.cs:11
`MainViewModel` is a singleton (one shared instance) but mutates instance state outside any lock (IsScanning, _refreshCancellation, _previousPortStates; e.g. `IsScanning` at line 120). — platforms/windows/PortKiller/ViewModels/MainViewModel.cs:20
`TunnelViewModel` is a singleton (one shared instance) but mutates instance state outside any lock (_isCloudflaredInstalled, _cloudflaredProtocol; e.g. `_isCloudflaredInstalled` at line 30). — platforms/windows/PortKiller/ViewModels/TunnelViewModel.cs:15
`PortFilter` is not registered, but the singleton `MainViewModel` creates it and keeps it in `_filter`, so one instance outlives every request and is shared by every caller that reaches it — and it mutates instance state outside any lock (SearchText, MinPort, MaxPort, ProcessTypes, ShowOnlyFavorites, ShowOnlyWatched; e.g. `SearchText` at line 60). — platforms/windows/PortKiller/Models/PortFilter.cs:10
`CloudflareTunnel` is not registered, but the singleton `TunnelViewModel` creates it and keeps it in `Tunnels`, so one instance outlives every request and is shared by every caller that reaches it — and it mutates instance state outside any lock (_id, _port, _status, _tunnelUrl, _lastError, _startTime; e.g. `_id` at line 35). — platforms/windows/PortKiller/Models/CloudflareTunnel.cs:22
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 read (query) handlers stay side-effect-free — a query that writes persistent state or raises events breaks CQS and makes reads unsafe to retry, cache, or route to a read replica.
Method: Roslyn scan: CQRS handlers classified query-vs-command by interface (IQueryHandler/ICommandHandler/IRequestHandler<TQuery,TResult>) and name convention (*Query/Get*/Find* vs *Command); each query handler's body checked for persistent-state writes (SaveChanges/repository Add-Update) or event publishes by resolved invocation. Deterministic, type-level, exhaustive over the detected handlers.
Coverage: Population: CQRS handlers identified by IQueryHandler/ICommandHandler/IRequestHandler interface + *Query/Get*/Find*/*Command NAME convention; query purity then checked exhaustively within that set — a query handler using neither convention is invisible, and mutation is a resolved persistence/publish CALL, not full dataflow.
Other · Code Health — Unreviewed-generation residue: 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.
A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface. (×4) — platforms/windows/PortKiller/Helpers/ValueConverters.cs:21, platforms/windows/PortKiller/Helpers/ValueConverters.cs:37, platforms/windows/PortKiller/Helpers/ValueConverters.cs:56, …
What to do
Finish or delete NotImplementedException stubs and replace placeholder literals before shipping.
Maturity · Maturity — Whether the repository and its projects have a README, and whether it is substantive.
Method: Filesystem scan: README presence, word count, and headings for depth; git history for staleness. Exhaustive across root and project dirs, deterministic.
Maturity · Maturity — Whether key decisions (ADRs) and the high-level shape (C4/diagrams) are written down.
Method: Filesystem scan: ADR folder/naming conventions or content, plus Mermaid/PlantUML/C4/architecture.md discovery. Exhaustive, deterministic.
No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
What to do
Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them.
Maturity · Maturity — Whether the repository is organised deliberately: production code and tests are set apart in a way its ecosystem or the repository itself declares.
Method: Filesystem scan: src/test folder separation and namespace-prefix consistency (majority RootNamespace agreement). Exhaustive across projects, deterministic.
Maturity · Maturity — Whether the project's current-state documentation describes the code that exists.
Method: Every current-state document's checkable claims looked up in the tree (links, versions, and artefact counts an order of magnitude off), plus two README checks: an advertised infrastructure product with no footprint, and a module the CHANGELOG records as removed. Deterministic, no model. Advisory.
platforms/windows/README.md names .NET 8, but the projects target .NET 9. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong. — platforms/windows/README.md:105
What to do
Reconcile the README with reality: platforms/windows/README.md names .NET 8, but the projects target .NET 9.
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 & versioning10.0 / 10Exemplary○ Nothing flagged
Readiness · Readiness — For a library: a deliberate (small) public API surface and explicit semantic versioning so consumers can depend on it safely.
Method: Roslyn scan: public API surface area and semantic-versioning markers (SemVer attributes, changelog entries) for libraries; off .NET, a library is the ecosystem's publication act (an npm package that is not private and names an entry point, a PyPI distribution with a build system, a Rust library crate, a Maven/Gradle module that publishes, a Go module with no package main, a gemspec, a Composer library, a SwiftPM library product, a pub.dev or Hex package), its surface is the share of types the language's code model records as public (Rust, Swift, Java, Kotlin, Go, Dart; not measured where the model records no type visibility or, as in TypeScript, only module-level export), and its version is read from the manifest, a semver CHANGELOG, release tooling or semver git tags. Exhaustive, deterministic.
Do you agree with this assessment?
P2 · Observability6.0 / 10Adequate✓ Tool-verified
Readiness · Readiness — Whether the code is diagnosable in production — structured logging, tracing/metrics, health checks.
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.
`platforms/windows/PortKiller/PortKiller.csproj` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`. — platforms/windows/PortKiller/PortKiller.csproj:18
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.
The release 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 the release trigger points at is published to users unreviewed, so a mistagged or unverified commit ships and the only remedy is a follow-up release.
What to do
Nothing pauses a release for a human: publish as a draft release (or gate the release job on a protected tag/manual dispatch) so a bad build can be stopped before users can download it.
Readiness · Readiness — Whether releases are traceable — a maintained changelog and explicit version stamping.
Method: Filesystem scan: changelog file presence and version tags in csproj or git tags. Exhaustive, deterministic.
No CHANGELOG/HISTORY/RELEASES file — what shipped when isn't easy to reconstruct for support or audit. (Versioning/tagging makes releases traceable, but a changelog records the what.)
What to do
Keep a changelog (e.g. Keep-a-Changelog) recording what shipped in each release.
Readiness · Performance — Whether asynchronous code stays responsive — it avoids sync-over-async blocking (a .NET .Wait()/.GetAwaiter().GetResult(), a time.sleep or blocking HTTP call inside a Python coroutine, a *Sync call inside an async JavaScript function, block_on inside a Rust async fn, runBlocking inside a Kotlin suspend function, block() inside a Reactor publisher) that stalls a thread or event loop and risks deadlock, and, where the code is a reusable library on .NET, awaits with ConfigureAwait(false) so it never captures and stalls its caller's context.
Method: Production-source scan: sync-over-async blocking counted everywhere — .Wait()/.GetAwaiter().GetResult() in .NET; off .NET, read from each language's code model, a blocking call inside an async function (Python, TS/JS, Rust, Kotlin, Swift, Dart) or inside a Java method returning a Reactor Mono/Flux or a Scala method returning a Future or effect — and, for a .NET library with ≥5 awaits, the share of awaits using ConfigureAwait(false). Deterministic, syntax/text detection.
`killAllPortForwarderProcesses` is async and calls .waitUntilExit() — a blocking call inside async code stalls the cooperative pool's thread — one per core — and every task scheduled on it for as long as it runs. — platforms/macos/Sources/Managers/PortForwardProcessManager.swift:121
`startDirectExecProxy` is async and calls .waitUntilExit() — a blocking call inside async code stalls the cooperative pool's thread — one per core — and every task scheduled on it for as long as it runs. — platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:86
`run` is async and calls .waitUntilExit() — a blocking call inside async code stalls the cooperative pool's thread — one per core — and every task scheduled on it for as long as it runs. — platforms/macos/Sources/Services/ProcessExecutor.swift:34
`runDiscardingOutput` is async and calls .waitUntilExit() — a blocking call inside async code stalls the cooperative pool's thread — one per core — and every task scheduled on it for as long as it runs. — platforms/macos/Sources/Services/ProcessExecutor.swift:86
What to do
Swift: await instead of blocking — `try await Task.sleep(for:)` for Thread.sleep/sleep, a checked continuation instead of a DispatchSemaphore or DispatchGroup wait, the async Process and URLSession APIs; never park a thread waiting on a Task — the cooperative pool cannot guarantee it progress.
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.1 `!` suppressions per 1k syntax nodes — 2 suppression(s) across the 14824 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. Many are correct: each is a claim the checker could not verify, and it is wrong only where the value can in fact be missing, so review the densest places first.
What to do
Enable <Nullable>enable</Nullable> across all projects and resolve warnings rather than suppressing with `!`.
Do you agree with this assessment?
Reference — by lens
The score is the rank-weighted fold of these lenses (worst-heaviest), each including its meta-dimensions; a lens with a Critical contributor is capped at Fair (its band reads "gated by …") and is never the strongest area however high its average.
Unscored — 3 check(s) recorded observations but carry no score
These checks ran and found something, but they do not carry a score — either by design (an advisory check reports evidence rather than grading it) or because they could not be scored here. They are excluded from the score for that reason, not because there was nothing to see.
SC1 Supply-chain hygiene — 1 observation(s) recorded · Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
X10 Duplicated predicate — 2 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
X7 Silent fallback defaults — 6 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 1 control(s) we could not find positive evidence for
These checks grade a working control, and the repository shows no evidence of one. That is deliberately not scored as a zero: a repository cannot show an ops runbook, a database TTL or an infrastructure-side audit log, so absence of evidence here is not evidence the control is missing. It is also not a statement that the check is irrelevant to this codebase — the thing it grades applies; we just could not see it. Excluded from the score either way.
P5 DR & Backup — not evidenced — repo shows no backup/RTO/RPO controls; absence of evidence is not evidence of a working control
Not included — 71 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.
AC1 Text alternatives — No web markup found — accessibility is not applicable to this repository.
AC2 Forms & labels — No web markup found — accessibility is not applicable to this repository.
AC3 Page structure — No web markup found — accessibility is not applicable to this repository.
AC4 Keyboard semantics — No web markup found — accessibility is not applicable to this repository.
AC5 ARIA correctness — No web markup found — accessibility is not applicable to this repository.
AC6 Visual & motion safety — No web markup found — accessibility is not applicable to this repository.
AX6 Interface segregation — no public interfaces
AX7 Slice cohesion — not applicable — not a vertical-slice architecture
AX8 Test isolation — no test/production split to check
AXB1 Runtime evidence locked — no reproducible boot — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
C1 Data Protection — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
C2 Access Controls — No access-control surface detected in the analyzed source — no web/app surface to authorize (no HTTP API or web-UI project) and no authorization code at all (no [Authorize]/policies, no imperative guard methods). Access control is therefore N/A here — this is a library/CLI, which is authorized by its CALLER, not by itself. If this codebase grows request handlers, the dimension reactivates and a default-deny posture is expected then.
C3 Audit Trail — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
C4 Data Retention — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
C5 Data-Subject Rights — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
D11 Test Reliability — Test reliability not included — the .swift suite was found but not re-run
D12 Dependency Hygiene — Dependency hygiene not measured
D16 Bus Factor — single-maintainer repository — bus factor is not applicable
D18 Solution Shape — D18 scores the shape of a C#/VB .NET solution, but this repository's production source is mostly .py, .rs, .swift, 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.
D21 Naming Consistency — N/A — too few peers to establish a naming convention (2896 declarations, no unit with a dominant convention).
D22 Internal API Consistency — API consistency is measured on C# only; the exposed Rust surface was not measured.
D23 Boundary Type-Coupling — single shared-core project — no cross-context coupling to assess
D25 ADR Conformance — no ADRs to check
D26 Project Cohesion — This repository is one project, `PortKiller` (3562 LoC, 29 public types across 5 namespaces), within the size bounds. Not scored: a single unit of this size gives project cohesion nothing to grade.
D31 IaC & Container Security — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.
D32 Data Compliance (PII/GDPR) — 3 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
D37 Vulnerability-disclosure Policy — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.
D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
D7 Architectural Integrity — no checkable ADRs and no dependency cycles — architectural integrity not assessed
D8 Code Coverage — Coverage not included — suite not readable by the collector
DM1 Domain Modelling — not scored — this repository shows none of the 3 signals this lens looks for
ED2 Event/command shape — not scored — deciding whether a command has more than one competing handler requires resolving the call graph, and this analysis resolves a call's owner only where the receiver's type is written down in the source. Reported as guidance rather than measured
ED2 Event/command shape — not scored — deciding whether a command has more than one competing handler requires resolving the call graph, and a call made through an inferred or generic receiver has no resolvable owner in the source. Reported as guidance rather than measured
ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
IC1 Incompleteness & stubs — IC1 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
P12 CI test-gate honesty — Reported, not scored — and nothing was matched here. The coverage check applies to any stack, and the automatic-re-run check to any GitHub-Actions workflow, but the checks for excluded tests, skipped tests and sleep-based synchronisation currently recognise only some ecosystems' test-runner idioms, so on a repository built with another stack the zeros below mean 'not checked', not 'clean'.
P7 Outbound HTTP resilience — not applicable — this isn't a service/API/worker
P8 Schema migrations — no EF Core usage detected
P9 Domain vs controller coverage — coverage not measured: this check compares the coverage of the analyzer's own test run across the domain and web layers, and that run measured none here — Test coverage (D8) says why
PF1 Benchmark discipline — Performance is assessed only for perf-relevant repos — a packaged library, one that ships benchmarks, or one already using allocation-aware APIs. This repo isn't one, so the Performance lens is not applicable and is excluded from the score.
PF2 Allocation hygiene — Not scored: this check counted allocation-aware idioms (Span, pools, stackalloc) per line, which describes what kind of code a repository is rather than whether it has an allocation problem, so it was withdrawn. Nothing here is a finding about your code.
S1 Web-Security Posture — No web surface detected in the analyzed source — no HTTP API or web-UI project (no controllers/minimal-API endpoints, no Razor/Blazor views) and no web middleware (HTTPS redirection, HSTS, security headers, cookies). Transport security, security headers, secure cookies, CSRF/input-validation and middleware-order controls are therefore N/A here — this is a library/CLI/worker, not a web app. Crypto hygiene was still checked and found nothing to flag. If this codebase becomes web-facing, the dimension reactivates automatically.
X1 Async correctness — X1 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X12 Unreachable branch — X12 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X13 Undrained process stream — X13 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X14 Bypassable address classification — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X15 Unvalidated length from an untrusted reader — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X16 Unfloored truncation loop — X16 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X17 Uncapped recursion over a caller-supplied document — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X18 Disposal-pattern correctness — X18 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X19 Unrestored process-global state — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X2 Cancellation propagation — X2 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X20 Mistyped argument guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X21 Side-effecting pattern guard — X21 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X22 Contradicted release guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X23 Unguarded diagnostic materialisation — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X24 Document value interpolated into markup unescaped — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X25 Inert configuration knob — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X26 Unsynchronised callback handoff — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X27 Collection changed while being enumerated — X27 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X28 Index access outside its own emptiness guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X29 Per-element action decided by a fixed element — X29 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X3 Exception handling — X3 reached only 17% of this repository's production lines — swift (14,962 lines), python (1,436 lines), rust (1,275 lines) was left unread. Not scored: a score over a minority of the product would be published as the whole of it.
X30 Support guard that admits what it rejects — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X32 Type resolved by simple name across every loaded assembly — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
X4 Structured logging — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
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.
EmptyCatchBlock platforms/windows/PortKiller/Services/NotificationService.cs:42— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/NotificationService.cs:60— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/NotificationService.cs:78— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/PortScannerService.cs:374— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/PortScannerService.cs:402— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/SettingsService.cs:50— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/SettingsService.cs:64— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/SettingsService.cs:164— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/TunnelService.cs:71— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/TunnelService.cs:272— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
EmptyCatchBlock platforms/windows/PortKiller/Services/TunnelService.cs:304— empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
Dead code: EnableGlassBlur platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:115— Method EnableGlassBlur — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: DisableBlur platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:124— Method DisableBlur — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: ToDisplayName platforms/windows/PortKiller/Models/CloudflaredProtocol.cs:16— Method ToDisplayName — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: Reset platforms/windows/PortKiller/Models/PortFilter.cs:58— Method Reset — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: GetIcon platforms/windows/PortKiller/Models/PortFilter.cs:105— Method GetIcon — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: GetDisplayName platforms/windows/PortKiller/Models/ProcessType.cs:24— Method GetDisplayName — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: GetIcon platforms/windows/PortKiller/Models/ProcessType.cs:37— Method GetIcon — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: Unregister platforms/windows/PortKiller/Services/NotificationService.cs:84— Method Unregister — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: MIB_TCP6TABLE_OWNER_PID platforms/windows/PortKiller/Services/PortScannerService.cs:89— NamedType MIB_TCP6TABLE_OWNER_PID — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: KillProcessAsync platforms/windows/PortKiller/Services/ProcessKillerService.cs:19— Method KillProcessAsync — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: KillProcessesOnPortAsync platforms/windows/PortKiller/Services/ProcessKillerService.cs:104— Method KillProcessesOnPortAsync — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: ProcessExists platforms/windows/PortKiller/Services/ProcessKillerService.cs:124— Method ProcessExists — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: GetAutoStart platforms/windows/PortKiller/Services/SettingsService.cs:113— Method GetAutoStart — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: SaveAutoStart platforms/windows/PortKiller/Services/SettingsService.cs:119— Method SaveAutoStart — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: ClearAllSettings platforms/windows/PortKiller/Services/SettingsService.cs:155— Method ClearAllSettings — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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: IsRunning platforms/windows/PortKiller/Services/TunnelService.cs:214— Method IsRunning — Roslyn's SymbolFinder walked every project the solution loads, including PortKiller, 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.
Duplicated block (9 lines × 2) platforms/macos/Sources/Services/PortGroupingService.swift:37— platforms/macos/Sources/Services/PortGroupingService.swift:37-45 | platforms/macos/Sources/Views/PortTable/PortTableView.swift:210-218 — 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 `platforms/macos/Sources/Services/PortGroupingService.swift:37` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (9 lines × 2) platforms/macos/Sources/Services/PortGroupingService.swift:74— platforms/macos/Sources/Services/PortGroupingService.swift:74-83 | platforms/macos/Sources/Views/MenuBar/MenuBarView.swift:91-99 — 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 `platforms/macos/Sources/Services/PortGroupingService.swift:74` 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.
Duplicated block (9 lines × 2) platforms/macos/Sources/Views/PortForwarder/PortForwarderToolbar.swift:85— platforms/macos/Sources/Views/PortForwarder/PortForwarderToolbar.swift:85-93 | platforms/macos/Sources/Views/PortForwarder/Tabs/ConnectionsTab.swift:39-47 — 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 × 2) platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:78— platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:78-86 | platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift:131-139 — before extracting anything, compare `platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift` and `platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 40 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 `platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:78` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (9 lines × 2) platforms/macos/Sources/Services/PermissionService.swift:152— platforms/macos/Sources/Services/PermissionService.swift:152-160 | platforms/macos/Sources/Views/Settings/PermissionsSection.swift:107-115 — 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 × 2) platforms/macos/Sources/Views/CloudflareTunnels/NamedTunnelDetailView.swift:69— platforms/macos/Sources/Views/CloudflareTunnels/NamedTunnelDetailView.swift:69-77 | platforms/macos/Sources/Views/CloudflareTunnels/NamedTunnelsSection.swift:233-241 — 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.
Stateful singleton: NotificationService platforms/windows/PortKiller/Services/NotificationService.cs:9— `NotificationService` is a singleton (one shared instance) but mutates instance state outside any lock (_isInitialized; e.g. `_isInitialized` at line 25).
Stateful singleton: TunnelService platforms/windows/PortKiller/Services/TunnelService.cs:11— `TunnelService` is a singleton (one shared instance) but mutates instance state outside any lock (_processes, _urlHandlers, _errorHandlers; e.g. `_processes` at line 122).
Stateful singleton: MainViewModel platforms/windows/PortKiller/ViewModels/MainViewModel.cs:20— `MainViewModel` is a singleton (one shared instance) but mutates instance state outside any lock (IsScanning, _refreshCancellation, _previousPortStates; e.g. `IsScanning` at line 120).
Stateful singleton: TunnelViewModel platforms/windows/PortKiller/ViewModels/TunnelViewModel.cs:15— `TunnelViewModel` is a singleton (one shared instance) but mutates instance state outside any lock (_isCloudflaredInstalled, _cloudflaredProtocol; e.g. `_isCloudflaredInstalled` at line 30).
LinuxScanner::parse_ss_output (cognitive 35) portkiller-core/src/scanner/linux.rs:309— LinuxScanner::parse_ss_output has cognitive complexity 35 (threshold 15). Drivers by points: if/else 11 (26 pts), loops 2 (5 pts), match/switch 2 (4 pts) (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
LinuxScanner::decode_escaped (cognitive 33) portkiller-core/src/scanner/linux.rs:155— LinuxScanner::decode_escaped has cognitive complexity 33 (threshold 15). Drivers by points: if/else 9 (28 pts), loops 2 (5 pts) (nesting depth added 22). 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.
LinuxScanner::parse_lsof_output (cognitive 19) portkiller-core/src/scanner/linux.rs:250— LinuxScanner::parse_lsof_output has cognitive complexity 19 (threshold 15). Drivers by points: if/else 4 (9 pts), match/switch 3 (6 pts), loops 2 (3 pts), boolean chains 1 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
LinuxScanner::get_pids_on_port_ss (cognitive 16) portkiller-core/src/scanner/linux.rs:52— LinuxScanner::get_pids_on_port_ss has cognitive complexity 16 (threshold 15). Drivers by points: if/else 4 (7 pts), loops 2 (4 pts), match/switch 2 (4 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
Duplicated block (10 lines × 2) platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionEditSection.swift:232— platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionEditSection.swift:232-241 | platforms/macos/Sources/Views/PortForwarder/TableComponents/PortForwarderTableRow.swift:20-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. 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) platforms/macos/Sources/PortScanner.swift:56— platforms/macos/Sources/PortScanner.swift:56-65 | platforms/macos/Sources/PortScanner.swift:382-391 — 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 `platforms/macos/Sources/PortScanner.swift:382` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (10 lines × 2) platforms/macos/Sources/Services/PermissionService.swift:173— platforms/macos/Sources/Services/PermissionService.swift:173-182 | platforms/macos/Sources/Views/Settings/PermissionsSection.swift:128-137 — 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 (10 lines × 2) platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionEditSection.swift:221— platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionEditSection.swift:221-230 | platforms/macos/Sources/Views/PortForwarder/TableComponents/PortForwarderTableRow.swift:9-18 — 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.
Unfinished stub — throws NotImplementedException platforms/windows/PortKiller/Helpers/ValueConverters.cs:21— A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
Unfinished stub — throws NotImplementedException platforms/windows/PortKiller/Helpers/ValueConverters.cs:37— A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
Unfinished stub — throws NotImplementedException platforms/windows/PortKiller/Helpers/ValueConverters.cs:56— A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
Unfinished stub — throws NotImplementedException platforms/windows/PortKiller/Helpers/ValueConverters.cs:75— A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
Sync-over-async blocking platforms/macos/Sources/Managers/PortForwardProcessManager.swift:121— `killAllPortForwarderProcesses` is async and calls .waitUntilExit() — a blocking call inside async code stalls the cooperative pool's thread — one per core — and every task scheduled on it for as long as it runs.
Sync-over-async blocking platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:86— `startDirectExecProxy` is async and calls .waitUntilExit() — a blocking call inside async code stalls the cooperative pool's thread — one per core — and every task scheduled on it for as long as it runs.
Sync-over-async blocking platforms/macos/Sources/Services/ProcessExecutor.swift:34— `run` is async and calls .waitUntilExit() — a blocking call inside async code stalls the cooperative pool's thread — one per core — and every task scheduled on it for as long as it runs.
Sync-over-async blocking platforms/macos/Sources/Services/ProcessExecutor.swift:86— `runDiscardingOutput` is async and calls .waitUntilExit() — a blocking call inside async code stalls the cooperative pool's thread — one per core — and every task scheduled on it for as long as it runs.
D4 · Code Duplication· Edited copy of a member (9 corresponding lines) · ×3
Edited copy of a member (9 corresponding lines) platforms/windows/PortKiller/MainWindow.xaml.cs:404— platforms/windows/PortKiller/MainWindow.xaml.cs:404-428 | platforms/windows/PortKiller/MainWindow.xaml.cs:431-444 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (9 corresponding lines) platforms/windows/PortKiller/CloudflareTunnelsView.xaml.cs:67— platforms/windows/PortKiller/CloudflareTunnelsView.xaml.cs:67-75 | platforms/windows/PortKiller/MainWindow.xaml.cs:480-488 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (9 corresponding lines) platforms/windows/PortKiller/CloudflareTunnelsView.xaml.cs:78— platforms/windows/PortKiller/CloudflareTunnelsView.xaml.cs:78-86 | platforms/windows/PortKiller/MainWindow.xaml.cs:491-499 — These two members are one piece of code written twice and then edited apart: 9 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (14 corresponding lines) · ×3
Edited copy of a member (14 corresponding lines) platforms/macos/Sources/Managers/PortForwardProcessManager+Kubernetes.swift:22— platforms/macos/Sources/Managers/PortForwardProcessManager+Kubernetes.swift:22-35 | platforms/macos/Sources/Managers/PortForwardProcessManager+Kubernetes.swift:38-53 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (14 corresponding lines) platforms/linux/src/ui/tray.py:81— platforms/linux/src/ui/tray.py:81-94 | platforms/linux/src/ui/tray.py:259-285 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (14 corresponding lines) platforms/macos/Sources/Services/PermissionService.swift:86— platforms/macos/Sources/Services/PermissionService.swift:86-99 | platforms/macos/Sources/Views/Settings/SettingsView.swift:236-249 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (17 corresponding lines) · ×3
Edited copy of a member (17 corresponding lines) platforms/macos/Sources/Views/CloudflareTunnels/NamedTunnelDetailView.swift:276— platforms/macos/Sources/Views/CloudflareTunnels/NamedTunnelDetailView.swift:276-292 | platforms/macos/Sources/Views/CloudflareTunnels/NamedTunnelsSection.swift:149-166 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (17 corresponding lines) platforms/macos/Sources/Managers/NamedTunnelManager.swift:84— platforms/macos/Sources/Managers/NamedTunnelManager.swift:84-100 | platforms/macos/Sources/Managers/NamedTunnelManager.swift:105-121 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (17 corresponding lines) platforms/windows/PortKiller/Services/PortScannerService.cs:362— platforms/windows/PortKiller/Services/PortScannerService.cs:362-379 | platforms/windows/PortKiller/Services/TunnelService.cs:293-309 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Duplicated block (14 lines × 2) platforms/macos/Sources/Views/SponsorsWindowView.swift:111— platforms/macos/Sources/Views/SponsorsWindowView.swift:111-124 | platforms/macos/Sources/Views/SponsorsWindowView.swift:133-146 — 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 `platforms/macos/Sources/Views/SponsorsWindowView.swift:111` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (14 lines × 2) platforms/linux/src/ui/dialogs.py:96— platforms/linux/src/ui/dialogs.py:96-109 | platforms/linux/src/ui/dialogs.py:112-125 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (14 lines × 2) platforms/linux/src/ui/window.py:348— platforms/linux/src/ui/window.py:348-361 | platforms/linux/src/ui/window.py:424-437 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (8 lines × 2) platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:56— platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:56-63 | platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:139-146 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (8 lines × 2) platforms/macos/Sources/Services/PermissionService.swift:163— platforms/macos/Sources/Services/PermissionService.swift:163-170 | platforms/macos/Sources/Views/Settings/PermissionsSection.swift:118-125 — 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 (8 lines × 2) portkiller-core/src/scanner/linux.rs:53— portkiller-core/src/scanner/linux.rs:53-60 | portkiller-core/src/scanner/linux.rs:415-422 — 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `portkiller-core/src/scanner/linux.rs:48` calls `get_pids_on_port_ss` and `portkiller-core/src/scanner/linux.rs:412` 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 lines × 2) platforms/macos/Sources/Services/PortGroupingService.swift:60— platforms/macos/Sources/Services/PortGroupingService.swift:60-66 | platforms/macos/Sources/Views/MenuBar/MenuBarView.swift:79-85 — 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 `platforms/macos/Sources/Services/PortGroupingService.swift:60` 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.
Duplicated block (7 lines × 2) platforms/macos/Sources/Views/PortForwarder/Settings/DependencyRow.swift:91— platforms/macos/Sources/Views/PortForwarder/Settings/DependencyRow.swift:91-97 | platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift:183-189 — 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 before the matched lines, `platforms/macos/Sources/Views/PortForwarder/Settings/DependencyRow.swift:88` calls `padding` and `platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift:180` 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) platforms/linux/src/ui/window.py:327— platforms/linux/src/ui/window.py:327-333 | platforms/linux/src/ui/window.py:414-420 — 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `platforms/linux/src/ui/window.py:411` calls `set_margin_start` and `platforms/linux/src/ui/window.py:324` 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.
Stateful shared instance: PortFilter platforms/windows/PortKiller/Models/PortFilter.cs:10— `PortFilter` is not registered, but the singleton `MainViewModel` creates it and keeps it in `_filter`, so one instance outlives every request and is shared by every caller that reaches it — and it mutates instance state outside any lock (SearchText, MinPort, MaxPort, ProcessTypes, ShowOnlyFavorites, ShowOnlyWatched; e.g. `SearchText` at line 60).
Stateful shared instance: CloudflareTunnel platforms/windows/PortKiller/Models/CloudflareTunnel.cs:22— `CloudflareTunnel` is not registered, but the singleton `TunnelViewModel` creates it and keeps it in `Tunnels`, so one instance outlives every request and is shared by every caller that reaches it — and it mutates instance state outside any lock (_id, _port, _status, _tunnelUrl, _lastError, _startTime; e.g. `_id` at line 35).
MethodTooLong: SettingsView.body platforms/macos/Sources/Views/Settings/SettingsView.swift:30— MethodTooLong — body runs 110 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 10 over it, 1.10× 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: ConnectionInfoSection.body platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionInfoSection.swift:23— MethodTooLong — body 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.
D4 · Code Duplication· Edited copy of a member (12 corresponding lines) · ×2
Edited copy of a member (12 corresponding lines) platforms/macos/Sources/Views/PortForwarder/DetailPanel/KubeContextPicker.swift:109— platforms/macos/Sources/Views/PortForwarder/DetailPanel/KubeContextPicker.swift:109-122 | platforms/macos/Sources/Views/PortForwarder/Settings/DependencyRow.swift:99-110 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Edited copy of a member (12 corresponding lines) platforms/macos/Sources/Services/PermissionService.swift:68— platforms/macos/Sources/Services/PermissionService.swift:68-79 | platforms/macos/Sources/Views/Settings/SettingsView.swift:215-233 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
Duplicated block (21 lines × 2) platforms/macos/Sources/Views/SponsorsWindowView.swift:203— platforms/macos/Sources/Views/SponsorsWindowView.swift:203-223 | platforms/macos/Sources/Views/SponsorsWindowView.swift:311-331 — 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 `platforms/macos/Sources/Views/SponsorsWindowView.swift:203` 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, `platforms/macos/Sources/Views/SponsorsWindowView.swift:309` calls `ZStack` and `platforms/macos/Sources/Views/SponsorsWindowView.swift:201` 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 (21 lines × 2) portkiller-core/src/scanner/linux.rs:63— portkiller-core/src/scanner/linux.rs:63-83 | portkiller-core/src/scanner/linux.rs:313-333 — 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 `portkiller-core/src/scanner/linux.rs:63` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (18 lines × 2) platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionInfoSection.swift:71— platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionInfoSection.swift:71-88 | platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionInfoSection.swift:118-135 — 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 `platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionInfoSection.swift:71` 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 after the matched lines, `platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionInfoSection.swift:89` calls `frame` and `platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionInfoSection.swift:136` 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 (18 lines × 2) platforms/macos/Sources/Views/SponsorsWindowView.swift:280— platforms/macos/Sources/Views/SponsorsWindowView.swift:280-297 | platforms/macos/Sources/Views/SponsorsWindowView.swift:402-419 — 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 `platforms/macos/Sources/Views/SponsorsWindowView.swift:280` 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.
Duplicated block (17 lines × 2) platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:57— platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:57-73 | platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift:98-114 — before extracting anything, compare `platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift` and `platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 40 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 `platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:57` 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 `spacing` to `10` in one and `6` 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 (17 lines × 2) platforms/linux/src/ui/tray.py:129— platforms/linux/src/ui/tray.py:129-145 | platforms/linux/src/ui/tray.py:159-175 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (13 lines × 2) platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:63— platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:63-75 | platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:76-88 — 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 `platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:63` 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 (13 lines × 2) platforms/macos/Sources/Views/PortForwarder/PortForwarderToolbar.swift:71— platforms/macos/Sources/Views/PortForwarder/PortForwarderToolbar.swift:71-83 | platforms/macos/Sources/Views/PortForwarder/Tabs/ConnectionsTab.swift: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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `platforms/macos/Sources/Views/PortForwarder/Tabs/ConnectionsTab.swift:37` calls `help` and `platforms/macos/Sources/Views/PortForwarder/PortForwarderToolbar.swift:85` 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 (12 lines × 2) platforms/macos/Sources/Managers/KubernetesDiscoveryManager.swift:61— platforms/macos/Sources/Managers/KubernetesDiscoveryManager.swift:61-72 | platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionEditSection.swift:173-184 — 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 (12 lines × 2) platforms/macos/Sources/Views/Components/PortRow/PortRowView.swift:109— platforms/macos/Sources/Views/Components/PortRow/PortRowView.swift:109-120 | platforms/macos/Sources/Views/Components/PortRow/PortRowView.swift:176-187 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (11 lines × 2) platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:261— platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:261-271 | platforms/macos/Sources/Views/MenuBar/MenuBarTunnelRow.swift:34-44 — before extracting anything, compare `platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift` and `platforms/macos/Sources/Views/MenuBar/MenuBarTunnelRow.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 41 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:261` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (11 lines × 2) platforms/linux/src/ui/window.py:271— platforms/linux/src/ui/window.py:271-281 | platforms/linux/src/ui/window.py:302-312 — 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `platforms/linux/src/ui/window.py:270` calls `set_line_wrap` and `platforms/linux/src/ui/window.py:301` 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.
Low cohesion: AppDelegate (LCOM4 4) platforms/macos/Sources/PortKillerApp.swift:4— AppDelegate's methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
Low cohesion: PortForwardProcessManager (LCOM4 4) platforms/macos/Sources/Managers/PortForwardProcessManager.swift:6— PortForwardProcessManager's methods fall into 4 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 4 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
MenuBarWindow.render_list (cyclomatic 27) platforms/linux/src/ui/window.py:136— MenuBarWindow.render_list has cyclomatic complexity 27 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PortForwardManager.checkConnections (cyclomatic 24) platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:28— PortForwardManager.checkConnections has cyclomatic complexity 24 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PortFilter.matches (cyclomatic 19) platforms/macos/Sources/Models/PortFilter.swift:20— PortFilter.matches has cyclomatic complexity 19 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
PortForwardManager.startConnection (cyclomatic 18) platforms/macos/Sources/Managers/PortForwardManager.swift:136— PortForwardManager.startConnection has cyclomatic complexity 18 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
PortFilter.Matches (cyclomatic 17) platforms/windows/PortKiller/Models/PortFilter.cs:27— PortFilter.Matches has cyclomatic complexity 17 (threshold 15). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
SponsorCard.body (cyclomatic 16) platforms/macos/Sources/Views/SponsorsWindowView.swift:200— SponsorCard.body 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.
MenuBarWindow.render_list (cognitive 44) platforms/linux/src/ui/window.py:136— MenuBarWindow.render_list has cognitive complexity 44 (threshold 15). Drivers by points: if/else 10 (17 pts), loops 9 (17 pts), boolean chains 6, ternaries 2 (4 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PortForwardManager.checkConnections (cognitive 43) platforms/macos/Sources/Managers/PortForwardManager+Monitoring.swift:28— PortForwardManager.checkConnections has cognitive complexity 43 (threshold 15). Drivers by points: if/else 14 (34 pts), boolean chains 8, loops 1 (nesting depth added 20). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PortScanner.parse_ss_output (cognitive 29) platforms/linux/src/scanner.py:89— PortScanner.parse_ss_output has cognitive complexity 29 (threshold 15). Drivers by points: if/else 9 (23 pts), loops 2 (4 pts), error handling 1 (2 pts) (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PortKillerTrayApp.build_menu_with_data (cognitive 28) platforms/linux/src/ui/tray.py:96— PortKillerTrayApp.build_menu_with_data has cognitive complexity 28 (threshold 15). Drivers by points: if/else 8 (12 pts), ternaries 3 (9 pts), loops 4 (7 pts) (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
MainWindow.UpdateTrayMenu (cognitive 26) platforms/windows/PortKiller/MainWindow.xaml.cs:541— MainWindow.UpdateTrayMenu has cognitive complexity 26 (threshold 15). Of this number, 17 points are the body's own statements and 9 belong to one function literal inside it that branches. To reduce it, flatten the nesting: invert conditions into early returns or guard clauses so the happy path stays at one level, and lift the deepest nested block into its own named function.
CloudflaredDiscoveryService.parseConfigYAML (cognitive 24) platforms/macos/Sources/Services/CloudflaredDiscoveryService.swift:140— CloudflaredDiscoveryService.parseConfigYAML has cognitive complexity 24 (threshold 15). Drivers by points: if/else 13 (22 pts), boolean chains 1, loops 1 (nesting depth added 9). Of this number, 23 points are the body's own statements and 1 belongs to one function item inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
NamedTunnelManager.discoverAsync (cognitive 23) platforms/macos/Sources/Managers/NamedTunnelManager.swift:135— NamedTunnelManager.discoverAsync has cognitive complexity 23 (threshold 15). Drivers by points: if/else 8 (18 pts), loops 3, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PortForwardProcessManager.startReadingOutput (cognitive 23) platforms/macos/Sources/Managers/PortForwardProcessManager.swift:27— PortForwardProcessManager.startReadingOutput has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (20 pts), loops 1 (2 pts), error handling 1 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
MiniPortKillerWindow.ContextMenu_ShareViaTunnel (cognitive 22) platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:593— MiniPortKillerWindow.ContextMenu_ShareViaTunnel has cognitive complexity 22 (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.
PortScanner.parse_lsof_output (cognitive 22) platforms/linux/src/scanner.py:34— PortScanner.parse_lsof_output has cognitive complexity 22 (threshold 15). Drivers by points: if/else 8 (16 pts), loops 2 (3 pts), error handling 1 (2 pts), boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PortScanner.parseLsofOutput (cognitive 20) platforms/macos/Sources/PortScanner.swift:162— PortScanner.parseLsofOutput has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (15 pts), loops 2 (3 pts), boolean chains 2 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PortFilter.matches (cognitive 19) platforms/macos/Sources/Models/PortFilter.swift:20— PortFilter.matches has cognitive complexity 19 (threshold 15). Drivers by points: boolean chains 11, if/else 7 (8 pts) (nesting depth added 1). To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
K8sService._parse_port_forward_cmd (cognitive 19) platforms/linux/src/services/k8s.py:68— K8sService._parse_port_forward_cmd has cognitive complexity 19 (threshold 15). Drivers by points: if/else 9 (16 pts), loops 1 (2 pts), boolean chains 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
TunnelManager._startTunnelImpl (cognitive 18) platforms/macos/Sources/Managers/TunnelManager.swift:80— TunnelManager._startTunnelImpl has cognitive complexity 18 (threshold 15). Drivers by points: if/else 11 (15 pts), boolean chains 2, error handling 1 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
MenuBarTunnelRow.body (cognitive 18) platforms/macos/Sources/Views/MenuBar/MenuBarTunnelRow.swift:9— MenuBarTunnelRow.body has cognitive complexity 18 (threshold 15). Drivers by points: if/else 8 (10 pts), ternaries 4 (6 pts), boolean chains 2 (nesting depth added 4). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
K8sService.scan_active_forwards (cognitive 18) platforms/linux/src/services/k8s.py:25— K8sService.scan_active_forwards has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (11 pts), error handling 2 (4 pts), boolean chains 2, loops 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PortForwardManager.startConnection (cognitive 17) platforms/macos/Sources/Managers/PortForwardManager.swift:136— PortForwardManager.startConnection has cognitive complexity 17 (threshold 15). Drivers by points: if/else 11, boolean chains 6. 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.
SponsorCard.body (cognitive 17) platforms/macos/Sources/Views/SponsorsWindowView.swift:200— SponsorCard.body has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (8 pts), ternaries 8, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, 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.
PortScanner.commandLine (cognitive 16) platforms/macos/Sources/PortScanner.swift:100— PortScanner.commandLine has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 5, if/else 4 (5 pts), loops 4 (5 pts), ternaries 1 (nesting depth added 2). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
CloudflaredDiscoveryService.discover (cognitive 16) platforms/macos/Sources/Services/CloudflaredDiscoveryService.swift:38— CloudflaredDiscoveryService.discover has cognitive complexity 16 (threshold 15). Drivers by points: if/else 5 (9 pts), loops 3 (5 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
CloudflareService.scan_running_tunnels_from_ps (cognitive 16) platforms/linux/src/services/cloudflare.py:132— CloudflareService.scan_running_tunnels_from_ps has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (11 pts), error handling 2 (3 pts), boolean chains 1, loops 1 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
TooManyMethods: MainWindow platforms/windows/PortKiller/MainWindow.xaml.cs— TooManyMethods — 291 significant lines (blank, comment-only and punctuation-only lines excluded), 37 methods. The bar is 30 methods; this is 7 over it, 1.23× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
Near-duplicate member pair (39 shared lines) platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:23— platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:23-120 | platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift:82-181 — These two members are variants of one another: 39 of their lines are already reported as duplicated blocks below, spread through both bodies rather than gathered into one. Read them as a single construct written twice. The repair is at the members' grain — factor the shared pipeline into one implementation the two call with their differences as parameters or as an injected step, or, where the difference is systematic (sync against async, one transport against another), generate one from the other. Extracting the individual blocks below is not the same fix: it leaves the two bodies in place and the next edit still has to be made twice.
D4 · Code Duplication· Members sharing a duplicated core (4 members, 50+ identical tokens) · ×1
Members sharing a duplicated core (4 members, 50+ identical tokens) platforms/macos/Sources/Services/PortGroupingService.swift:35— platforms/macos/Sources/Services/PortGroupingService.swift:35-45 | platforms/macos/Sources/Services/PortGroupingService.swift:57-84 | platforms/macos/Sources/Views/MenuBar/MenuBarView.swift:40-104 | platforms/macos/Sources/Views/PortTable/PortTableView.swift:208-218 — 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.
D4 · Code Duplication· Edited copy of a member (77 corresponding lines) · ×1
Edited copy of a member (77 corresponding lines) platforms/macos/Sources/Views/SponsorsWindowView.swift:200— platforms/macos/Sources/Views/SponsorsWindowView.swift:200-276 | platforms/macos/Sources/Views/SponsorsWindowView.swift:307-398 — These two members are one piece of code written twice and then edited apart: 77 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (25 corresponding lines) · ×1
Edited copy of a member (25 corresponding lines) platforms/linux/src/ui/window.py:255— platforms/linux/src/ui/window.py:255-285 | platforms/linux/src/ui/window.py:292-316 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (46 corresponding lines) · ×1
Edited copy of a member (46 corresponding lines) platforms/windows/PortKiller/Services/PortScannerService.cs:212— platforms/windows/PortKiller/Services/PortScannerService.cs:212-257 | platforms/windows/PortKiller/Services/PortScannerService.cs:263-311 — These two members are one piece of code written twice and then edited apart: 46 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (36 corresponding lines) · ×1
Edited copy of a member (36 corresponding lines) platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:5— platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:5-45 | platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:48-83 — These two members are one piece of code written twice and then edited apart: 36 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (34 corresponding lines) · ×1
Edited copy of a member (34 corresponding lines) platforms/macos/Sources/Managers/KubernetesDiscoveryManager.swift:50— platforms/macos/Sources/Managers/KubernetesDiscoveryManager.swift:50-86 | platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionEditSection.swift:166-199 — These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (41 corresponding lines) · ×1
Edited copy of a member (41 corresponding lines) platforms/linux/src/services/cloudflare.py:133— platforms/linux/src/services/cloudflare.py:133-188 | platforms/linux/src/services/k8s.py:26-66 — These two members are one piece of code written twice and then edited apart: 41 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (21 corresponding lines) · ×1
Edited copy of a member (21 corresponding lines) platforms/macos/Sources/Views/SponsorsWindowView.swift:110— platforms/macos/Sources/Views/SponsorsWindowView.swift:110-130 | platforms/macos/Sources/Views/SponsorsWindowView.swift:132-152 — These two members are one piece of code written twice and then edited apart: 21 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copies of one member (3 members, 20+ corresponding lines) · ×1
Edited copies of one member (3 members, 20+ corresponding lines) platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:367— platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:367-392 | platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:395-429 | platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:432-451 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication· Edited copy of a member (24 corresponding lines) · ×1
Edited copy of a member (24 corresponding lines) platforms/macos/Sources/Managers/PortForwardManager+Execution.swift:47— platforms/macos/Sources/Managers/PortForwardManager+Execution.swift:47-78 | platforms/macos/Sources/Managers/PortForwardManager+Execution.swift:81-104 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (15 corresponding lines) · ×1
Edited copy of a member (15 corresponding lines) platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:133— platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:133-152 | platforms/macos/Sources/Views/CloudflareTunnels/NamedTunnelsSection.swift:82-96 — These two members are one piece of code written twice and then edited apart: 15 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (20 corresponding lines) · ×1
Edited copy of a member (20 corresponding lines) platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:545— platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:545-569 | platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:572-591 — These two members are one piece of code written twice and then edited apart: 20 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (31 corresponding lines) · ×1
Edited copy of a member (31 corresponding lines) platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:80— platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:80-110 | platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:125-160 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (5 corresponding lines) · ×1
Edited copy of a member (5 corresponding lines) platforms/macos/Sources/Views/MenuBar/MenuBarPortList.swift:100— platforms/macos/Sources/Views/MenuBar/MenuBarPortList.swift:100-104 | platforms/macos/Sources/Views/PortForwarder/PortForwarderSidebarContent.swift:78-82 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (10 corresponding lines) · ×1
Edited copy of a member (10 corresponding lines) platforms/macos/Sources/Views/MenuBar/MenuBarPortForwardRow.swift:8— platforms/macos/Sources/Views/MenuBar/MenuBarPortForwardRow.swift:8-17 | platforms/macos/Sources/Views/PortForwarder/PortForwardConnectionCard.swift:10-20 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (16 corresponding lines) · ×1
Edited copy of a member (16 corresponding lines) platforms/windows/PortKiller/CloudflareTunnelsView.xaml.cs:49— platforms/windows/PortKiller/CloudflareTunnelsView.xaml.cs:49-64 | platforms/windows/PortKiller/MainWindow.xaml.cs:453-469 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copy of a member (6 corresponding lines) · ×1
Edited copy of a member (6 corresponding lines) platforms/windows/PortKiller/Models/CloudflareTunnel.cs:161— platforms/windows/PortKiller/Models/CloudflareTunnel.cs:161-166 | platforms/windows/PortKiller/ViewModels/TunnelViewModel.cs:297-302 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication· Edited copies of one member (3 members, 6+ corresponding lines) · ×1
Edited copies of one member (3 members, 6+ corresponding lines) platforms/macos/Sources/Services/DependencyChecker.swift:68— platforms/macos/Sources/Services/DependencyChecker.swift:68-76 | platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:16-21 | platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift:68-73 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 6 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
Duplicated block (34–35 lines × 2) platforms/windows/PortKiller/Services/PortScannerService.cs:118— platforms/windows/PortKiller/Services/PortScannerService.cs:118-152 | platforms/windows/PortKiller/Services/PortScannerService.cs:158-191 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (29–31 lines × 2) platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:80— platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:80-110 | platforms/windows/PortKiller/Helpers/WindowBlurHelper.cs:127-155 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (27 lines × 2) platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:57— platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:57-83 | platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:120-146 — 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 `platforms/macos/Sources/Managers/PortForwardProcessManager+Execution.swift:57` 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 (26 lines × 2) platforms/macos/Sources/Views/SponsorsWindowView.swift:242— platforms/macos/Sources/Views/SponsorsWindowView.swift:242-267 | platforms/macos/Sources/Views/SponsorsWindowView.swift:364-389 — 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 `platforms/macos/Sources/Views/SponsorsWindowView.swift:242` 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 (25 lines × 2) platforms/macos/Sources/Views/Settings/SettingsComponents.swift:99— platforms/macos/Sources/Views/Settings/SettingsComponents.swift:99-123 | platforms/macos/Sources/Views/Settings/SettingsComponents.swift:137-161 — 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 `platforms/macos/Sources/Views/Settings/SettingsComponents.swift:99` 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.
Duplicated block (22 lines × 2) platforms/macos/Sources/Views/PortForwarder/Browser/NamespaceListView.swift:39— platforms/macos/Sources/Views/PortForwarder/Browser/NamespaceListView.swift:39-60 | platforms/macos/Sources/Views/PortForwarder/Browser/ServiceListView.swift:22-43 — 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 `platforms/macos/Sources/Views/PortForwarder/Browser/NamespaceListView.swift:39` 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 (19 lines × 2) platforms/macos/Sources/Views/PortForwarder/ServiceBrowserView.swift:42— platforms/macos/Sources/Views/PortForwarder/ServiceBrowserView.swift:42-60 | platforms/macos/Sources/Views/PortForwarder/Tabs/ServiceBrowserTab.swift:71-89 — 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 `platforms/macos/Sources/Views/PortForwarder/ServiceBrowserView.swift:42` 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–17 lines × 2) platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:232— platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:232-244 | platforms/macos/Sources/Views/MenuBar/MenuBarTunnelRow.swift:66-82 — before extracting anything, compare `platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift` and `platforms/macos/Sources/Views/MenuBar/MenuBarTunnelRow.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 41 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. Read the line range as the matched WINDOW rather than a finished unit: at `platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:232` 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 (16 lines × 2) platforms/macos/Sources/Views/Onboarding/OnboardingSetupStep.swift:29— platforms/macos/Sources/Views/Onboarding/OnboardingSetupStep.swift:29-44 | platforms/macos/Sources/Views/Onboarding/OnboardingSetupStep.swift:70-85 — 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 `platforms/macos/Sources/Views/Onboarding/OnboardingSetupStep.swift: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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `platforms/macos/Sources/Views/Onboarding/OnboardingSetupStep.swift:27` calls `toggleStyle` and `platforms/macos/Sources/Views/Onboarding/OnboardingSetupStep.swift: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 (13–14 lines × 2) platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:98— platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:98-110 | platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift:151-164 — before extracting anything, compare `platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift` and `platforms/macos/Sources/Views/Settings/PortForwardingSettingsSection.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 40 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 `platforms/macos/Sources/Views/Settings/CloudflaredSettingsSection.swift:98` 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 (8–13 lines × 3) platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:235— platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift:235-242 | platforms/macos/Sources/Views/Components/PortContextMenu.swift:224-236 | platforms/macos/Sources/Views/MenuBar/MenuBarTunnelRow.swift:69-80 — before extracting anything, compare `platforms/macos/Sources/Views/CloudflareTunnels/CloudflareTunnelsView.swift` and `platforms/macos/Sources/Views/MenuBar/MenuBarTunnelRow.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 41 lines, which is the signature of one file having been copied from the other rather than of a helper waiting to be extracted. The two sit in different directories, so one cannot simply be deleted in favour of the other while both are reached separately: hoist the shared part into a location both already depend on and have each file call it, and retire whichever file turns out to have no caller of its own left. Extracting one helper per block leaves the fork in place. 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 (10 lines × 3) platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:368— platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:368-377 | platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:396-405 | platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:433-442 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:380` calls `Stop` and `platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:445` 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 (9–11 lines × 2) platforms/windows/PortKiller/MainWindow.xaml.cs:409— platforms/windows/PortKiller/MainWindow.xaml.cs:409-419 | platforms/windows/PortKiller/MainWindow.xaml.cs:434-442 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (7 lines × 3) platforms/macos/Sources/Services/PortGroupingService.swift:37— platforms/macos/Sources/Services/PortGroupingService.swift:37-43 | platforms/macos/Sources/Services/PortGroupingService.swift:59-65 | platforms/macos/Sources/Views/PortTable/PortTableView.swift:210-216 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `platforms/macos/Sources/Services/PortGroupingService.swift: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. 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 (5 lines × 2) platforms/windows/PortKiller/Models/CloudflareTunnel.cs:162— platforms/windows/PortKiller/Models/CloudflareTunnel.cs:162-166 | platforms/windows/PortKiller/ViewModels/TunnelViewModel.cs:298-302 — 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. Each matched range is the entire body of the declaration above it, so the region is already a complete unit: move that whole declaration to the shared location and have each site call it, rather than lifting the lines out of their bodies. Any `return` inside it is the body's own exit and keeps its meaning in the moved unit.
Duplicated block (6 lines × 2) platforms/macos/Sources/Models/CloudflareTunnel.swift:43— platforms/macos/Sources/Models/CloudflareTunnel.swift:43-48 | platforms/macos/Sources/Models/NamedCloudflareTunnel.swift:105-110 — 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 (8 lines × 3) platforms/macos/Sources/Services/CloudflaredService.swift:43— platforms/macos/Sources/Services/CloudflaredService.swift:43-50 | platforms/macos/Sources/Services/DependencyChecker.swift:88-95 | platforms/macos/Sources/Services/DependencyChecker.swift:97-104 — there are 3 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 3 sites; resolving a subset leaves the remainder to drift apart. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (12–13 lines × 2) platforms/linux/src/ui/tray.py:64— platforms/linux/src/ui/tray.py:64-75 | platforms/linux/src/ui/window.py:108-120 — 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 × 3) platforms/linux/src/ui/tray.py:102— platforms/linux/src/ui/tray.py:102-112 | platforms/linux/src/ui/tray.py:135-145 | platforms/linux/src/ui/tray.py:165-175 — 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `platforms/linux/src/ui/tray.py:113` calls `hasattr`, `get` and `platforms/linux/src/ui/tray.py:146` 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.
SC1 · Supply-chain hygiene· NuGet dependencies are not locked · ×1
NuGet dependencies are not locked — No packages.lock.json and no central package management — restores aren't reproducible or pinned (SSDF PW.4.4). Enable <RestorePackagesWithLockFile>true</RestorePackagesWithLockFile> (commit the lockfile) or adopt Directory.Packages.props. Advisory — never scored.
redundant comment platforms/windows/PortKiller/MainWindow.xaml.cs:29— "Setup keyboard shortcuts" repeats the code it sits on: 3 of its 3 words (setup, keyboard, shortcuts) are already in `SetupKeyboardShortcuts();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment platforms/windows/PortKiller/MainWindow.xaml.cs:133— "Update ports list" repeats the code it sits on: 3 of its 3 words (update, ports, list) are already in `PortsListView.ItemsSource = _viewModel.FilteredPorts;`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment platforms/windows/PortKiller/MainWindow.xaml.cs:405— "Bind tunnels list to view model" repeats the code it sits on: 4 of its 5 words (tunnels, list, view, model) are already in `TunnelsListView.ItemsSource = _tunnelViewModel.Tunnels;`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:390— "Start spinner animation" repeats the code it sits on: 3 of its 3 words (start, spinner, animation) are already in `StartSpinnerAnimation();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:407— "Stop spinner animation" repeats the code it sits on: 3 of its 3 words (stop, spinner, animation) are already in `StopSpinnerAnimation();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment platforms/windows/PortKiller/MiniPortKillerWindow.xaml.cs:659— "Helper method to find a child element by name in a visual tree" repeats the code it sits on: 7 of its 8 words (helper, find, child, element, name, visual, tree) are already in `private static T? FindChildByName<T>(DependencyObject parent, string name) where T : FrameworkElement`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment platforms/windows/PortKiller/ViewModels/MainViewModel.cs:262— "Watched Port Notifications" repeats the code it sits on: 3 of its 3 words (watched, port, notifications) are already in `private void CheckWatchedPorts()`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
redundant comment platforms/windows/PortKiller/ViewModels/TunnelViewModel.cs:93— "Check if tunnel already exists for this port" repeats the code it sits on: 4 of its 5 words (check, tunnel, exists, port) are already in `var existingTunnel = Tunnels.FirstOrDefault(t => t.Port == port && t.Status != TunnelStatus.Error);`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
Silent fallback default in catch platforms/windows/PortKiller/Services/PortScannerService.cs:200— `ScanPortsAsync` swallows every exception into `return new List<PortInfo>();` — a data error becomes a silent behavior change with no trail. Log the failure or let validation throw.
Silent fallback default in catch platforms/windows/PortKiller/Services/PortScannerService.cs:345— `GetProcessInfo` swallows every exception and sets `user = Environment.UserName;` — a data error becomes a silent behavior change with no trail. Log the failure or let validation throw.
Silent fallback default in catch platforms/windows/PortKiller/Services/ProcessKillerService.cs:43— `KillProcessAsync` swallows `ArgumentException` into `return false;` — a data error becomes a silent behavior change with no trail. Log the failure or let validation throw.
Silent fallback default in catch platforms/windows/PortKiller/Services/ProcessKillerService.cs:89— `KillProcessGracefullyAsync` swallows `ArgumentException` into `return false;` — a data error becomes a silent behavior change with no trail. Log the failure or let validation throw.
Silent fallback default in catch platforms/windows/PortKiller/Services/ProcessKillerService.cs:131— `ProcessExists` swallows every exception into `return false;` — a data error becomes a silent behavior change with no trail. Log the failure or let validation throw.
Silent fallback default in catch platforms/macos/Sources/Services/CloudflaredDiscoveryService.swift:92— `readCredentialsFiles` turns every thrown error into `[]` — a data error becomes a silent behavior change with no trail. Log the error or let it propagate (`throws`). If that constant is the correct answer rather than a stand-in for a value that could not be read, say so in a comment at the `catch`, `guard` or `??`, or in the doc comment, and the row stops firing.
Duplicated predicate platforms/macos/Sources/Views/MenuBar/MenuBarPortForwardRow.swift:13— `connection.portForwardStatus == .connecting || connection.proxyStatus == .connecting` appears character-identically in 4 files — platforms/macos/Sources/Views/MenuBar/MenuBarPortForwardRow.swift, platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionEditSection.swift, platforms/macos/Sources/Views/PortForwarder/PortForwardConnectionCard.swift, platforms/macos/Sources/Views/PortForwarder/TableComponents/PortForwarderTableRow.swift. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
Duplicated predicate platforms/macos/Sources/Views/MenuBar/MenuBarPortForwardRow.swift:9— `connection.portForwardStatus == .error || connection.proxyStatus == .error` appears character-identically in 4 files — platforms/macos/Sources/Views/MenuBar/MenuBarPortForwardRow.swift, platforms/macos/Sources/Views/PortForwarder/DetailPanel/ConnectionEditSection.swift, platforms/macos/Sources/Views/PortForwarder/PortForwardConnectionCard.swift, platforms/macos/Sources/Views/PortForwarder/TableComponents/PortForwarderTableRow.swift. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
No ADRs found platforms/windows/PortKiller/PortKiller.csproj:3— No ADRs found. No recognised ADR directory (`docs/adr/`, `docs/decisions/`, `adr/`, `docs/rfcs/`, an `ADR0001/` folder, or their siblings) exists anywhere in this tree. What was searched, so you can tell an empty log from a search that missed one: every directory under the tree (build output, dependencies and VCS metadata excepted), for a document that is either any non-index page inside a recognised ADR directory, whatever its name and however deeply nested (`docs/adr/use-postgres.md`, `docs/adr/2024/0001-x.md`); or a file anywhere whose name is ADR-shaped (`0001-use-postgres.md`, `adr-012-caching.md`); or, when neither turned anything up, a document carrying the decision-record signature (an "Architecture Decision Record" heading, or Status / Context / Decision / Consequences as section headings). A decision log that clears none of these — unnumbered files outside any recognised directory, without those headings — is not seen by this check and this row is then wrong. If that is your case, say so rather than renaming anything; otherwise, consider recording architectural decisions in `docs/adr/`. ADRs are expected here because `platforms/windows/PortKiller/PortKiller.csproj` makes this repository a deployable product (line 3).
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.
README/code drift platforms/windows/README.md:105— platforms/windows/README.md names .NET 8, but the projects target .NET 9. Checked without a model against the repository: its files and folders, the scripts and dependencies of every package.json, the projects, namespaces, package references and target frameworks of the .NET build, the SDK and Node pins, and the identifiers of every file that is not a document; the documents' own text never counts. A footprint generated at build time, read only by a platform, or living outside this repository is not seen, and this row is then wrong.
Logging is not universal — Only 2/3 runnable modules use logging (modules with no entry point or server are excluded — they are libraries a runnable module hosts). Silent: `.`.
No dependency-update automation platforms/windows/PortKiller/PortKiller.csproj:18— `platforms/windows/PortKiller/PortKiller.csproj` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`.
No release approval gate — The release 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 the release trigger points at is published to users unreviewed, so a mistagged or unverified commit ships and the only remedy is a follow-up release.
No changelog — No CHANGELOG/HISTORY/RELEASES file — what shipped when isn't easy to reconstruct for support or audit. (Versioning/tagging makes releases traceable, but a changelog records the what.)
Null-forgiving operator (`!`) suppressions override nullable warnings — ~0.1 `!` suppressions per 1k syntax nodes — 2 suppression(s) across the 14824 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. Many are correct: each is a claim the checker could not verify, and it is wrong only where the value can in fact be missing, so review the densest places first.
doc comments repeat the names platforms/windows/PortKiller/Services/TunnelService.cs:143— 0 of 3 documented parameters and 2 of 75 summaries in `PortKiller` only repeat the member or parameter name (e.g. "Stops a tunnel" for `StopTunnelAsync`). Delete the restating tags, or add what the name does not say.
Appendix B — Reproduction & audit trail
Every external tool invocation behind a deep-scan dimension — the tool, its captured version, the exact command, how many findings it yielded, and a link to the retained raw output. To reproduce any finding: check out the same commit and run the command shown (repo-relative — never an absolute scratch path). The complete raw scanner output is retained verbatim under artifacts/raw/ (indexed in artifacts/raw/index.json); per-invocation exit codes and wall-clock durations are in sidecar.json — kept out of this table so the rendered report stays byte-identical across runs of the same commit.
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
trivy: not applicable — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.
semgrep: not applicable — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that. semgrep could not parse 3 file(s) — `platforms/macos/Sources/Managers/NamedTunnelManager.swift`, `platforms/macos/Sources/Services/PortForwardOutputParser.swift`, `platforms/macos/Sources/Views/Settings/ShortcutsSection.swift` — so the PII/GDPR sweep did not cover the unparsed regions of them; rows reported elsewhere in those files are real.
disclosure: not applicable — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.
runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
Run 01a1dc09-6f3a-794f-9f37-4ccbe61d2c7a · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.
Issues: 47 · Warnings: 157 · Recommendations: 27 · Info: 1 — Appendix A · all findings · full markdown report.
Generated by the Canine Code Analyzer: deterministic code-health analysis. 14-11-2026 @ 21:49 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.