Public report — Transmission, published 1 Oct 2026.
Concrete security findings (which rule fired, in which file, on which line; CVE IDs, secret matches,
dependency versions) are REDACTED in this version; ask the repo owner for the full report.
Public
Codebase surveyMeasured under the Code Assurance Index · rubric rubric-2026.09.18 (frozen) · verify this surveyFiledcd_6c05587ff11344cda3a18ea147d67ecb
Filed 1 October 2026, 13:43 UTC
Public
Medium · 31,116 LoC · 1 projects · rebuild ~0.2 person-years · weakest lens: Readiness (36%)
Findings by grade
4 critical304 serious9 minor44 could not be resolved — could be critical — see Limitations
This survey was produced by
Watchdog
Producer
Canine Development
Analyzer
Watchdog engine 1.0.0
Measured
1 October 2026, 13:35 UTC
A measurement, not a certificate. The Code Assurance Index does not certify,
approve or guarantee this codebase; it records a reproducible number and the evidence it was computed from. The
standard is authored by Canine Development, who also build Watchdog — its only implementation today. That is said
here so the number is checked rather than believed.
Grounded in facts. Every number here is computed, not narrated — reproducible, tool-backed, and traceable to a line of code. How to trust this ▸
304findings with an exact file:lineof 317 — the remainder are repo-wide signals (a dimension-level measurement, not a single line); open any file:line and verify
31/120dimensions across the health lenses31116 LoC · 1 projects — wide & deep
Band capped at Weak: the weakest category (Testing, 0%) reads Critical — the cover never out-promises the category table.
The system holds a moderate overall standing of 52%, indicating a workable asset that carries significant operational risk. While the underlying code structure is sound, the lack of operational safeguards creates a fragile environment for delivery. The system is medium-sized, with a rebuild cost of approximately €30,000, representing a manageable but non-trivial investment. The true value at stake lies in the speed and reliability of changes, not just the static code.
The most critical issue is operational fragility. With a readiness score of 36%, the system lacks the testing and observability needed to ensure safe deployments. This exposes the business to higher defect rates and potential outages, directly impacting customer trust and support costs. The absence of automated tests means every change is a manual gamble, increasing the likelihood of regression errors that could disrupt service.
A second theme is the velocity tax on every change. Code quality signals suggest a 4–8% efficiency drag on all modifications. This hidden cost compounds over time, slowing down feature delivery and increasing engineering hours for routine updates. While the architecture is strong, this inefficiency drains resources that could otherwise be spent on innovation or addressing technical debt.
On the positive side, the codebase is clean and well-structured, with no boilerplate or complex logic issues. The security posture is strong, with no confirmed vulnerabilities. This solid foundation makes remediation straightforward and cost-effective. The system is not broken; it is simply under-protected and inefficient.
Focus first on implementing automated tests. This single action offers the highest leverage, paying for itself within months by reducing the annual drag on engineering productivity. It addresses the root cause of operational risk and unlocks faster, safer delivery. Without this step, other improvements will yield diminishing returns. The picture is partial, as some areas like domain modeling were not measured, but the current risks are clear and actionable.
How the score is built — each lens's share of the headlineWidth is the lens's weight in the worst-heaviest fold (the weakest area pulls hardest); colour is that lens's own band. A lens fixes the score in proportion to its width.
D22 · Semantic duplication with inconsistent naming. `DestinationCoordinator` uses 'pop' (navigation stack terminology) while `PresentationCoordinator` uses 'dismiss' (modal terminology). However, both classes expose identical method signatures (`pop/dismiss`, `popToRoot/dismissToRoot`, `popToView/dismissToView`) and likely share the same underlying implementation logic for stack manipulation. This forces developers to learn two different verb sets for the same conceptual action (removing items from a presentation stack).
D22 · Redundant types with overlapping intent. `DestinationLink`, `PresentationLink`, `MenuDialogLink`, and `ContextMenuLink` all serve as SwiftUI views that trigger a presentation action. They share nearly identical constructor signatures (transition, animation, isPresented/value bindings, destination/content, label). The distinction between 'Destination' (navigation), 'Presentation' (modal), and 'MenuDialog' (alert/action sheet) is often implementation detail rather than API surface difference, leading to API sprawl where users must choose the correct 'Link' type for the specific UIKit container, despite the SwiftUI usage pattern being identical.
D22 · Redundant Modifier types. Similar to the Link types, there are distinct Modifier types for every presentation style (`DestinationLinkModifier`, `PresentationLinkModifier`, etc.). They all wrap a view and add presentation logic. This violates the DRY principle and creates maintenance overhead. A user wanting to add a modal presentation to a view must find the specific `PresentationLinkModifier` rather than using a generic `presentation` modifier.
A full-fidelity diff against the previous run's complete recorded findings — line-move tolerant: a finding that only shifted line counts as unchanged, only genuinely new titles/files surface here.
0.7× (at 52% quality) — the last 20% of quality is most of the work
Size & shape
Medium · effort split not classified (source measured from disk; the effort-tier breakdown is a C#-only syntax walk)
This codebase represents roughly ~0.2 person-years of build effort (about ~€30,000 to rebuild). Its weakest lens is Readiness at 36% — the part of that asset most exposed by the findings below.
How we model this: boilerplate at a scaffolding rate + logic × domain Standard (×1.0) — standard service × a 0.7× quality factor, at €60–95/h; indicative, ±~30% · size measured directly from source · effort from total production LoC as straight-line logic (the tier split is a C#-only syntax walk), a conservative lower bound. Indicative only — most sensitive to the hourly rate and the domain tier (both tunable in config).
Top priorities
The highest-leverage moves; the full ranked list is in the Roadmap below.
1
Resolve the 1 No automated tests finding(s) in Code Coverage.
Value concentrated against a weak lens · High · Value at risk
This is a Medium asset (~0.2 person-years to rebuild), and its weakest lens is Readiness at 36%. The operational and business risk on an asset this size concentrates there — that's where remediation buys the most protection.
→ Direct remediation budget at Readiness first — highest risk-reduction per euro on an asset this size.
The top fix pays for itself · High · Economics
The top-ranked fix costs roughly 1–3 engineer-days once. Not doing it costs about 5.5–33.1 engineer-days every year, paid as drag on the ~61,462 lines this team changes annually — a bill that arrives whether or not anyone books it. On those figures the fix breaks even in roughly 1–7 months and is free after that. Method, stated so this is not read as a quotation: debt from the ranked task's effort band; interest = annual changed lines (measured, annualised from the 90-day window) ÷ an ASSUMED 150–400 lines per engineer-day × the 4–8% drag implied by the code-quality signals; breaking point = debt ÷ annual interest. A modelled planning range built from measured inputs and one named assumption — not a quotation, a valuation, or a certified figure.
Evidence: D15 churn: 15,155 line(s) changed over a 90-day window ⇒ ~61,462/year · D1/D2/D4/D6 code quality: averaging 6.6/10 ⇒ a 4–8% drag on each change · top-ranked remediation: Low effort ⇒ about 1–3 engineer-day(s)
→ Do the top-ranked fix now if this code will still be yours in 7 months.
Highest-leverage move · Medium · Leverage
Of everything flagged, the best return on effort is: Resolve the 1 No automated tests finding(s) in Code Coverage. The rest can wait behind it.
Evidence: priority ranking: top of 5 ranked by impact/effort
→ Resolve the 1 No automated tests finding(s) in Code Coverage.
A velocity tax on every change · Medium · Economics
The code-quality signals (complexity, duplication, cohesion) average 6.6/10, which acts as a tax on every change in the weaker areas: modifications there plausibly cost on the order of 4–8% more than in clean code, and the tax compounds as the codebase grows. (A modelled estimate, not a measured fact.)
Evidence: D1/D2/D4/D6 code quality: averaging 6.6/10 across the code-quality signals actually measured
→ Pay it down where churn is highest — the hotspots — not everywhere; that's where the tax is actually paid.
Architecture — module dependency matrix
Rows and columns are the same modules, ordered so that a module only depends on ones above it. A cell means the row depends on the column, and its number is how many type pairs create that dependency. Read one thing: is anything above the diagonal? A mark there is a dependency cycle. (A cycle is all this shows — an unusual but cycle-free dependency sits below the diagonal like any other.)
2 modules, 2 dependencies. 1 dependency cycle across 2 modules, marked above the diagonal.
Module dependency matrix. The row depends on the column; the number is how many type pairs create the dependency. A cell above the diagonal is part of a dependency cycle.
Findings mapped to OWASP categories; the specific CVEs/secrets are in the Security dimension cards below and findings.md (redacted only on the public version of this report).
OWASP category
Findings
Severity
A03:2021 — Injection
2
High / Critical
Roadmap
First, address the single gaps in automated testing by resolving the missing code coverage and test distribution findings. Next, establish a changelog to track release contents and create architecture decision records to document significant design choices and their consequences. Finally, ensure the test suite runs explicitly in CI and gate merges on its success to maintain release hygiene.
Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.
Do this
Helps
Effort
Dimension
Resolve the 1 No automated tests finding(s) in Code Coverage.
Record significant decisions one document per decision — dated, stating the context, the decision and its consequences — and keep them together wherever your design docs already live (a conventional `docs/adr/` tree, with each file named `NNNN-title` in whatever markup those docs already use, is the most discoverable form).
Start a test surface where your build system looks for one (tests/, test/, spec/, or your ecosystem's test source set) — the separation follows from putting the first tests in the right place.
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 — 4
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 — 304
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 — 9
Recorded, with no effect on how the codebase functions.
Present so the survey is complete, not because it needs doing.
Could not be resolved — 44
Something this survey could not settle
from the outside, and which could be critical or serious. Either a control was required and no
positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves
nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean
result. These are excluded from the score rather than awarded a pass, so the number on the cover neither
rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each
one is named under Limitations.
Methodology & how to trust this report
Watchdog is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. 26 of 31 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); 5 documentation/naming judgement(s) are LLM-assisted and labelled advisory. Overall confidence is 0.8 — the weighted average across measured dimensions; it falls as more of the score leans on LLM-assisted judgement and rises when it's fully tool-backed.
Every figure here is one of three kinds, and we label which: ✓ Measured — a deterministic fact (LoC, complexity, coverage); ~ Modeled — an estimate from a stated model (cost, effort, value-at-risk), always a range with its assumptions, never a precise fact; ◐ Advisory — an LLM prose judgement. We never present a modelled estimate as if it were measured. Perfect or absent scores carry their provenance too (ADR-0011): ✓ Tool-verified means the property itself was measured across the surface; ○ Nothing flagged means the probes came back clean — a claim bounded by what a repository can show; ⊘ Not evidenced means a working control (a tested restore, an automated rollback) showed no positive evidence — absence of evidence is not evidence of a control, so it's excluded from the score rather than awarded a spurious 10; ◐ Sampled · advisory marks an LLM verdict over a bounded sample — advisory, never a deterministic measurement.
What we checked — 31 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, 304 of 317 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line. (Every path in this report is repo-relative by construction: paths are normalized at the producer and the report is rejected if any rooted path leaks through.)
Is there a tool behind the number? Every score below names the method that produced it — Roslyn, git, a scanner, or (for a handful of documentation/naming dimensions) an LLM labelled sampled · advisory — not a narrative.
Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.
This report answers yes to all three. That's the bar to hold any assessment to.
Tools & methods
The actual versions used this run (captured at analysis time) — re-run on the same commit for the identical score.
Method
Backs
Version
Evaluator
Roslyn static analysis
Complexity, cohesion, coupling, dead code, API surface, layering
What ran differently this time — a tool absent, degraded, or that fell back to an estimate. Named openly, not folded silently into the scores. A degraded run also records its exact cause in diagnostics.md.
D12 Dependency Hygiene — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Not scored — 1 SwiftPM declaration(s) across 1 `Package.swift` and 0 committed pin(s) were read for PINNING discipline (0 defect(s) reported), but the outdated signal comes from listing each declared repository's release tags rather than from a registry, and none of them resolved to a version to compare, so this dimension's own question is only partly answered. NOT a finding that these dependencies are current or healthy.
D14 License Compliance — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Not scored — none of the 1 package(s) this repository's SwiftPM files bring in could be read at a pinned revision or is a repository the public index (api.deps.dev) knows, so no licence could be read for any of them: they are private, self-hosted, or unpinned and too little-referenced to be indexed. NOT a finding that this repository's licences are compliant: this dimension asserts nothing about its licensing in either direction.
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 (3 contributor(s) across 220 commit(s) sampled, automation and bot accounts excluded). One of them holds 97% of the history; the other 2 hold 1.5% 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.
D32 Data Compliance (PII/GDPR) — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. `Example/Example/DestinationLinkExamples.swift`, `Example/Example/PresentationLinkExamples.swift`, `Example/Example/QuickLookPreviewLinkExamples.swift`, `Example/Example/ShareSheetLinkExamples.swift`, `Example/Example/StatusBarAppearanceExamples.swift`, … (+18 more) produced a parse error, so every rule in this engine's `gdpr.yml` was absent there. That absence is NOT a clean result: these rules detect personal data crossing a boundary into a log sink, a URL or browser storage, and a file that was never parsed cannot report any of the three. The rest of the tree analysed normally and its rows above stand; only these files are unaccounted for. You can widen what we reach: fix the syntax error (or exclude the file deliberately) and re-scan to cover it.
D44 Platform End-of-Life — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This dimension reads a project's own statement about the platform it runs on: a TargetFramework in a .NET project file, a .nvmrc or .python-version, a capped requires-python, a Rust toolchain file or Cargo.toml rust-version, a .go-version, .java-version, .ruby-version, .tool-versions or .sdkmanrc, a go.mod go directive, a Maven or Gradle Java level or toolchain, a Gemfile's ruby directive, a mix.exs elixir requirement, a rebar.config minimum_otp_vsn, a pubspec.yaml SDK constraint, a build.sbt scalaVersion, or a framework major pinned by a dependency constraint. This repository carries none of them, so nothing about its platform was established. That is a gap in this analyzer's coverage, NOT a finding that the platform is supported — a language whose runtime is declared elsewhere (Package.swift, a Dockerfile) is simply not read here yet.
AX6 Interface segregation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is computed over the public interfaces this run's compilations declare, and none was loaded, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
AXB1 Runtime evidence locked — no reproducible boot — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Subject: a native UI project (Example/Example.xcodeproj/project.pbxproj). The Runtime Evidence tier boots an app only via docker-compose, an Aspire AppHost, a Dockerfile, or an npm dev script. None was found, 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. Watchdog then boots it in an isolated sandbox and gathers real runtime evidence — you change nothing in your pipeline (no CI step, no SDK).
C1 Data Protection — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These personal data controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks personal data controls.
C2 Access Controls — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These authorization controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks authorization controls.
C3 Audit Trail — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These audit controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks audit controls.
C4 Data Retention — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These retention controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks retention controls.
C5 Data-Subject Rights — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These data-subject rights controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks data-subject rights controls.
ED5 Idempotency — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check finds retry-prone mutations by walking the repository's declared types, and NONE was loaded on this run, so it had nothing to look at. That is a limit of the analyzer's reach — it reads .NET projects — not a finding that this repository has no command handlers or message consumers.
GD1 Unfinished & placeholder code — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
IC1 Incompleteness & stubs — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
P1 CI/CD gates — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. A CI pipeline exists and the word "test" appears, but no explicit test-runner invocation (your stack's test command, or a test job) was matched — so either the gate runs tests through a step this pass could not recognise, or "test" is incidental here (a path, "latest", a reporter). Which of the two it is cannot be settled from this dimension's evidence; the coverage dimensions report whether a suite exists at all. You can widen what we reach: name the test runner explicitly in the pipeline step (your stack's test command, or a job named for the suite) so the gate is unambiguous to a reader and to this pass.
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.
P8 Schema migrations — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads EF Core usage in C# and the schema tooling its file scan recognises only, and no .NET project was loaded, and this repository's language is not one the scan models, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
PF3 Async & latency hygiene — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Those languages colour their functions async, so blocking inside them is the same defect this card counts elsewhere, but their blocking vocabulary is not modelled yet. That is a gap in this analyzer's language reach — not a finding that the code is free of it.
S1 Web-Security Posture — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. These web-security controls are read from declarative annotations, request middleware, entity/column names and guard methods in a C# source model, and none was loaded on this run, so there was nothing to gather. That is a gap in this analyzer's language reach — not a finding that the repository lacks web-security controls.
X1 Async correctness — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X12 Unreachable branch — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X13 Undrained process stream — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X14 Bypassable address classification — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X15 Unvalidated length from an untrusted reader — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X16 Unfloored truncation loop — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X17 Uncapped recursion over a caller-supplied document — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X18 Disposal-pattern correctness — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X19 Unrestored process-global state — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X2 Cancellation propagation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X20 Mistyped argument guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X21 Side-effecting pattern guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X22 Contradicted release guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X23 Unguarded diagnostic materialisation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X24 Document value interpolated into markup unescaped — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript and Java source only, and no C# was loaded and no JavaScript/TypeScript or Java was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X25 Inert configuration knob — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript and Java source only, and no C# was loaded and no JavaScript/TypeScript or Java was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X26 Unsynchronised callback handoff — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and Java, Kotlin and Scala source only, and no C# was loaded, no Java, Kotlin or Scala was found, and this repository's Swift is not read yet, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X27 Collection changed while being enumerated — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and Java and Rust source only, and no C# was loaded and no Java or Rust was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X28 Index access outside its own emptiness guard — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and Scala source only, and no C# was loaded and no Scala was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X29 Per-element action decided by a fixed element — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java and Rust source only, and no C# was loaded and no JavaScript/TypeScript, Java or Rust was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X3 Exception handling — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X30 Support guard that admits what it rejects — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and Scala source only, and no C# was loaded and no Scala was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X4 Structured logging — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X5 Nullable reference types — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check is implemented over the C# syntax tree, and no C# was loaded on this run, so it had nothing to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X6 Hand-rolled structured-format parsing — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and Python, JavaScript/TypeScript, Go, Java/Kotlin/Scala, Ruby, PHP and Rust source only, and no C# was loaded and none of those languages was found in this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
X7 Silent fallback defaults — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C#, Python, TypeScript/JavaScript, Rust, Go, Java and Kotlin syntax only, and no C#, Python, TypeScript/JavaScript, Rust, Go, Java or Kotlin was loaded for this repository, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
Repo exclusion declarations (.gitattributes linguist-generated/vendored, .editorconfig generated_code): none declared — every source file was scored.
Limitations & what we did not check
Watchdog assesses the repository exactly as committed, and only the repository. By design it does not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.
Per-dimension blind spots
For each dimension that was measured, what a static, repo-only scan structurally cannot see — the honest edge of the measurement, not a failure of it.
D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
D8 Code Coverage: Coverage is measured by building and running the test suite inside Watchdog's isolated image — the target repo is never modified, and nothing on your systems runs. So coverage exists only when the suite builds and runs within the inline time budget; one that needs external services, can't build, or exceeds the budget yields no coverage (D8 then degrades to not-measured, not a low score). Line coverage also says nothing about assertion quality.
D9 Test Distribution: The test-pyramid shape is inferred from project/folder naming and references, with a single test host bucketed per-file by its path tier and content signals — a suite that names tiers unconventionally and gives no per-file signal can still be mis-bucketed.
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").
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 is judged by an LLM over a bounded sample of docs — it reads what is written, not whether the docs match the running system, and it is advisory, not a measurement. Its critique rows are drawn from a closed category vocabulary and each row means the same thing in every run, so two scans can be compared row by row; the SET that fires is still a sample, and does not repeat exactly. Measured on one frozen input, six scans at one engine SHA: 2-5 critique rows per scan, 8 distinct rows across the six, 3 of those 8 seen in only one scan. So a D19 row is evidence about the documentation, but a COUNT of D19 rows is not a quantity — never read a change in it as an improvement or a regression.
D21 Naming Consistency: Naming quality is an LLM judgement over a bounded sample — it assesses clarity/consistency of the names it sees, not domain-correctness, and is advisory.
D22 Internal API Consistency: API-surface coherence is an LLM judgement over a sample of the public surface — consistency of intent across the whole API is approximated, not exhaustively verified.
D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
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.
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: Onboarding quality is an LLM read of the docs/setup present — it cannot run the onboarding or measure how long a real new joiner takes; the verdict is sampled and advisory.
P6 Release Hygiene: Rollback/observability controls are inferred from repo artefacts (pipelines, dashboards-as-code) — controls configured in external tooling, with no in-repo trace, cannot be credited.
The LLM boundary
LLM-set scores this run (5): D19, D21, D22, D26, M4 (model: Local LLM). For these, a model reads a bounded sample and sets the numeric score; each names its own sample and method on its card. They are sampled and advisory by design: they vary at the margins between runs and are never a deterministic measurement. Every other score in this report is tool-computed at confidence 1.0.
What it measures: How tangled the control flow is — methods with many branches are hard to test and change.
Method: Cyclomatic complexity per method (1 + decision points), computed exhaustively across production source; test projects separated by convention. Deterministic.
+ 29 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 1 InteractivePresentationController.onPanGesture (cyclomatic 104) finding(s) in Cyclomatic Complexity — start with InteractivePresentationController.swift. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 MatchedGeometryViewControllerTransitionAnimator.animateTransition… finding(s) in Cyclomatic Complexity — start with MatchedGeometryViewControllerTransition.swift. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 DestinationLinkDelegateProxy.panGestureDidChange (cyclomatic 71) finding(s) in Cyclomatic Complexity — start with DestinationLinkAdapter.swift. — One of this dimension's main actionable groups (1 warning-level).
Enforce Cyclomatic Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
Detailed fixes: d1_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: How hard the code is for a person to follow, beyond raw branching.
Method: Cognitive complexity per method (Sonar-style nesting-penalized score), computed exhaustively over production code, excluding test projects. Deterministic.
+ 51 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 1 InteractivePresentationController.onPanGesture (cognitive 235) finding(s) in Cognitive Complexity — start with InteractivePresentationController.swift. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 DestinationLinkDelegateProxy.panGestureDidChange (cognitive 180) finding(s) in Cognitive Complexity — start with DestinationLinkAdapter.swift. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 PresentationLinkCoordinatorAdapter.onUpdate (cognitive 158) finding(s) in Cognitive Complexity — start with PresentationLinkAdapter.swift. — One of this dimension's main actionable groups (1 warning-level).
Enforce Cognitive Complexity in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D3 · God Classes7.6 / 10Strong✓ Tool-verified
What it measures: Over-large classes that try to do too much ("god classes").
Method: God-class detection by line and method-count thresholds per logical type (partial classes unified), filtered for generated code and registration/contract false positives. Deterministic.
Resolve the 16 MethodTooLong finding(s) in God Classes — start with SheetPresentationLinkTransition.swift (2), PresentationLinkAdapter.swift (2), ContextMenuAccessoryView.swift (2). — One of this dimension's main actionable groups (16 warning-level).
Resolve the 9 FileTooLong finding(s) in God Classes — start with DestinationLinkAdapter.swift, PresentationLinkAdapter.swift, CornerRadiusOptions.swift. — One of this dimension's main actionable groups (9 warning-level).
Resolve the 5 ClassTooLong finding(s) in God Classes — start with DestinationLinkAdapter.swift (2), PresentationLinkAdapter.swift, InteractivePresentationController.swift. — One of this dimension's main actionable groups (5 warning-level).
Enforce God Classes in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Copy-pasted code that should be shared instead.
Method: Code duplication via token-stream sliding windows with type-aware normalization (locals masked, type names preserved), density-scored per KLoC of production code. Deterministic.
154 duplicated block group(s) detected. A further 7 rows report members as variants of one another; they aggregate block groups already counted above and are not themselves counted. 16 of the 161 are in trees this repository does not ship — vendored, example/demo, fixture and benchmark code — and are ranked below the shipped groups rather than excluded from them: the duplication there is real and is still counted in this dimension's score. The dimensions that publish a production-file census leave those trees out of theirs, so this count is deliberately drawn over the wider population.
+ 57 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 16 Duplicated block (15 lines × 2) finding(s) in Code Duplication — start with DestinationLink.swift (5), DestinationLinkAdapter.swift (2), DestinationSourceViewLink.swift (2). — One of this dimension's main actionable groups (16 warning-level).
Resolve the 13 Duplicated block (9 lines × 2) finding(s) in Code Duplication — start with MenuLink.swift (4), MenuDialogLink.swift, PresentationLinkAdapter.swift. — One of this dimension's main actionable groups (13 warning-level).
Resolve the 12 Duplicated block (11 lines × 2) finding(s) in Code Duplication — start with DestinationLinkModifier.swift (4), DestinationLinkExamples.swift (2), ContextMenuLinkAdapter.swift. — One of this dimension's main actionable groups (12 warning-level).
Enforce Code Duplication in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.
Detailed fixes: d4_recommendation.md · top locations in Appendix A, every location in findings.md.
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 7 Low cohesion finding(s) in Cohesion (LCOM4) — start with StatusBarModifier.swift, DestinationLinkAdapter.swift, ContextMenuAccessoryView.swift. — One of this dimension's main actionable groups (7 warning-level).
Enforce Cohesion (LCOM4) in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.
Detailed fixes: d6_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D8 · Code Coverage0.0 / 10Critical✓ Tool-verified
What it measures: How much of the code is actually exercised by tests.
Method: Coverage from coverlet runs or committed reports (Cobertura/OpenCover/lcov), computed per-file with structured exclusions for generated, trivial, and glue code. When the suite can't be built/run in-image AND no report is committed, coverage is reported NOT-MEASURED (excluded from the score) with the precondition to make it measurable — never a LoC-ratio proxy folded in as if measured. Deterministic.
No automated tests — no test code was found in this repository.
No automated tests
What to do
Resolve the 1 No automated tests finding(s) in Code Coverage. — One of this dimension's main actionable groups (1 issue-level).
Enforce Code Coverage in CI to reach Verified (currently Documented). — Hardens enforcement from Documented toward Verified — provenance only; does not change the score.
Detailed fixes: d8_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D9 · Test Distribution0.0 / 10Critical✓ Tool-verified
What it measures: Whether the test suite has a healthy mix of unit / integration / end-to-end tests.
Method: Test projects classified (Unit/Integration/BDD/E2E) from compiled metadata; test methods counted exhaustively across projects with placement-agnostic disk fallback. Deterministic.
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: Files that change often and are also complex — the riskiest hotspots.
Method: Per production file churn times cyclomatic complexity over a rolling window, computed from git and Roslyn/JS/Razor analysis. Exhaustive, deterministic per commit date.
Resolve the 10 Hotspot finding(s) in Churn × Complexity Hotspots — start with PresentationLinkAdapter.swift, DestinationLinkAdapter.swift, InteractivePresentationController.swift. — One of this dimension's main actionable groups (10 warning-level).
Detailed fixes: d15_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Acknowledged debt left in the code — TODOs, dead code, suppressed warnings.
Method: Roslyn syntactic debt markers (suppressions/TODO/FIXME/HACK/empty-catch/commented-code/Obsolete) plus SymbolFinder dead-code analysis; weighted-debt-per-KLoC density deducted 2.0x per unit. Deterministic, exhaustive.
0 deducted task-comment markers across 31116 LoC (0.0/KLoC) → score 10.0. Task comments only: this repository's language is read without a compiler, so D17's suppression, dead-code and commented-out-code arms did not run and this score counts fewer marker kinds than a .NET repository's would.
What it measures: Whether the project's documentation is clear, complete, and useful.
Method: Judged by language model at low temperature (0.0-0.1) on a deterministic doc sample (READMEs plus first 25 architecture docs), with two-pass stability filtering. Advisory, sampled.
The repository's root README is a well-written overview of the Transmission project: it states what Transmission does (bridging UIKit presentation APIs to SwiftUI), links to supporting libraries (Engine, Turbocharger, Metallic, Ignition), shows an iOS/macOS/watchOS/visionOS deployment target range, and gives installation instructions for both Swift Package Manager and Xcode projects. It also includes a Preview link and an 'Introduction to Transmission' section with sample code. The document is rich in content but the body ends in a clipped marker ('public static let slide: PresentationLinkTransitio') before the outline sections (e.g. TransitionReader, DestinationLink) are named; these must be assumed present rather than flagged as missing.
Documentation: no architecture or design documentationREADME.md
What to do
Resolve the 1 Documentation finding(s) in Documentation Quality — start with README.md. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d19_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether names — types, methods, variables — are clear and consistent.
Method: Judged by language model at low temperature (0.0-0.1) on a deterministic random symbol sample (fixed size, not exhaustive), with disclosed confidence band. Advisory, sampled.
0 naming inconsistencies across 0 sampled symbols.
✓ On the Gold path — maintain.
Detailed fixes: d21_recommendation.md.
Do you agree with this assessment?
D22 · Internal API ConsistencyWeak◐ Sampled · advisory
What it measures: Whether the internal API surface is consistent and coherent.
Method: Judged by language model at low temperature over a sample of the public API surface (IsPackable or .Contracts types). Sampled, advisory; confidence discounted by model uncertainty.
3 API inconsistencies across a 400-member sample of 204 exposed types.
Semantic duplication with inconsistent naming. `DestinationCoordinator` uses 'pop' (navigation stack terminology) while `PresentationCoordinator` uses 'dismiss' (modal terminology). However, both classes expose identical method signatures (`pop/dismiss`, `popToRoot/dismissToRoot`, `popToView/dismissToView`) and likely share the same underlying implementation logic for stack manipulation. This forces developers to learn two different verb sets for the same conceptual action (removing items from a presentation stack).
Redundant types with overlapping intent. `DestinationLink`, `PresentationLink`, `MenuDialogLink`, and `ContextMenuLink` all serve as SwiftUI views that trigger a presentation action. They share nearly identical constructor signatures (transition, animation, isPresented/value bindings, destination/content, label). The distinction between 'Destination' (navigation), 'Presentation' (modal), and 'MenuDialog' (alert/action sheet) is often implementation detail rather than API surface difference, leading to API sprawl where users must choose the correct 'Link' type for the specific UIKit container, despite the SwiftUI usage pattern being identical.
Redundant Modifier types. Similar to the Link types, there are distinct Modifier types for every presentation style (`DestinationLinkModifier`, `PresentationLinkModifier`, etc.). They all wrap a view and add presentation logic. This violates the DRY principle and creates maintenance overhead. A user wanting to add a modal presentation to a view must find the specific `PresentationLinkModifier` rather than using a generic `presentation` modifier.
What to do
Resolve the 1 Semantic duplication with inconsistent naming. `DestinationCoordinator`… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 Redundant types with overlapping intent. `DestinationLink`,… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 Redundant Modifier types. Similar to the Link types, there are distinct… finding(s) in Internal API Consistency. — One of this dimension's main actionable groups (1 warning-level).
Detailed fixes: d22_recommendation.md · top locations in Appendix A, every location in findings.md.
1 of 1 build units (SwiftPM) flagged as possibly oversized/incoherent.
Projects may be oversized for their cohesion
What to do
Resolve the 1 Projects may be oversized for their cohesion finding(s) in Project Cohesion. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d26_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: 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).
2 finding(s): 0 critical, 2 high, 0 medium, 0 low. 2 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.
REDACTED
What to do
No action in Static Analysis (SAST) — all 2 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 (2 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 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 91 of the 135 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.
Other · Architecture — How the codebase splits by code ROLE — domain, application, infrastructure, test, generated. The significance map behind the knowledge/coupling weighting, and a DDD signal in its own right: a thin domain core under fat infrastructure is the anemic-domain smell, quantified. How each file's role is decided, because the split is only as good as that: a generated name or a build-output tree makes it Generated, a test project makes it Test, and otherwise the file's NAMESPACE and PATH words are matched against fixed vocabularies in a fixed ORDER — domain, then infrastructure, then application — so a file whose words hit two layers is counted under the earlier one. A production file matching none of them counts as application, so that share reads 'application or unclassified' rather than a measured application layer. Roles come from naming convention, never from what the code does. On this repository the split was taken from the source tree on disk rather than from a loaded .NET workspace, so a file's role is decided by its PATH segments alone — no declared namespace was available to add to the evidence — and generated output is excluded from the census entirely rather than counted as a generated share.
Method: Roslyn line-count by code ROLE: every source file classified Domain/Application/Infrastructure/Test/Generated by namespace + path convention (the shared CodeRoleClassifier), then significant lines summed per role. Deterministic; the advisory score is the business-logic (domain+application) share of production code.
Coverage: Population: ALL source files, each bucketed into ONE of five roles (Domain/Application/Infrastructure/Test/Generated) by namespace + path convention — a file whose layer isn't named in the convention falls to Application (the neutral default), and the split is line-count, not semantic depth or business value.
What to do
The domain core is a small share of production code, but most of the rest matched no layer vocabulary at all — so this is not yet an anemic-domain finding. The namespace/path convention could not place that code, which makes the composition above a statement about the naming, not about the design. Name the layers (or check that the repository's conventions differ from the ones this check knows) before reading a thin domain into it.
Other · Architecture — Whether the project-reference graph is acyclic (cycles block independent build/deploy and signal eroding boundaries).
Method: Project reference cycles via elementary-DFS over real .csproj references, using the engine shared with D5/D7; cyclic versus acyclic. Exhaustive, deterministic.
Other · Architecture — Whether dependencies point inward (Domain ← Application ← Infrastructure/Web) — the clean-architecture dependency rule, checked across the project graph.
Method: Layer violations by name-segment inference (Domain/Core to Application to Infrastructure/Web) over the project-reference graph. Exhaustive over all projects, deterministic.
Other · Architecture — Whether read (query) handlers stay side-effect-free — a query that writes persistent state or raises events breaks CQS and makes reads unsafe to retry, cache, or route to a read replica.
Method: Roslyn scan: CQRS handlers classified query-vs-command by interface (IQueryHandler/ICommandHandler/IRequestHandler<TQuery,TResult>) and name convention (*Query/Get*/Find* vs *Command); each query handler's body checked for persistent-state writes (SaveChanges/repository Add-Update) or event publishes by resolved invocation. Deterministic, type-level, exhaustive over the detected handlers.
Coverage: Population: CQRS handlers identified by IQueryHandler/ICommandHandler/IRequestHandler interface + *Query/Get*/Find*/*Command NAME convention; query purity then checked exhaustively within that set — a query handler using neither convention is invisible, and mutation is a resolved persistence/publish CALL, not full dataflow.
Other · Event-Driven — Whether state changes and message publishes are atomic (a transactional outbox) rather than a crash-unsafe dual write.
Method: Roslyn semantic scan (event-driven gated): event-handler methods scanned for DB-save plus bus-publish without a transactional outbox reference. Deterministic, semantic-resolved.
`ContextMenuLinkCoordinator.onUpdate` performs two independent DURABLE writes — `adapter` (a persistence store) via `update` and `interaction` (a persistence store) via `update` — in one command path with no shared transaction or outbox. A crash between the two leaves the stores diverged (one write committed, the other lost) or emits a phantom record. Wrap both in one transaction, or record the second write in the same store and dispatch it afterwards (a transactional outbox). — Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:249
What to do
Adopt the transactional outbox pattern so DB writes and message publishes commit atomically — no lost or phantom events on a crash.
Maturity · Maturity — Whether the repo and its projects have a README, and whether it's substantive and current.
Method: Filesystem scan: README presence, word count, and headings for depth; git history for staleness. Exhaustive across root and project dirs, deterministic.
What to do
Add a 'Testing' section to the root README — how to run the test suite.
Add an 'Architecture' / 'How it works' section to the root README — the high-level shape.
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.
No C4/Structurizr/PlantUML/Mermaid/Graphviz/D2 diagram, no drawn diagram named for the architecture, no file named `architecture` or `design` in any markup this check reads, and nothing in the README, docs or contributor guides that announces the shape — no `## Architecture` heading, no "architecture overview"/"high-level design" phrasing, no "the architecture is …" introduction, no guided code tour. A shape laid out in prose that never names itself as the architecture is not visible to this check, and neither is one kept outside the repository, so this row reports the absence of a re-findable shape document — not evidence that nobody wrote the shape down.
What to do
Record significant decisions one document per decision — dated, stating the context, the decision and its consequences — and keep them together wherever your design docs already live (a conventional `docs/adr/` tree, with each file named `NNNN-title` in whatever markup those docs already use, is the most discoverable form).
Add a C4 context/container diagram (Structurizr, PlantUML or Mermaid) or an architecture.md overview.
Maturity · Maturity — Whether the repo is organised deliberately — src/test separation and consistent project naming.
Method: Filesystem scan: src/test folder separation and namespace-prefix consistency (majority RootNamespace agreement). Exhaustive across projects, deterministic.
What to do
Start a test surface where your build system looks for one (tests/, test/, spec/, or your ecosystem's test source set) — the separation follows from putting the first tests in the right place.
Maturity · Maturity — Whether the README actually describes the code that exists (LLM-judged, advisory).
Method: Judged by language model at low temperature: README accuracy versus actual projects, within a disclosed tolerance. Advisory, not a measured number.
README advertises Docker containerisation, but no Dockerfile/compose file exists — searched for: `dockerfile`, `docker-compose`, `compose.yaml`, `compose.yml`. Each was matched case- and separator-insensitively against file and directory NAMES anywhere in the tree, and against the CONTENTS of manifest files (package.json, *.csproj, *.props, *.slnx, *.yml, Dockerfile); the README's own prose never counts, so a claim is never refuted by merely being made. Nothing outside that search was read — a footprint living only in a submodule, in a file type not listed here, or under a name none of those terms matches is not seen, and this row is then wrong.
What to do
Reconcile the README with reality: README advertises Docker containerisation, but no Dockerfile/compose file exists.
Do you agree with this assessment?
P1 · CI/CD gates8.5 / 10Strong✓ Tool-verified
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.
What to do
Run the test suite in CI via an explicit runner step (`xcodebuild test` for the toolchain this pipeline already uses) and gate merges on it.
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 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.
Readiness · Readiness — Whether SAST, secret/dependency scanning and performance benchmarking are wired in (presence, not runtime).
Method: Filesystem scan: SAST configuration, dependency-update automation, secret scanning, and a benchmark harness or benchmark step — in this repository's own ecosystem. Exhaustive, deterministic.
No static application security testing detected. For this repository's stack, add CodeQL's Swift pack (Swift/Xcode) (or `semgrep --config=auto`, which runs on any language) as a CI step. What was searched, so you can tell an absence from a miss: the 2441 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
What to do
Add a SAST step to CI running what this repository's stack ships: CodeQL's Swift pack (Swift/Xcode) — or `semgrep --config=auto`, which runs on any language — so a security regression fails the build instead of landing.
Enable Dependabot/Renovate or a dependency-review gate.
Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
Readiness · Readiness — Whether releases are 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.
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.
Not evidenced — 5 control(s) we could not find positive evidence for
These checks grade a working control, and the repository shows no evidence of one. That is deliberately not scored as a zero: a repository cannot show an ops runbook, a database TTL or an infrastructure-side audit log, so absence of evidence here is not evidence the control is missing. It is also not a statement that the check is irrelevant to this codebase — the thing it grades applies; we just could not see it. Excluded from the score either way.
C3 Audit Trail — Not assessed: these audit controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks audit controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
C4 Data Retention — Not assessed: these retention controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks retention controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
C5 Data-Subject Rights — Not assessed: these data-subject rights controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks data-subject rights controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
P4 Deployment & Rollback — not evidenced — no deploy/rollback/approval signal in the repo; absence of evidence is not evidence of a manual release
P5 DR & Backup — not evidenced — repo shows no backup/RTO/RPO controls; absence of evidence is not evidence of a working control
Not included — 84 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.
AC7 A11y enforcement — No web markup found — accessibility is not applicable to this repository.
AX1 Captive dependencies — Not applicable: this repository's Swift imports no dependency-injection container and defines no container of its own — nothing that both registers and resolves bindings, and nothing that names two lifetimes — so nothing holds one lifetime's instance while handing out another's.
AX2 Stateful singletons — No container singleton was found, so there is no shared instance for concurrent requests to race on. No Swift request handler (a Vapor, Hummingbird, Kitura, Swifter or Perfect route handler, as a method or a registered closure) is declared, so no state is shared between request threads.
AX5 Architecture & structure — not assessed — architecture style/structure is computed from a project graph (projects, types, module namespaces) that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
AX6 Interface segregation — not assessed — interface segregation is computed over a type surface that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
AX7 Slice cohesion — not applicable — not a vertical-slice architecture
AX8 Test isolation — no test/production split to check
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 — Not assessed: these personal data controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks personal data controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
C2 Access Controls — Not assessed: these authorization controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks authorization controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
D10 Test Quality — No tests were found in the analyzed repository to assess for quality.
D11 Test Reliability — No test suite was found to re-run, so reliability couldn't be assessed. Two searches produced that zero and both came back empty: the classifier that reads the loaded workspace recognised no suite it could run, and a walk of the source on disk — which covers the JS/TS `*.test.*` and `*.spec.*` conventions and probes for a Pester suite — found no test source in any other ecosystem either. Neither search reaches a suite that is missing from the loaded workspace and carries no name either walk recognises, so this is 'no suite found by those two searches', not a verdict that the repository has none.
D12 Dependency Hygiene — Not scored — 1 SwiftPM declaration(s) across 1 `Package.swift` and 0 committed pin(s) were read for PINNING discipline (0 defect(s) reported), but the outdated signal comes from listing each declared repository's release tags rather than from a registry, and none of them resolved to a version to compare, so this dimension's own question is only partly answered. NOT a finding that these dependencies are current or healthy.
D14 License Compliance — SwiftPM package licences not graded — no dependency repository could be read
D16 Bus Factor — single-maintainer repository — bus factor is not applicable
D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
D20 ADR Quality — N/A — ADRs are expected on deployable products with a user-facing host, not consumed libraries; no ADR log is required here.
D23 Boundary Type-Coupling — No bounded-context organisation was detected either — neither a context-shaped layout nor 2+ sibling source directories each declaring an aggregate root. Declaring this codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
D24 Comment Value — No inline comments to assess — comment value is not applicable here.
D25 ADR Conformance — no ADRs to check
D27 Navigability — symbol resolution incomplete — navigability not assessed
D30 Dependency Vulnerabilities — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Swift Package.swift/Package.resolved — not scanned yet).
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) — 23 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
D36 Supply-chain Provenance & Signing — The CI pipeline builds and tests but publishes no released artifact — no package publish, container push, GitHub release or deployment step. Supply-chain provenance, signing and SBOM attest RELEASED artifacts, so there is nothing to attest here. Add them to the release pipeline when this repo starts shipping artifacts (a published package, a container image, a deployed service or a tagged release). Build integrity and workflow-token hygiene are reported below: they describe what the CI runs and the token it runs with, neither of which is affected by whether the pipeline ships an artifact.
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.
D39 IL Efficiency — D39 measures the IL emitted by a .NET build; this repository has no .NET solution or project files, so the dimension does not apply.
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.
D43 Malicious Dependencies — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Swift Package.swift/Package.resolved — not scanned yet).
D44 Platform End-of-Life — Platform end-of-life not assessed — this repository declares no platform this pass reads
D5 Coupling — Not applicable — this SwiftPM build ships 1 production module(s), so there is no coupling BETWEEN modules to measure. (Its test and non-production modules are not part of the shipped graph.)
D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
DM1 Domain Modelling — not scored — this repository shows 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
ED5 Idempotency — This check finds retry-prone mutations (command handlers and message/event consumers) by walking the repository's declared types, and none was loaded here, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
GD1 Unfinished & placeholder code — no source files were read — this check reads C# syntax, and none was loaded for this repository. That is a limit of the analyzer, not a finding about your code.
IC1 Incompleteness & stubs — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
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'.
P2 Observability — This repository's Swift source (1 module(s), 135 file(s) read) declares no entry point and bootstraps no server, and nothing here deploys a service — it is a library, run inside whatever hosts it, so production observability (structured logging, tracing/metrics, health checks) is N/A. If it grows a binary or a service, the dimension reactivates.
P7 Outbound HTTP resilience — not applicable — no HTTP server, API framework or worker entry point was found in the Swift source, so there is no service whose uptime a failing dependency could take down
P8 Schema migrations — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
P9 Domain vs controller coverage — no coverage report found on disk — produce a coverage report in a standard format (lcov — `swift test --enable-code-coverage` (SwiftPM) or `xcodebuild test -scheme <YourScheme> -enableCodeCoverage YES` (an .xcodeproj/.xcworkspace suite), then `xcrun llvm-cov export -format=lcov`) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures, or wire coverage collection into CI, to enable this cross-layer check
PF1 Benchmark discipline — Not applicable: no benchmark suite was found. This check searched for `Benchmark("…")` in a file importing package-benchmark, or package-benchmark in Package.swift, and for a `*benchmark*` script that this repository's CI runs. Benchmarks are credited as a bonus, so their absence is neither scored nor deducted.
PF2 Allocation hygiene — Not applicable: allocation awareness is rated where code engineers for it — at least 400 production lines that ship benchmarks or already use allocation-aware idioms (8 or more). This repository's Swift has 33,105 production line(s), 2 such use(s) and no benchmarks, so there is no allocation work to rate. The card is reward-only: its absence costs nothing.
PF3 Async & latency hygiene — Sync-over-async was not assessed: this repository's async code is written in Swift, whose blocking calls this check does not model yet. That is a gap in the analyzer's language reach, not a finding about your code.
S1 Web-Security Posture — Not assessed: these web-security controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks web-security controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
X1 Async correctness — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X10 Duplicated predicate — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
X12 Unreachable branch — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X13 Undrained process stream — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X14 Bypassable address classification — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X15 Unvalidated length from an untrusted reader — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X16 Unfloored truncation loop — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X17 Uncapped recursion over a caller-supplied document — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X18 Disposal-pattern correctness — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X19 Unrestored process-global state — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X2 Cancellation propagation — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X20 Mistyped argument guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X21 Side-effecting pattern guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X22 Contradicted release guard — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X23 Unguarded diagnostic materialisation — This check reads C# syntax; no C# was loaded for this repository, so it has nothing to report. That is a limit of the analyzer, not a finding about your code.
X24 Document value interpolated into markup unescaped — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X25 Inert configuration knob — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X26 Unsynchronised callback handoff — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X27 Collection changed while being enumerated — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X28 Index access outside its own emptiness guard — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X29 Per-element action decided by a fixed element — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X3 Exception handling — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X30 Support guard that admits what it rejects — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X32 Type resolved by simple name across every loaded assembly — This check is about how a .NET program searches the assemblies loaded into its process for a type, and this repository contains no .NET source, so there is nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
X4 Structured logging — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X5 Nullable reference types — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X6 Hand-rolled structured-format parsing — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
X7 Silent fallback defaults — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
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.
No automated tests — No automated tests — no test code was found in this repository. Untested code is the largest single risk to changing it safely. Start with the code you change most often: add a suite in a framework a runner can collect (XCTest or Swift Testing), and run it in CI so the gap cannot reopen.
Dual write (no outbox): ContextMenuLinkCoordinator.onUpdate Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:249— `ContextMenuLinkCoordinator.onUpdate` performs two independent DURABLE writes — `adapter` (a persistence store) via `update` and `interaction` (a persistence store) via `update` — in one command path with no shared transaction or outbox. A crash between the two leaves the stores diverged (one write committed, the other lost) or emits a phantom record. Wrap both in one transaction, or record the second write in the same store and dispatch it afterwards (a transactional outbox).
MethodTooLong: Detent.resolution Sources/Transmission/Sources/Transitions/PresentationLink Transitions/SheetPresentationLinkTransition.swift:105— MethodTooLong — resolution runs 266 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 166 over it, 2.66× 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: MenuSourceViewLink_Previews.previews Sources/Transmission/Sources/MenuSourceViewLink.swift:518— MethodTooLong — previews runs 248 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 148 over it, 2.48× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: InteractivePresentationController.onPanGesture Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:244— MethodTooLong — onPanGesture runs 242 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 142 over it, 2.42× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: Preview.body Sources/Transmission/Sources/VisualEffectView.swift:660— MethodTooLong — body runs 200 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 100 over it, 2.00× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: PresentationLinkCoordinatorAdapter.onUpdate Sources/Transmission/Sources/PresentationLinkAdapter.swift:394— MethodTooLong — onUpdate runs 187 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 87 over it, 1.87× 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: MatchedGeometryViewControllerTransitionAnimator.animateTransition Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift:39— MethodTooLong — animateTransition runs 182 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 82 over it, 1.82× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: UIContextMenuInteraction.makeUIAccessoryView Sources/Transmission/Sources/ContextMenuAccessoryView.swift:198— MethodTooLong — makeUIAccessoryView runs 161 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 61 over it, 1.61× 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: UIView.isInRetargetableAnimationBlock Sources/Transmission/Sources/ContextMenuAccessoryView.swift:201— MethodTooLong — isInRetargetableAnimationBlock runs 158 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 58 over it, 1.58× 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: DestinationLinkDelegateProxy.panGestureDidChange Sources/Transmission/Sources/DestinationLinkAdapter.swift:1093— MethodTooLong — panGestureDidChange runs 153 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 53 over it, 1.53× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: PortalView_Previews.previews Sources/Transmission/Sources/Supporting Files/PortalView.swift:193— MethodTooLong — previews runs 146 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 46 over it, 1.46× 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: PresentationHostingController.viewDidLayoutSubviews Sources/Transmission/Sources/Hosting/PresentationHostingController.swift:32— MethodTooLong — viewDidLayoutSubviews runs 141 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 41 over it, 1.41× 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: PresentationLinkCoordinatorAdapter.makePresentationController Sources/Transmission/Sources/PresentationLinkAdapter.swift:1336— MethodTooLong — makePresentationController runs 118 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 18 over it, 1.18× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: Preview.body Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:861— MethodTooLong — body runs 112 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 12 over it, 1.12× 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: Preview.body Sources/Transmission/Sources/Transitions/CornerRadiusOptions.swift:1136— MethodTooLong — body runs 109 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 9 over it, 1.09× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: Detent.toUIKit Sources/Transmission/Sources/Transitions/PresentationLink Transitions/SheetPresentationLinkTransition.swift:339— MethodTooLong — toUIKit runs 105 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 5 over it, 1.05× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
MethodTooLong: PushNavigationControllerTransition.configureTransitionAnimator Sources/Transmission/Sources/Transitions/DestinationLink Transitions/PushDestinationLinkTransition.swift:155— MethodTooLong — configureTransitionAnimator runs 102 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 2 over it, 1.02× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
Duplicated block (15 lines × 2) Sources/Transmission/Sources/ContextMenuAccessoryView.swift:610— Sources/Transmission/Sources/ContextMenuAccessoryView.swift:610-624 | Sources/Transmission/Sources/ContextMenuAccessoryView.swift:626-640 — 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. Note first that the copies are not typed on the same thing: the declarations holding them bind `alignment` to `.topTrailing` in one and `.center` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `Sources/Transmission/Sources/ContextMenuAccessoryView.swift:641` calls `padding` and `Sources/Transmission/Sources/ContextMenuAccessoryView.swift:626` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:120— Sources/Transmission/Sources/DestinationLink.swift:120-134 | Sources/Transmission/Sources/PresentationLink.swift:122-136 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:120` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:138— Sources/Transmission/Sources/DestinationLink.swift:138-152 | Sources/Transmission/Sources/PresentationLink.swift:140-154 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:138` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:157— Sources/Transmission/Sources/DestinationLink.swift:157-171 | Sources/Transmission/Sources/PresentationLink.swift:159-173 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:157` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:175— Sources/Transmission/Sources/DestinationLink.swift:175-189 | Sources/Transmission/Sources/PresentationLink.swift:177-191 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:175` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:194— Sources/Transmission/Sources/DestinationLink.swift:194-208 | Sources/Transmission/Sources/PresentationLink.swift:196-210 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:194` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationLinkAdapter.swift:105— Sources/Transmission/Sources/DestinationLinkAdapter.swift:105-119 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:106-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. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/DestinationLinkAdapter.swift:105` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationLinkAdapter.swift:125— Sources/Transmission/Sources/DestinationLinkAdapter.swift:125-139 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:126-140 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/DestinationLinkAdapter.swift:125` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:69— Sources/Transmission/Sources/DestinationSourceViewLink.swift:69-83 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:70-84 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:69` 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 (15 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:111— Sources/Transmission/Sources/DestinationSourceViewLink.swift:111-125 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:112-126 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:111` 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 (15 lines × 2) Sources/Transmission/Sources/MenuDialogLinkModifier.swift:172— Sources/Transmission/Sources/MenuDialogLinkModifier.swift:172-186 | Sources/Transmission/Sources/MenuDialogLinkModifier.swift:197-211 — 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 `Sources/Transmission/Sources/MenuDialogLinkModifier.swift:172` 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, `Sources/Transmission/Sources/MenuDialogLinkModifier.swift:214` calls `available` and `Sources/Transmission/Sources/MenuDialogLinkModifier.swift:188` 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 (15 lines × 2) Sources/Transmission/Sources/StatusBarModifier.swift:79— Sources/Transmission/Sources/StatusBarModifier.swift:79-93 | Sources/Transmission/Sources/StatusBarModifier.swift:189-203 — 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 (15 lines × 2) Sources/Transmission/Sources/Supporting Files/PortalView.swift:295— Sources/Transmission/Sources/Supporting Files/PortalView.swift:295-309 | Sources/Transmission/Sources/Supporting Files/PortalView.swift:314-328 — 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 `Sources/Transmission/Sources/Supporting Files/PortalView.swift:295` 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 (15 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift:128— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift:128-142 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/CrossDissolvePresentationLinkTransition.swift:167-181 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift` and `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/CrossDissolvePresentationLinkTransition.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 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.
Duplicated block (15 lines × 2) Example/Example/QuickLookPreviewLinkExamples.swift:18— Example/Example/QuickLookPreviewLinkExamples.swift:18-32 | Example/Example/QuickLookPreviewLinkExamples.swift:37-51 — 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 `Example/Example/QuickLookPreviewLinkExamples.swift:18` 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 (15 lines × 2) Example/Example/ShareSheetLinkExamples.swift:29— Example/Example/ShareSheetLinkExamples.swift:29-43 | Example/Example/ShareSheetLinkExamples.swift:49-63 — 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 `Example/Example/ShareSheetLinkExamples.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.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/MenuDialogLink.swift:31— Sources/Transmission/Sources/MenuDialogLink.swift:31-39 | Sources/Transmission/Sources/MenuDialogLink.swift:72-80 — 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 `Sources/Transmission/Sources/MenuDialogLink.swift:31` 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 (9 lines × 2) Sources/Transmission/Sources/MenuLink.swift:247— Sources/Transmission/Sources/MenuLink.swift:247-255 | Sources/Transmission/Sources/MenuSourceViewLink.swift:423-431 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1277— Sources/Transmission/Sources/PresentationLinkAdapter.swift:1277-1285 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:1300-1308 — 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 `Sources/Transmission/Sources/PresentationLinkAdapter.swift:1277` 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 (9 lines × 2) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1834— Sources/Transmission/Sources/DestinationLinkAdapter.swift:1834-1842 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:1737-1745 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:93— Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:93-101 | Sources/Transmission/Sources/PresentationLinkPathAdapter.swift:92-100 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkPathAdapter.swift` and `Sources/Transmission/Sources/PresentationLinkPathAdapter.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 81 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.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/MenuLink.swift:263— Sources/Transmission/Sources/MenuLink.swift:263-271 | Sources/Transmission/Sources/MenuSourceViewLink.swift:439-447 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/MenuLink.swift:291— Sources/Transmission/Sources/MenuLink.swift:291-299 | Sources/Transmission/Sources/MenuSourceViewLink.swift:467-475 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/MenuLink.swift:301— Sources/Transmission/Sources/MenuLink.swift:301-309 | Sources/Transmission/Sources/MenuSourceViewLink.swift:477-485 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift:68— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift:68-76 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/CrossDissolvePresentationLinkTransition.swift:65-73 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift` and `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/CrossDissolvePresentationLinkTransition.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 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.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/DestinationLinkTransition.swift:77— Sources/Transmission/Sources/DestinationLinkTransition.swift:77-85 | Sources/Transmission/Sources/PresentationLinkTransition.swift:112-122 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/DismissDestinationLink.swift:38— Sources/Transmission/Sources/DismissDestinationLink.swift:38-46 | Sources/Transmission/Sources/DismissPresentationLink.swift:38-46 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/MenuButton.swift:215— Sources/Transmission/Sources/MenuButton.swift:215-223 | Sources/Transmission/Sources/MenuPicker.swift:49-57 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (9 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift:19— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift:19-27 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:19-27 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift` and `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 46 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 first that the copies are not typed on the same thing: the declarations holding them bind `options` to `DestinationLinkTransition.Options = .init()` in one and `PresentationLinkTransition.Options = .init()` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (11 lines × 2) Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:761— Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:761-771 | Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:781-791 — 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) Sources/Transmission/Sources/DestinationLink.swift:51— Sources/Transmission/Sources/DestinationLink.swift:51-61 | Sources/Transmission/Sources/PresentationLink.swift:53-63 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:51` 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 (11 lines × 2) Sources/Transmission/Sources/DestinationLinkModifier.swift:68— Sources/Transmission/Sources/DestinationLinkModifier.swift:68-78 | Sources/Transmission/Sources/PresentationLinkModifier.swift:71-81 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkModifier.swift` and `Sources/Transmission/Sources/PresentationLinkModifier.swift` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 90 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 `Sources/Transmission/Sources/DestinationLinkModifier.swift:68` 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 (11 lines × 2) Sources/Transmission/Sources/DestinationLinkModifier.swift:82— Sources/Transmission/Sources/DestinationLinkModifier.swift:82-92 | Sources/Transmission/Sources/PresentationLinkModifier.swift:85-95 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkModifier.swift` and `Sources/Transmission/Sources/PresentationLinkModifier.swift` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 90 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 `Sources/Transmission/Sources/DestinationLinkModifier.swift:82` 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 (11 lines × 2) Sources/Transmission/Sources/DestinationLinkModifier.swift:97— Sources/Transmission/Sources/DestinationLinkModifier.swift:97-107 | Sources/Transmission/Sources/PresentationLinkModifier.swift:100-110 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkModifier.swift` and `Sources/Transmission/Sources/PresentationLinkModifier.swift` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 90 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 `Sources/Transmission/Sources/DestinationLinkModifier.swift:97` 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 (11 lines × 2) Sources/Transmission/Sources/DismissDestinationLink.swift:26— Sources/Transmission/Sources/DismissDestinationLink.swift:26-36 | Sources/Transmission/Sources/DismissPresentationLink.swift:26-36 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once.
Duplicated block (11 lines × 2) Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:124— Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:124-134 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/SlidePresentationLinkTransition.swift:87-97 — 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 `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:124` 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 (11 lines × 2) Sources/Transmission/Sources/DestinationCoordinator.swift:28— Sources/Transmission/Sources/DestinationCoordinator.swift:28-38 | Sources/Transmission/Sources/PresentationCoordinator.swift:30-40 — before extracting anything, compare `Sources/Transmission/Sources/DestinationCoordinator.swift` and `Sources/Transmission/Sources/PresentationCoordinator.swift` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 38 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.
Duplicated block (11 lines × 2) Sources/Transmission/Sources/DestinationLinkModifier.swift:33— Sources/Transmission/Sources/DestinationLinkModifier.swift:33-43 | Sources/Transmission/Sources/PresentationLinkModifier.swift:36-46 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkModifier.swift` and `Sources/Transmission/Sources/PresentationLinkModifier.swift` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 90 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.
Duplicated block (11 lines × 2) Example/Example/DestinationLinkExamples.swift:88— Example/Example/DestinationLinkExamples.swift:88-98 | Example/Example/PresentationLinkExamples.swift:145-155 — before extracting anything, compare `Example/Example/DestinationLinkExamples.swift` and `Example/Example/PresentationLinkExamples.swift` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 105 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 `Example/Example/DestinationLinkExamples.swift:88` 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 (11 lines × 2) Example/Example/DestinationLinkExamples.swift:110— Example/Example/DestinationLinkExamples.swift:110-120 | Example/Example/DestinationLinkExamples.swift:147-157 — 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 `Example/Example/DestinationLinkExamples.swift:110` 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 (11 lines × 2) Example/Example/PresentationLinkExamples.swift:195— Example/Example/PresentationLinkExamples.swift:195-205 | Example/Example/PresentationLinkExamples.swift:232-242 — 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 `Example/Example/PresentationLinkExamples.swift:195` 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.
Hotspot: Sources/Transmission/Sources/PresentationLinkAdapter.swift Sources/Transmission/Sources/PresentationLinkAdapter.swift:394— Sources/Transmission/Sources/PresentationLinkAdapter.swift changed 13 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 62 in PresentationLinkCoordinatorAdapter.onUpdate at line 394. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/PresentationLinkAdapter.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/DestinationLinkAdapter.swift Sources/Transmission/Sources/DestinationLinkAdapter.swift:1093— Sources/Transmission/Sources/DestinationLinkAdapter.swift changed 8 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 71 in DestinationLinkDelegateProxy.panGestureDidChange at line 1093. 1 of those changes was a fix/bug commit, and the other 7 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, make sure the area it touches is under test, then split that area out of the file so the following change is smaller than this one — a file this often edited pays the complexity back every time. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/DestinationLinkAdapter.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:244— Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 104 in InteractivePresentationController.onPanGesture at line 244. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift:39— Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift changed 6 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 72 in MatchedGeometryViewControllerTransitionAnimator.animateTransition at line 39. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/ContextMenuAccessoryView.swift Sources/Transmission/Sources/ContextMenuAccessoryView.swift:198— Sources/Transmission/Sources/ContextMenuAccessoryView.swift changed 7 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 59 in UIContextMenuInteraction.makeUIAccessoryView at line 198. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/ContextMenuAccessoryView.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/Hosting/PresentationHostingController.swift Sources/Transmission/Sources/Hosting/PresentationHostingController.swift:32— Sources/Transmission/Sources/Hosting/PresentationHostingController.swift changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 57 in PresentationHostingController.viewDidLayoutSubviews at line 32. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/Hosting/PresentationHostingController.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/ContextMenuLinkAdapter.swift Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:229— Sources/Transmission/Sources/ContextMenuLinkAdapter.swift changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 18 in ContextMenuLinkCoordinator.onUpdate at line 229. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/ContextMenuLinkAdapter.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/Transitions/Presentation Controllers/CardPresentationController.swift Sources/Transmission/Sources/Transitions/Presentation Controllers/CardPresentationController.swift:227— Sources/Transmission/Sources/Transitions/Presentation Controllers/CardPresentationController.swift changed 5 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 15 in CardPresentationController.setCornerRadius at line 227. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/Transitions/Presentation Controllers/CardPresentationController.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/VisualEffectView.swift Sources/Transmission/Sources/VisualEffectView.swift:246— Sources/Transmission/Sources/VisualEffectView.swift changed 4 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 16 in GlassEffect.makeUIVisualEffect at line 246. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/VisualEffectView.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
Hotspot: Sources/Transmission/Sources/WindowLinkAdapter.swift Sources/Transmission/Sources/WindowLinkAdapter.swift:141— Sources/Transmission/Sources/WindowLinkAdapter.swift changed 2 times in last 90 days, and the most complex body those changes touched has cyclomatic complexity 15 in WindowLinkCoordinatorAdapter.onUpdate at line 141. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, with the area under test before it moves. Counted over 2026-06-19..2026-09-17, the 90 days ending at the analysed commit. Reproduce with `git log --since='2026-06-19 14:37:24 -07:00' --until='2026-09-17 14:37:24 -07:00' --full-history --no-merges -- Sources/Transmission/Sources/WindowLinkAdapter.swift`: merges are excluded because a merge re-states changes already counted at their own commits, and history is NOT path-simplified because a change that reached the file through a merged branch is still a change to it. That command counts raw commits and can read HIGHER than this row, which counts a cherry-picked re-land, and a revert together with the commit it undoes, once each — a difference of several commits on a file whose history was re-landed or reverted inside the window.
FileTooLong: Sources/DestinationLinkAdapter.swift Sources/Transmission/Sources/DestinationLinkAdapter.swift— FileTooLong — 1367 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 867 over it, 2.73× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: Sources/PresentationLinkAdapter.swift Sources/Transmission/Sources/PresentationLinkAdapter.swift— FileTooLong — 1322 significant lines (blank, comment-only and punctuation-only lines excluded), about 74% of them inside a single declaration: PresentationLinkCoordinatorAdapter (341-1699). The bar is 500 significant lines; this is 822 over it, 2.64× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
FileTooLong: Transitions/CornerRadiusOptions.swift Sources/Transmission/Sources/Transitions/CornerRadiusOptions.swift— FileTooLong — 885 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 385 over it, 1.77× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: Sources/ContextMenuLinkAdapter.swift Sources/Transmission/Sources/ContextMenuLinkAdapter.swift— FileTooLong — 739 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 239 over it, 1.48× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: Sources/MenuElement.swift Sources/Transmission/Sources/MenuElement.swift— FileTooLong — 644 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 144 over it, 1.29× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: Sources/VisualEffectView.swift Sources/Transmission/Sources/VisualEffectView.swift— FileTooLong — 634 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 134 over it, 1.27× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: Sources/MenuSourceViewLink.swift Sources/Transmission/Sources/MenuSourceViewLink.swift— FileTooLong — 601 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 101 over it, 1.20× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
FileTooLong: Presentation Controllers/SheetPresentationController.swift Sources/Transmission/Sources/Transitions/Presentation Controllers/SheetPresentationController.swift— FileTooLong — 573 significant lines (blank, comment-only and punctuation-only lines excluded), about 61% of them inside a single declaration: SheetPresentationController (213-728). The bar is 500 significant lines; this is 73 over it, 1.15× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
FileTooLong: Presentation Controllers/InteractivePresentationController.swift Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift— FileTooLong — 548 significant lines (blank, comment-only and punctuation-only lines excluded), about 99% of them inside a single declaration: InteractivePresentationController (17-795). The bar is 500 significant lines; this is 48 over it, 1.10× the bar. Moving the declarations that sit BESIDE it into sibling files will not shorten this file. Extract from INSIDE that declaration instead: lift each cohesive group of its body — the parts that share the same inputs and are named together — into its own unit in a sibling file, and have the original call them.
Duplicated block (12 lines × 2) Sources/Transmission/Sources/DestinationLinkModifier.swift:111— Sources/Transmission/Sources/DestinationLinkModifier.swift:111-122 | Sources/Transmission/Sources/PresentationLinkModifier.swift:114-125 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkModifier.swift` and `Sources/Transmission/Sources/PresentationLinkModifier.swift` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 90 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 `Sources/Transmission/Sources/DestinationLinkModifier.swift:111` 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 (12 lines × 2) Sources/Transmission/Sources/DestinationLinkModifier.swift:127— Sources/Transmission/Sources/DestinationLinkModifier.swift:127-138 | Sources/Transmission/Sources/PresentationLinkModifier.swift:130-141 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkModifier.swift` and `Sources/Transmission/Sources/PresentationLinkModifier.swift` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 90 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 `Sources/Transmission/Sources/DestinationLinkModifier.swift:127` 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 (12 lines × 2) Sources/Transmission/Sources/Supporting Files/UIGestureRecognizerDelegateProxy.swift:20— Sources/Transmission/Sources/Supporting Files/UIGestureRecognizerDelegateProxy.swift:20-31 | Sources/Transmission/Sources/Supporting Files/UINavigationControllerDelegateProxy.swift:20-31 — 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 (12 lines × 2) Sources/Transmission/Sources/Supporting Files/UIGestureRecognizerDelegateProxy.swift:33— Sources/Transmission/Sources/Supporting Files/UIGestureRecognizerDelegateProxy.swift:33-44 | Sources/Transmission/Sources/Supporting Files/UINavigationControllerDelegateProxy.swift:33-44 — 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 (12 lines × 2) Sources/Transmission/Sources/Transitions/CornerRadiusOptions.swift:873— Sources/Transmission/Sources/Transitions/CornerRadiusOptions.swift:873-884 | Sources/Transmission/Sources/Transitions/CornerRadiusOptions.swift:944-955 — 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 (12 lines × 2) Sources/Transmission/Sources/DestinationCoordinator.swift:59— Sources/Transmission/Sources/DestinationCoordinator.swift:59-70 | Sources/Transmission/Sources/PresentationCoordinator.swift:61-72 — before extracting anything, compare `Sources/Transmission/Sources/DestinationCoordinator.swift` and `Sources/Transmission/Sources/PresentationCoordinator.swift` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 38 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.
Duplicated block (12 lines × 2) Sources/Transmission/Sources/Extensions/UIContextMenuConfiguration+Extensions.swift:22— Sources/Transmission/Sources/Extensions/UIContextMenuConfiguration+Extensions.swift:22-33 | Sources/Transmission/Sources/Extensions/UITargetedPreview+Extensions.swift:22-33 — 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 `Sources/Transmission/Sources/Extensions/UIContextMenuConfiguration+Extensions.swift:22` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (12 lines × 2) Sources/Transmission/Sources/MenuLink.swift:311— Sources/Transmission/Sources/MenuLink.swift:311-322 | Sources/Transmission/Sources/MenuSourceViewLink.swift:487-498 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (12 lines × 2) Sources/Transmission/Sources/MenuLink.swift:324— Sources/Transmission/Sources/MenuLink.swift:324-335 | Sources/Transmission/Sources/MenuSourceViewLink.swift:500-511 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (13 lines × 2) Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:43— Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:43-55 | Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:65-77 — 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 `Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:43` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
Duplicated block (13 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:88— Sources/Transmission/Sources/DestinationLink.swift:88-100 | Sources/Transmission/Sources/PresentationLink.swift:90-102 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:88` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
Duplicated block (13 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:104— Sources/Transmission/Sources/DestinationLink.swift:104-116 | Sources/Transmission/Sources/PresentationLink.swift:106-118 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:104` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
Duplicated block (13 lines × 2) Sources/Transmission/Sources/DestinationLinkAdapter.swift:67— Sources/Transmission/Sources/DestinationLinkAdapter.swift:67-79 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:68-80 — 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 `Sources/Transmission/Sources/DestinationLinkAdapter.swift:67` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
Duplicated block (13 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:268— Sources/Transmission/Sources/DestinationSourceViewLink.swift:268-280 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:268-280 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:268` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (13 lines × 2) Sources/Transmission/Sources/MenuDialogLink.swift:51— Sources/Transmission/Sources/MenuDialogLink.swift:51-63 | Sources/Transmission/Sources/MenuDialogLink.swift:94-106 — 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 `Sources/Transmission/Sources/MenuDialogLink.swift:51` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
Duplicated block (13 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift:149— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift:149-161 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/CrossDissolvePresentationLinkTransition.swift:188-200 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/DestinationLink Transitions/CrossDissolveDestinationLinkTransition.swift` and `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/CrossDissolvePresentationLinkTransition.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 37 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.
Duplicated block (13 lines × 2) Example/Example/PresentationLinkExamples.swift:393— Example/Example/PresentationLinkExamples.swift:393-405 | Example/Example/PresentationLinkExamples.swift:442-454 — 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 `Example/Example/PresentationLinkExamples.swift:393` 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 (8 lines × 2) Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:38— Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:38-45 | Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:59-66 — 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 `Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:38` 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 (8 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/ZoomDestinationLinkTransition.swift:18— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/ZoomDestinationLinkTransition.swift:18-25 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/ZoomPresentationLinkTransition.swift:20-27 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/Transitions/DestinationLink Transitions/ZoomDestinationLinkTransition.swift:18` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (8 lines × 2) Sources/Transmission/Sources/MenuLink.swift:213— Sources/Transmission/Sources/MenuLink.swift:213-220 | Sources/Transmission/Sources/MenuSourceViewLink.swift:367-374 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (8 lines × 2) Sources/Transmission/Sources/MenuLink.swift:273— Sources/Transmission/Sources/MenuLink.swift:273-280 | Sources/Transmission/Sources/MenuSourceViewLink.swift:449-456 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (8 lines × 2) Sources/Transmission/Sources/MenuLink.swift:282— Sources/Transmission/Sources/MenuLink.swift:282-289 | Sources/Transmission/Sources/MenuSourceViewLink.swift:458-465 — before extracting anything, compare `Sources/Transmission/Sources/MenuLink.swift` and `Sources/Transmission/Sources/MenuSourceViewLink.swift` as WHOLE FILES: this scan already matched 11 separate duplicated blocks between them, totalling at least 99 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.
Duplicated block (8 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/SlideDestinationLinkTransition.swift:107— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/SlideDestinationLinkTransition.swift:107-114 | Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:124-131 — 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) Example/Example/DestinationLinkExamples.swift:58— Example/Example/DestinationLinkExamples.swift:58-65 | Example/Example/PresentationLinkExamples.swift:92-99 — before extracting anything, compare `Example/Example/DestinationLinkExamples.swift` and `Example/Example/PresentationLinkExamples.swift` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 105 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 `Example/Example/DestinationLinkExamples.swift:58` 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.
Low cohesion: UIViewController (LCOM4 12) Sources/Transmission/Sources/StatusBarModifier.swift:250— UIViewController's methods fall into 12 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 12 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: UINavigationController (LCOM4 10) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1780— UINavigationController's methods fall into 10 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 10 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
Low cohesion: UIView (LCOM4 9) Sources/Transmission/Sources/ContextMenuAccessoryView.swift:525— UIView's methods fall into 9 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 9 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: MenuLinkSourceView (LCOM4 6) Sources/Transmission/Sources/MenuSourceViewLink.swift:293— MenuLinkSourceView's methods fall into 6 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 6 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
Low cohesion: MatchedGeometryPresentationController (LCOM4 5) Sources/Transmission/Sources/Transitions/Presentation Controllers/MatchedGeometryPresentationController.swift:11— MatchedGeometryPresentationController's methods fall into 5 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 5 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
Low cohesion: MenuLinkView (LCOM4 4) Sources/Transmission/Sources/MenuLink.swift:169— MenuLinkView'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: DynamicIslandPresentationController (LCOM4 4) Example/Example/DynamicIslandTransition.swift:86— DynamicIslandPresentationController'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.
Duplicated block (10 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:38— Sources/Transmission/Sources/DestinationLink.swift:38-47 | Sources/Transmission/Sources/PresentationLink.swift:40-49 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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 `Sources/Transmission/Sources/DestinationLink.swift:38` 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 (10 lines × 2) Sources/Transmission/Sources/MenuSourceViewLink.swift:100— Sources/Transmission/Sources/MenuSourceViewLink.swift:100-109 | Sources/Transmission/Sources/MenuSourceViewLink.swift:138-147 — 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 `Sources/Transmission/Sources/MenuSourceViewLink.swift:100` 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 (10 lines × 2) Sources/Transmission/Sources/DestinationCoordinator.swift:40— Sources/Transmission/Sources/DestinationCoordinator.swift:40-49 | Sources/Transmission/Sources/PresentationCoordinator.swift:42-51 — before extracting anything, compare `Sources/Transmission/Sources/DestinationCoordinator.swift` and `Sources/Transmission/Sources/PresentationCoordinator.swift` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 38 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.
Duplicated block (10 lines × 2) Sources/Transmission/Sources/Extensions/UIAlertController+Extensions.swift:22— Sources/Transmission/Sources/Extensions/UIAlertController+Extensions.swift:22-31 | Sources/Transmission/Sources/MenuElementView.swift:183-192 — 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 `Sources/Transmission/Sources/Extensions/UIAlertController+Extensions.swift:22` 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 (10 lines × 2) Sources/Transmission/Sources/Hosting/DestinationHostingController.swift:17— Sources/Transmission/Sources/Hosting/DestinationHostingController.swift:17-26 | Sources/Transmission/Sources/Hosting/PresentationHostingWindowController.swift:76-86 — 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 (10 lines × 2) Sources/Transmission/Sources/DestinationLinkAdapter.swift:463— Sources/Transmission/Sources/DestinationLinkAdapter.swift:463-472 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:813-822 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Note first that the copies are not typed on the same thing: the declarations holding them bind `options` to `DestinationLinkTransition.Options` in one and `PresentationLinkTransition.Options` 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.
ClassTooLong: PresentationLinkCoordinatorAdapter Sources/Transmission/Sources/PresentationLinkAdapter.swift:339— ClassTooLong — 976 significant lines (blank, comment-only and punctuation-only lines excluded), 35 methods. The bar is 400 significant lines; this is 576 over it, 2.44× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: DestinationLinkDelegateProxy Sources/Transmission/Sources/DestinationLinkAdapter.swift:964— ClassTooLong — 588 significant lines (blank, comment-only and punctuation-only lines excluded), 22 methods. The bar is 400 significant lines; this is 188 over it, 1.47× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: InteractivePresentationController Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:16— ClassTooLong — 541 significant lines (blank, comment-only and punctuation-only lines excluded), 27 methods. The bar is 400 significant lines; this is 141 over it, 1.35× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: DestinationLinkCoordinatorAdapter Sources/Transmission/Sources/DestinationLinkAdapter.swift:237— ClassTooLong — 483 significant lines (blank, comment-only and punctuation-only lines excluded), 24 methods. The bar is 400 significant lines; this is 83 over it, 1.21× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
ClassTooLong: SheetPresentationController Sources/Transmission/Sources/Transitions/Presentation Controllers/SheetPresentationController.swift:12— ClassTooLong — 476 significant lines (blank, comment-only and punctuation-only lines excluded), 9 methods, 2 blocks, lines 13-728. The bar is 400 significant lines; this is 76 over it, 1.19× 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.
Duplicated block (19 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:151— Sources/Transmission/Sources/DestinationSourceViewLink.swift:151-169 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:152-170 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:151` 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 (19 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:173— Sources/Transmission/Sources/DestinationSourceViewLink.swift:173-191 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:174-192 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:173` 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 (19 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:196— Sources/Transmission/Sources/DestinationSourceViewLink.swift:196-214 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:197-215 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:196` 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 (19 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:218— Sources/Transmission/Sources/DestinationSourceViewLink.swift:218-236 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:219-237 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:218` 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 (19 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:241— Sources/Transmission/Sources/DestinationSourceViewLink.swift:241-259 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:242-260 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:241` 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 (16 lines × 2) Sources/Transmission/Sources/MenuSourceViewLink.swift:734— Sources/Transmission/Sources/MenuSourceViewLink.swift:734-749 | Sources/Transmission/Sources/MenuSourceViewLink.swift:751-766 — 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. Note first that the copies are not typed on the same thing: the declarations holding them bind `id` to `"a"` in one and `"b"` 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 (16 lines × 2) Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:47— Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:47-62 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/SlidePresentationLinkTransition.swift:45-60 — 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 `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:47` 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 (16 lines × 2) Sources/Transmission/Sources/DestinationLinkModifier.swift:45— Sources/Transmission/Sources/DestinationLinkModifier.swift:45-60 | Sources/Transmission/Sources/PresentationLinkModifier.swift:48-63 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkModifier.swift` and `Sources/Transmission/Sources/PresentationLinkModifier.swift` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 90 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.
Duplicated block (16 lines × 2) Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:37— Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:37-52 | Sources/Transmission/Sources/PresentationLinkPathAdapter.swift:36-51 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkPathAdapter.swift` and `Sources/Transmission/Sources/PresentationLinkPathAdapter.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 81 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.
Duplicated block (16 lines × 2) Example/Example/DestinationLinkExamples.swift:70— Example/Example/DestinationLinkExamples.swift:70-85 | Example/Example/PresentationLinkExamples.swift:108-123 — before extracting anything, compare `Example/Example/DestinationLinkExamples.swift` and `Example/Example/PresentationLinkExamples.swift` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 105 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 `Example/Example/DestinationLinkExamples.swift:70` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (14 lines × 2) Example/Example/DynamicIslandTransition.swift:190— Example/Example/DynamicIslandTransition.swift:190-203 | Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:211-224 — 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 (14 lines × 2) Sources/Transmission/Sources/DestinationLinkAdapter.swift:855— Sources/Transmission/Sources/DestinationLinkAdapter.swift:855-868 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:1599-1612 — 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 (14 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:52— Sources/Transmission/Sources/DestinationSourceViewLink.swift:52-65 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:53-66 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:52` 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 (14 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift:185— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift:185-198 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:271-284 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift` and `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 46 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.
Duplicated block (14 lines × 2) Example/Example/DestinationLinkExamples.swift:150— Example/Example/DestinationLinkExamples.swift:150-163 | Example/Example/PresentationLinkExamples.swift:235-248 — before extracting anything, compare `Example/Example/DestinationLinkExamples.swift` and `Example/Example/PresentationLinkExamples.swift` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 105 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 `Example/Example/DestinationLinkExamples.swift:150` 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.
D4 · Code Duplication· Members sharing a duplicated core (4 members, 50+ identical tokens) · ×4
Members sharing a duplicated core (4 members, 50+ identical tokens) Example/Example/DynamicIslandTransition.swift:167— Example/Example/DynamicIslandTransition.swift:167-230 | Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:133-215 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:112-202 | Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:28-94 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
Members sharing a duplicated core (4 members, 50+ identical tokens) Sources/Transmission/Sources/DestinationLinkAdapter.swift:103— Sources/Transmission/Sources/DestinationLinkAdapter.swift:103-121 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:123-141 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:104-122 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:124-142 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
Members sharing a duplicated core (4 members, 50+ identical tokens) Sources/Transmission/Sources/DestinationLinkAdapter.swift:885— Sources/Transmission/Sources/DestinationLinkAdapter.swift:885-928 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:1328-1381 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:1646-1698 | Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:604-648 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
Members sharing a duplicated core (4 members, 50+ identical tokens) Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:25— Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:25-92 | Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift:39-294 | Sources/Transmission/Sources/Transitions/View Controller Transitions/SlideTransitionAnimator.swift:26-124 | Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:194-244 — These 4 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 4 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 4 times.
Duplicated block (17 lines × 2) Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:139— Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:139-155 | Sources/Transmission/Sources/PresentationLinkPathAdapter.swift:138-154 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkPathAdapter.swift` and `Sources/Transmission/Sources/PresentationLinkPathAdapter.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 81 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.
Duplicated block (17 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:131— Sources/Transmission/Sources/DestinationSourceViewLink.swift:131-147 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:132-148 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:131` 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 (17 lines × 2) Sources/Transmission/Sources/DestinationLink.swift:63— Sources/Transmission/Sources/DestinationLink.swift:63-79 | Sources/Transmission/Sources/PresentationLink.swift:65-81 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/PresentationLink.swift` as WHOLE FILES: this scan already matched 13 separate duplicated blocks between them, totalling at least 165 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.
Duplicated block (17 lines × 2) Sources/Transmission/Sources/DestinationLinkAdapter.swift:81— Sources/Transmission/Sources/DestinationLinkAdapter.swift:81-97 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:82-98 — 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) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1822— Sources/Transmission/Sources/DestinationLinkAdapter.swift:1822-1832 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:1725-1735 | Sources/Transmission/Sources/WindowLinkAdapter.swift:340-350 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/DestinationLinkAdapter.swift:1822` 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 (11 lines × 3) Sources/Transmission/Sources/Extensions/CALayer+CornerRadii.swift:46— Sources/Transmission/Sources/Extensions/CALayer+CornerRadii.swift:46-56 | Sources/Transmission/Sources/Extensions/UISheetPresentationController+Extensions.swift:224-234 | Sources/Transmission/Sources/Extensions/UISheetPresentationController+Extensions.swift:236-246 — 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 (11 lines × 3) Sources/Transmission/Sources/Extensions/UIPopoverPresentationController+Extensions.swift:11— Sources/Transmission/Sources/Extensions/UIPopoverPresentationController+Extensions.swift:11-21 | Sources/Transmission/Sources/Extensions/UISheetPresentationController+Extensions.swift:248-258 | Sources/Transmission/Sources/Extensions/UISheetPresentationController+Extensions.swift:260-270 — 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 (7 lines × 2) Sources/Transmission/Sources/MenuElement.swift:941— Sources/Transmission/Sources/MenuElement.swift:941-947 | Sources/Transmission/Sources/MenuElementView.swift:130-136 — 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 `Sources/Transmission/Sources/MenuElement.swift:941` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (7 lines × 2) Sources/Transmission/Sources/ShareSheetLink.swift:71— Sources/Transmission/Sources/ShareSheetLink.swift:71-77 | Sources/Transmission/Sources/ShareSheetLink.swift:85-91 — 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 `Sources/Transmission/Sources/ShareSheetLink.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.
Duplicated block (7 lines × 2) Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:112— Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:112-119 | Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:28-34 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 43 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 `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:112` 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:109` calls `available` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:26` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (6 lines × 4) Example/Example/DynamicIslandTransition.swift:175— Example/Example/DynamicIslandTransition.swift:175-180 | Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:141-146 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:120-125 | Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:35-40 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 62 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. 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 (6 lines × 4) Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:33— Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:33-38 | Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift:48-53 | Sources/Transmission/Sources/Transitions/View Controller Transitions/SlideTransitionAnimator.swift:34-39 | Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:202-207 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 4 call sites, so a change lands once. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (6 lines × 4) Sources/Transmission/Sources/DestinationLinkAdapter.swift:22— Sources/Transmission/Sources/DestinationLinkAdapter.swift:22-27 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:22-27 | Sources/Transmission/Sources/TransitionLinkAdapter.swift:20-25 | Sources/Transmission/Sources/WindowLinkAdapter.swift:21-26 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 4 call sites, so a change lands once.
Duplicated block (6 lines × 2) Sources/Transmission/Sources/MenuDialogLink.swift:69— Sources/Transmission/Sources/MenuDialogLink.swift:69-74 | Sources/Transmission/Sources/MenuDialogLinkModifier.swift:167-173 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (6 lines × 2) Sources/Transmission/Sources/MenuDialogLink.swift:91— Sources/Transmission/Sources/MenuDialogLink.swift:91-96 | Sources/Transmission/Sources/MenuDialogLinkModifier.swift:192-198 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from both call sites, so a change lands once. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (6 lines × 2) Sources/Transmission/Sources/MenuGroup.swift:242— Sources/Transmission/Sources/MenuGroup.swift:242-247 | Sources/Transmission/Sources/MenuGroup.swift:252-257 — 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 `Sources/Transmission/Sources/MenuGroup.swift:242` 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `Sources/Transmission/Sources/MenuGroup.swift:248` calls `toUIKit` and `Sources/Transmission/Sources/MenuGroup.swift:258` 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.
TooManyMethods: View Sources/Transmission/Sources/AdaptiveColorSchemeModifier.swift:50— TooManyMethods — 37 methods. The bar is 30 methods; this is 7 over it, 1.23× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
TooManyMethods: PresentationLinkCoordinatorAdapter Sources/Transmission/Sources/PresentationLinkAdapter.swift:339— TooManyMethods — 35 methods. The bar is 30 methods; this is 5 over it, 1.17× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
Duplicated block (23 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift:161— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift:161-183 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:247-269 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/DestinationLink Transitions/MatchedGeometryDestinationLinkTransition.swift` and `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift` as WHOLE FILES: this scan already matched 3 separate duplicated blocks between them, totalling at least 46 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.
Duplicated block (23 lines × 2) Example/Example/DestinationLinkExamples.swift:113— Example/Example/DestinationLinkExamples.swift:113-135 | Example/Example/PresentationLinkExamples.swift:198-220 — before extracting anything, compare `Example/Example/DestinationLinkExamples.swift` and `Example/Example/PresentationLinkExamples.swift` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 105 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 `Example/Example/DestinationLinkExamples.swift:113` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (21 lines × 2) Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:190— Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:190-210 | Sources/Transmission/Sources/PresentationLinkPathAdapter.swift:190-210 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkPathAdapter.swift` and `Sources/Transmission/Sources/PresentationLinkPathAdapter.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 81 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 `Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:190` 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 (21 lines × 2) Sources/Transmission/Sources/MenuSourceViewLink.swift:524— Sources/Transmission/Sources/MenuSourceViewLink.swift:524-544 | Sources/Transmission/Sources/MenuSourceViewLink.swift:548-568 — 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 `Sources/Transmission/Sources/MenuSourceViewLink.swift:524` 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 (20 lines × 2) Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:172— Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:172-191 | Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:195-214 — 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 `Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:172` 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, `Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:194` calls `frame` and `Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:171` 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 (20 lines × 2) Sources/Transmission/Sources/DestinationLinkAdapter.swift:160— Sources/Transmission/Sources/DestinationLinkAdapter.swift:160-179 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:161-180 — 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 `Sources/Transmission/Sources/DestinationLinkAdapter.swift:160` 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 (18 lines × 2) Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:172— Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:172-189 | Sources/Transmission/Sources/PresentationLinkPathAdapter.swift:171-188 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkPathAdapter.swift` and `Sources/Transmission/Sources/PresentationLinkPathAdapter.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 81 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 `Sources/Transmission/Sources/DestinationLinkPathAdapter.swift:172` 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 (18 lines × 2) Sources/Transmission/Sources/DestinationSourceViewLink.swift:85— Sources/Transmission/Sources/DestinationSourceViewLink.swift:85-102 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:86-103 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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.
Duplicated block (11–12 lines × 2) Sources/Transmission/Sources/ContextMenuAccessoryView.swift:245— Sources/Transmission/Sources/ContextMenuAccessoryView.swift:245-256 | Sources/Transmission/Sources/ContextMenuAccessoryView.swift:376-386 — 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 `Sources/Transmission/Sources/ContextMenuAccessoryView.swift:245` 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. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (11–12 lines × 2) Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:183— Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:183-194 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:208-218 — 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 `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/MatchedGeometryPresentationLinkTransition.swift:183` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note first that the copies are not typed on the same thing: the declarations holding them bind `presentationController` to `MatchedGeometryPresentationController` in one and `UIPresentationController` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (10 lines × 3) Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:47— Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:47-56 | Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:46-55 | Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:68-77 — 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 `Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:47` 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 (10 lines × 3) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/ZoomDestinationLinkTransition.swift:42— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/ZoomDestinationLinkTransition.swift:42-51 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/SheetPresentationLinkTransition.swift:87-96 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/ZoomPresentationLinkTransition.swift:44-53 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere all 3 call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made 3 times. Note first that the copies are not typed on the same thing: the declarations holding them bind `options` to `DestinationLinkTransition.Options = .init()` in one and `PresentationLinkTransition.Options = .init()` in another, and the duplicated lines use it. The extracted unit therefore needs a parameter type that fits BOTH — their common supertype where they have one, or a new abstraction over them where they do not — and settling that is the step that comes BEFORE the extraction above. Where the two types are deliberately unrelated, the duplication is the price of that separation and the honest resolution is to record the decision rather than to extract.
Duplicated block (9 lines × 3) Sources/Transmission/Sources/DestinationSourceViewLink.swift:153— Sources/Transmission/Sources/DestinationSourceViewLink.swift:153-161 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:154-162 | Sources/Transmission/Sources/WindowLink.swift:128-136 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:153` 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 (9 lines × 3) Sources/Transmission/Sources/DestinationSourceViewLink.swift:243— Sources/Transmission/Sources/DestinationSourceViewLink.swift:243-251 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:244-252 | Sources/Transmission/Sources/WindowLink.swift:210-218 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:243` 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 (6 lines × 3) Example/Example/DynamicIslandTransition.swift:167— Example/Example/DynamicIslandTransition.swift:167-174 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:113-119 | Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:29-34 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 43 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 `Example/Example/DynamicIslandTransition.swift:167` 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. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just before the matched lines, `Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:109` calls `available` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:26` does not — after which the two agree again for 2 more lines. One of those two behaviours is the intended one and the other is what a copy-paste left behind, so decide which BEFORE unifying them: extracting the shared part will silently settle it, and if the copy that skips the call is the wrong one, that bug is already live.
Duplicated block (6 lines × 3) Sources/Transmission/Sources/DestinationLinkModifier.swift:278— Sources/Transmission/Sources/DestinationLinkModifier.swift:278-283 | Sources/Transmission/Sources/PresentationLinkModifier.swift:281-286 | Sources/Transmission/Sources/WindowLinkModifier.swift:303-308 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkModifier.swift` and `Sources/Transmission/Sources/PresentationLinkModifier.swift` as WHOLE FILES: this scan already matched 8 separate duplicated blocks between them, totalling at least 90 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.
Duplicated block (5 lines × 2) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/ZoomDestinationLinkTransition.swift:109— Sources/Transmission/Sources/Transitions/DestinationLink Transitions/ZoomDestinationLinkTransition.swift:109-113 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/ZoomPresentationLinkTransition.swift:133-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 (5 lines × 2) Sources/Transmission/Sources/DestinationCoordinator.swift:115— Sources/Transmission/Sources/DestinationCoordinator.swift:115-119 | Sources/Transmission/Sources/PresentationCoordinator.swift:117-121 — before extracting anything, compare `Sources/Transmission/Sources/DestinationCoordinator.swift` and `Sources/Transmission/Sources/PresentationCoordinator.swift` as WHOLE FILES: this scan already matched 4 separate duplicated blocks between them, totalling at least 38 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.
InteractivePresentationController.onPanGesture (cyclomatic 104) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:244— InteractivePresentationController.onPanGesture has cyclomatic complexity 104 (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.
MatchedGeometryViewControllerTransitionAnimator.animateTransition (cyclomatic 72) Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift:39— MatchedGeometryViewControllerTransitionAnimator.animateTransition has cyclomatic complexity 72 (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.
DestinationLinkDelegateProxy.panGestureDidChange (cyclomatic 71) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1093— DestinationLinkDelegateProxy.panGestureDidChange has cyclomatic complexity 71 (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.
PresentationLinkCoordinatorAdapter.onUpdate (cyclomatic 62) Sources/Transmission/Sources/PresentationLinkAdapter.swift:394— PresentationLinkCoordinatorAdapter.onUpdate has cyclomatic complexity 62 (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.
UIContextMenuInteraction.makeUIAccessoryView (cyclomatic 59) Sources/Transmission/Sources/ContextMenuAccessoryView.swift:198— UIContextMenuInteraction.makeUIAccessoryView has cyclomatic complexity 59 (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.
PresentationHostingController.viewDidLayoutSubviews (cyclomatic 57) Sources/Transmission/Sources/Hosting/PresentationHostingController.swift:32— PresentationHostingController.viewDidLayoutSubviews has cyclomatic complexity 57 (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.
PushNavigationControllerTransition.configureTransitionAnimator (cyclomatic 36) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/PushDestinationLinkTransition.swift:155— PushNavigationControllerTransition.configureTransitionAnimator has cyclomatic complexity 36 (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.
Detent.toUIKit (cyclomatic 34) Sources/Transmission/Sources/Transitions/PresentationLink Transitions/SheetPresentationLinkTransition.swift:339— Detent.toUIKit has cyclomatic complexity 34 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
DestinationLinkDelegateProxy.gestureRecognizerShouldBegin (cyclomatic 29) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1425— DestinationLinkDelegateProxy.gestureRecognizerShouldBegin has cyclomatic complexity 29 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PresentationLinkCoordinatorAdapter.present (cyclomatic 27) Sources/Transmission/Sources/PresentationLinkAdapter.swift:685— PresentationLinkCoordinatorAdapter.present 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.
InteractivePresentationController.isAtTop (cyclomatic 24) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:667— InteractivePresentationController.isAtTop 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.
UIView.swizzled_magicMorph_setCenter (cyclomatic 24) Sources/Transmission/Sources/ContextMenuAccessoryView.swift:62— UIView.swizzled_magicMorph_setCenter 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.
LuminanceTrackingReader.init (cyclomatic 22) Sources/Transmission/Sources/AdaptiveColorSchemeModifier.swift:222— LuminanceTrackingReader.init has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
DestinationLinkCoordinatorAdapter.onPop (cyclomatic 22) Sources/Transmission/Sources/DestinationLinkAdapter.swift:474— DestinationLinkCoordinatorAdapter.onPop has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PresentationLinkCoordinatorAdapter.makePresentationController (cyclomatic 22) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1336— PresentationLinkCoordinatorAdapter.makePresentationController has cyclomatic complexity 22 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
MatchedGeometryPresentationController.dismissalTransitionShouldBegin (cyclomatic 22) Sources/Transmission/Sources/Transitions/Presentation Controllers/MatchedGeometryPresentationController.swift:39— MatchedGeometryPresentationController.dismissalTransitionShouldBegin has cyclomatic complexity 22 (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.
DestinationLinkCoordinatorAdapter.onUpdate (cyclomatic 21) Sources/Transmission/Sources/DestinationLinkAdapter.swift:295— DestinationLinkCoordinatorAdapter.onUpdate has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
DestinationLinkCoordinatorAdapter.navigationController (cyclomatic 21) Sources/Transmission/Sources/DestinationLinkAdapter.swift:637— DestinationLinkCoordinatorAdapter.navigationController has cyclomatic complexity 21 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
MenuSourceViewLink_Previews.previews (cyclomatic 20) Sources/Transmission/Sources/MenuSourceViewLink.swift:518— MenuSourceViewLink_Previews.previews has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
TransitionReaderCoordinator.transitionDidChange (cyclomatic 20) Sources/Transmission/Sources/TransitionReader.swift:212— TransitionReaderCoordinator.transitionDidChange has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PassthroughView.hitTest (cyclomatic 20) Sources/Transmission/Sources/Supporting Files/PassthroughView.swift:37— PassthroughView.hitTest has cyclomatic complexity 20 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
ContextMenuLinkCoordinator.onUpdate (cyclomatic 18) Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:229— ContextMenuLinkCoordinator.onUpdate has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PresentationLinkCoordinatorAdapter.presentationControllerWillDismiss (cyclomatic 18) Sources/Transmission/Sources/PresentationLinkAdapter.swift:947— PresentationLinkCoordinatorAdapter.presentationControllerWillDismiss has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PresentationLinkCoordinatorAdapter.animationController (cyclomatic 18) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1209— PresentationLinkCoordinatorAdapter.animationController has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
InteractivePresentationController.gestureRecognizer (cyclomatic 18) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:746— InteractivePresentationController.gestureRecognizer has cyclomatic complexity 18 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PresentationLinkCoordinatorAdapter.presentationControllerShouldDismiss (cyclomatic 17) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1024— PresentationLinkCoordinatorAdapter.presentationControllerShouldDismiss has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
InteractivePresentationController.dismissalTransitionShouldBegin (cyclomatic 17) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:135— InteractivePresentationController.dismissalTransitionShouldBegin 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.
ToastPresentationControllerTransition.configureTransitionAnimator (cyclomatic 17) Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:133— ToastPresentationControllerTransition.configureTransitionAnimator has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
PopoverPresentationControllerTransition.configureTransitionAnimator (cyclomatic 17) Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:112— PopoverPresentationControllerTransition.configureTransitionAnimator has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
CrossDissolveTransitionAnimator.animateTransition (cyclomatic 17) Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:25— CrossDissolveTransitionAnimator.animateTransition has cyclomatic complexity 17 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
SlideTransitionAnimator.animateTransition (cyclomatic 17) Sources/Transmission/Sources/Transitions/View Controller Transitions/SlideTransitionAnimator.swift:26— SlideTransitionAnimator.animateTransition has cyclomatic complexity 17 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
DestinationLinkDelegateProxy.triggerHapticsIfNeeded (cyclomatic 16) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1328— DestinationLinkDelegateProxy.triggerHapticsIfNeeded has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
PresentationLinkCoordinatorAdapter.presentationController (cyclomatic 16) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1481— PresentationLinkCoordinatorAdapter.presentationController has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
GlassEffect.makeUIVisualEffect (cyclomatic 16) Sources/Transmission/Sources/VisualEffectView.swift:246— GlassEffect.makeUIVisualEffect has cyclomatic complexity 16 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
InteractivePresentationController.onPanGesture (cognitive 235) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:244— InteractivePresentationController.onPanGesture has cognitive complexity 235 (threshold 15). Drivers by points: if/else 63 (164 pts), boolean chains 38, ternaries 9 (29 pts), match/switch 2 (4 pts) (nesting depth added 123). 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.
DestinationLinkDelegateProxy.panGestureDidChange (cognitive 180) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1093— DestinationLinkDelegateProxy.panGestureDidChange has cognitive complexity 180 (threshold 15). Drivers by points: if/else 53 (143 pts), boolean chains 19, ternaries 5 (12 pts), loops 1 (5 pts), match/switch 1 (nesting depth added 101). 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.
PresentationLinkCoordinatorAdapter.onUpdate (cognitive 158) Sources/Transmission/Sources/PresentationLinkAdapter.swift:394— PresentationLinkCoordinatorAdapter.onUpdate has cognitive complexity 158 (threshold 15). Drivers by points: if/else 38 (129 pts), boolean chains 14, ternaries 3 (9 pts), match/switch 2 (6 pts) (nesting depth added 101). 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.
PresentationHostingController.viewDidLayoutSubviews (cognitive 107) Sources/Transmission/Sources/Hosting/PresentationHostingController.swift:32— PresentationHostingController.viewDidLayoutSubviews has cognitive complexity 107 (threshold 15). Drivers by points: if/else 36 (77 pts), boolean chains 28, ternaries 1 (2 pts) (nesting depth added 42). 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.
MatchedGeometryViewControllerTransitionAnimator.animateTransition (cognitive 105) Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift:39— MatchedGeometryViewControllerTransitionAnimator.animateTransition has cognitive complexity 105 (threshold 15). Drivers by points: if/else 46 (68 pts), ternaries 16 (18 pts), boolean chains 17, loops 1, match/switch 1 (nesting depth added 24). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
UIContextMenuInteraction.makeUIAccessoryView (cognitive 91) Sources/Transmission/Sources/ContextMenuAccessoryView.swift:198— UIContextMenuInteraction.makeUIAccessoryView has cognitive complexity 91 (threshold 15). Drivers by points: if/else 30 (51 pts), ternaries 5 (16 pts), boolean chains 12, match/switch 6 (12 pts) (nesting depth added 38). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PushNavigationControllerTransition.configureTransitionAnimator (cognitive 55) Sources/Transmission/Sources/Transitions/DestinationLink Transitions/PushDestinationLinkTransition.swift:155— PushNavigationControllerTransition.configureTransitionAnimator has cognitive complexity 55 (threshold 15). Drivers by points: if/else 20 (33 pts), ternaries 11 (15 pts), boolean chains 6, match/switch 1 (nesting depth added 17). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
Detent.toUIKit (cognitive 55) Sources/Transmission/Sources/Transitions/PresentationLink Transitions/SheetPresentationLinkTransition.swift:339— Detent.toUIKit has cognitive complexity 55 (threshold 15). Drivers by points: if/else 23 (44 pts), boolean chains 10, match/switch 1 (nesting depth added 21). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
UIView.swizzled_magicMorph_setCenter (cognitive 53) Sources/Transmission/Sources/ContextMenuAccessoryView.swift:62— UIView.swizzled_magicMorph_setCenter has cognitive complexity 53 (threshold 15). Drivers by points: if/else 15 (37 pts), boolean chains 10, loops 2 (6 pts) (nesting depth added 26). 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.
PresentationLinkCoordinatorAdapter.present (cognitive 46) Sources/Transmission/Sources/PresentationLinkAdapter.swift:685— PresentationLinkCoordinatorAdapter.present has cognitive complexity 46 (threshold 15). Drivers by points: if/else 24 (35 pts), boolean chains 8, loops 2 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
DestinationLinkCoordinatorAdapter.onUpdate (cognitive 45) Sources/Transmission/Sources/DestinationLinkAdapter.swift:295— DestinationLinkCoordinatorAdapter.onUpdate has cognitive complexity 45 (threshold 15). Drivers by points: if/else 10 (32 pts), boolean chains 6, ternaries 2 (4 pts), match/switch 1 (3 pts) (nesting depth added 26). 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.
DestinationLinkCoordinatorAdapter.navigationController (cognitive 41) Sources/Transmission/Sources/DestinationLinkAdapter.swift:637— DestinationLinkCoordinatorAdapter.navigationController has cognitive complexity 41 (threshold 15). Drivers by points: if/else 14 (30 pts), boolean chains 6, ternaries 2 (5 pts) (nesting depth added 19). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
DestinationLinkDelegateProxy.gestureRecognizerShouldBegin (cognitive 40) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1425— DestinationLinkDelegateProxy.gestureRecognizerShouldBegin has cognitive complexity 40 (threshold 15). Drivers by points: if/else 17 (28 pts), boolean chains 12 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PassthroughView.hitTest (cognitive 40) Sources/Transmission/Sources/Supporting Files/PassthroughView.swift:37— PassthroughView.hitTest has cognitive complexity 40 (threshold 15). Drivers by points: if/else 10 (24 pts), loops 3 (10 pts), boolean chains 5, ternaries 1 (nesting depth added 21). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
DestinationLinkCoordinatorAdapter.onPop (cognitive 38) Sources/Transmission/Sources/DestinationLinkAdapter.swift:474— DestinationLinkCoordinatorAdapter.onPop has cognitive complexity 38 (threshold 15). Drivers by points: if/else 16 (29 pts), boolean chains 9 (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.
MenuSourceViewLink_Previews.previews (cognitive 38) Sources/Transmission/Sources/MenuSourceViewLink.swift:518— MenuSourceViewLink_Previews.previews has cognitive complexity 38 (threshold 15). Drivers by points: if/else 10 (15 pts), ternaries 6 (15 pts), loops 5 (8 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.
PresentationLinkCoordinatorAdapter.presentationControllerShouldDismiss (cognitive 36) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1024— PresentationLinkCoordinatorAdapter.presentationControllerShouldDismiss has cognitive complexity 36 (threshold 15). Drivers by points: if/else 10 (28 pts), boolean chains 5, ternaries 1 (2 pts), match/switch 1 (nesting depth added 19). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
PopoverDimmingView.hitTest (cognitive 36) Sources/Transmission/Sources/Transitions/Presentation Controllers/PopoverPresentationController.swift:14— PopoverDimmingView.hitTest has cognitive complexity 36 (threshold 15). Drivers by points: if/else 7 (27 pts), loops 2 (7 pts), boolean chains 2 (nesting depth added 25). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
PresentationLinkCoordinatorAdapter.makePresentationController (cognitive 35) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1336— PresentationLinkCoordinatorAdapter.makePresentationController has cognitive complexity 35 (threshold 15). Drivers by points: if/else 10 (22 pts), match/switch 2 (6 pts), boolean chains 5, ternaries 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.
PresentationLinkCoordinatorAdapter.sheetPresentationControllerDidChangeSelectedDetentIdentifier (cognitive 35) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1526— PresentationLinkCoordinatorAdapter.sheetPresentationControllerDidChangeSelectedDetentIdentifier has cognitive complexity 35 (threshold 15). Drivers by points: if/else 14 (27 pts), ternaries 1 (4 pts), match/switch 1 (3 pts), boolean chains 1 (nesting depth added 18). 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.
TransitionReaderCoordinator.transitionDidChange (cognitive 33) Sources/Transmission/Sources/TransitionReader.swift:212— TransitionReaderCoordinator.transitionDidChange has cognitive complexity 33 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 7 (14 pts), boolean chains 4 (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.
LuminanceTrackingReader.init (cognitive 31) Sources/Transmission/Sources/AdaptiveColorSchemeModifier.swift:222— LuminanceTrackingReader.init has cognitive complexity 31 (threshold 15). Drivers by points: if/else 9 (19 pts), boolean chains 12 (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.
PresentationLinkCoordinatorAdapter.presentationControllerWillDismiss (cognitive 30) Sources/Transmission/Sources/PresentationLinkAdapter.swift:947— PresentationLinkCoordinatorAdapter.presentationControllerWillDismiss has cognitive complexity 30 (threshold 15). Drivers by points: if/else 11 (23 pts), boolean chains 7 (nesting depth added 12). 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.
ContextMenuLinkCoordinator.contextMenuPreview (cognitive 27) Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:507— ContextMenuLinkCoordinator.contextMenuPreview has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (22 pts), boolean chains 3, loops 1 (2 pts) (nesting depth added 13). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
WindowLinkCoordinatorAdapter.onUpdate (cognitive 27) Sources/Transmission/Sources/WindowLinkAdapter.swift:141— WindowLinkCoordinatorAdapter.onUpdate has cognitive complexity 27 (threshold 15). Drivers by points: if/else 8 (16 pts), boolean chains 4, ternaries 2 (4 pts), match/switch 1 (3 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
CardPresentationController.setCornerRadius (cognitive 27) Sources/Transmission/Sources/Transitions/Presentation Controllers/CardPresentationController.swift:227— CardPresentationController.setCornerRadius has cognitive complexity 27 (threshold 15). Drivers by points: if/else 9 (15 pts), ternaries 3 (9 pts), boolean chains 3 (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
InteractivePresentationController.isAtTop (cognitive 27) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:667— InteractivePresentationController.isAtTop has cognitive complexity 27 (threshold 15). Drivers by points: if/else 10 (14 pts), boolean chains 13 (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.
TransitionReaderCoordinator.transitionCoordinatorDidChange (cognitive 26) Sources/Transmission/Sources/TransitionReader.swift:159— TransitionReaderCoordinator.transitionCoordinatorDidChange has cognitive complexity 26 (threshold 15). Drivers by points: if/else 10 (21 pts), ternaries 1 (3 pts), boolean chains 2 (nesting depth added 13). To reduce it, flatten the nesting: this score is depth rather than breadth — most of its points come from checks stacked inside one another, so the work sits several levels in. Invert each enclosing check into an early exit (a return, or the language's equivalent) so the happy path stays at one level, and where a level cannot be exited early, lift the block it encloses into its own named function.
ContextMenuLinkCoordinator.onUpdate (cognitive 25) Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:229— ContextMenuLinkCoordinator.onUpdate has cognitive complexity 25 (threshold 15). Drivers by points: if/else 15 (21 pts), boolean chains 4 (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.
DestinationLinkDelegateProxy.triggerHapticsIfNeeded (cognitive 25) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1328— DestinationLinkDelegateProxy.triggerHapticsIfNeeded has cognitive complexity 25 (threshold 15). Drivers by points: if/else 10 (16 pts), boolean chains 6, ternaries 1 (2 pts), match/switch 1 (nesting depth added 7). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
PresentationLinkCoordinatorAdapter.animationController (cognitive 25) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1209— PresentationLinkCoordinatorAdapter.animationController has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (19 pts), boolean chains 5, match/switch 1 (nesting depth added 8). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
Preview.body (cognitive 25) Sources/Transmission/Sources/TransitionSourceHostingView.swift:211— Preview.body has cognitive complexity 25 (threshold 15). Drivers by points: ternaries 9 (17 pts), if/else 8 (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.
SlideTransitionAnimator.animateTransition (cognitive 25) Sources/Transmission/Sources/Transitions/View Controller Transitions/SlideTransitionAnimator.swift:26— SlideTransitionAnimator.animateTransition has cognitive complexity 25 (threshold 15). Drivers by points: if/else 11 (17 pts), ternaries 4, boolean chains 3, match/switch 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.
InteractivePresentationController.gestureRecognizer (cognitive 24) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:746— InteractivePresentationController.gestureRecognizer has cognitive complexity 24 (threshold 15). Drivers by points: if/else 11 (18 pts), boolean chains 6 (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.
GlassEffect.makeUIVisualEffect (cognitive 23) Sources/Transmission/Sources/VisualEffectView.swift:246— GlassEffect.makeUIVisualEffect has cognitive complexity 23 (threshold 15). Drivers by points: if/else 7 (15 pts), boolean chains 8 (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.
CornerMask.toCoreAnimation (cognitive 22) Sources/Transmission/Sources/Transitions/CornerRadiusOptions.swift:1000— CornerMask.toCoreAnimation has cognitive complexity 22 (threshold 15). Drivers by points: ternaries 4 (12 pts), if/else 6 (10 pts) (nesting depth added 12). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
DestinationLinkDelegateProxy.gestureRecognizer (cognitive 21) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1503— DestinationLinkDelegateProxy.gestureRecognizer has cognitive complexity 21 (threshold 15). Drivers by points: if/else 9 (15 pts), boolean chains 6 (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.
PresentationLinkCoordinatorAdapter.gestureDidChange (cognitive 21) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1646— PresentationLinkCoordinatorAdapter.gestureDidChange has cognitive complexity 21 (threshold 15). Drivers by points: if/else 10 (15 pts), boolean chains 3, match/switch 2 (3 pts) (nesting depth added 6). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
MatchedGeometryPresentationController.dismissalTransitionShouldBegin (cognitive 21) Sources/Transmission/Sources/Transitions/Presentation Controllers/MatchedGeometryPresentationController.swift:39— MatchedGeometryPresentationController.dismissalTransitionShouldBegin has cognitive complexity 21 (threshold 15). Drivers by points: boolean chains 16, if/else 5. 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.
PresentationLinkCoordinatorAdapter.presentationController (cognitive 20) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1481— PresentationLinkCoordinatorAdapter.presentationController has cognitive complexity 20 (threshold 15). Drivers by points: if/else 8 (12 pts), boolean chains 6, ternaries 1 (2 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ToastPresentationControllerTransition.configureTransitionAnimator (cognitive 20) Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:133— ToastPresentationControllerTransition.configureTransitionAnimator has cognitive complexity 20 (threshold 15). Drivers by points: if/else 6 (8 pts), match/switch 3 (5 pts), ternaries 4, boolean chains 3 (nesting depth added 4). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
PopoverPresentationControllerTransition.configureTransitionAnimator (cognitive 20) Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:112— PopoverPresentationControllerTransition.configureTransitionAnimator has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (9 pts), boolean chains 6, ternaries 4, 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.
CrossDissolveTransitionAnimator.animateTransition (cognitive 20) Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:25— CrossDissolveTransitionAnimator.animateTransition has cognitive complexity 20 (threshold 15). Drivers by points: if/else 7 (9 pts), boolean chains 5, ternaries 5, 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.
DisplayMode.isCollapsed (cognitive 20) Sources/Transmission/Sources/Extensions/UISplitViewController+Extensions.swift:11— DisplayMode.isCollapsed has cognitive complexity 20 (threshold 15). Drivers by points: ternaries 3 (11 pts), match/switch 2 (5 pts), if/else 4 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
UIViewController.swizzled_dismiss (cognitive 19) Sources/Transmission/Sources/StatusBarModifier.swift:59— UIViewController.swizzled_dismiss has cognitive complexity 19 (threshold 15). Drivers by points: if/else 7 (11 pts), loops 4 (6 pts), boolean chains 2 (nesting depth added 6). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
DestinationLinkCoordinatorAdapter.navigationController (cognitive 18) Sources/Transmission/Sources/DestinationLinkAdapter.swift:738— DestinationLinkCoordinatorAdapter.navigationController has cognitive complexity 18 (threshold 15). Drivers by points: if/else 6 (9 pts), boolean chains 5, ternaries 2 (4 pts) (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
DestinationLinkCoordinatorAdapter.gestureDidChange (cognitive 18) Sources/Transmission/Sources/DestinationLinkAdapter.swift:885— DestinationLinkCoordinatorAdapter.gestureDidChange has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 3, match/switch 1 (nesting depth added 5). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
InteractivePresentationController.triggerHapticsIfNeeded (cognitive 18) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:604— InteractivePresentationController.triggerHapticsIfNeeded has cognitive complexity 18 (threshold 15). Drivers by points: if/else 9 (14 pts), boolean chains 3, match/switch 1 (nesting depth added 5). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
SheetPresentationController.frameOfPresentedViewInContainerView (cognitive 17) Sources/Transmission/Sources/Transitions/Presentation Controllers/SheetPresentationController.swift:51— SheetPresentationController.frameOfPresentedViewInContainerView has cognitive complexity 17 (threshold 15). Drivers by points: if/else 7 (10 pts), ternaries 3 (6 pts), match/switch 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.
ViewControllerTransition.configureTransitionAnimator (cognitive 17) Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:194— ViewControllerTransition.configureTransitionAnimator has cognitive complexity 17 (threshold 15). Drivers by points: if/else 6 (8 pts), ternaries 5, boolean chains 3, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, 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.
DestinationLinkCoordinatorAdapter.navigationController (cognitive 16) Sources/Transmission/Sources/DestinationLinkAdapter.swift:803— DestinationLinkCoordinatorAdapter.navigationController has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (12 pts), match/switch 2 (3 pts), boolean chains 1 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
DestinationLinkDelegateProxy.gestureRecognizer (cognitive 16) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1586— DestinationLinkDelegateProxy.gestureRecognizer has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 3 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PresentationLinkCoordinatorAdapter.animationController (cognitive 16) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1146— PresentationLinkCoordinatorAdapter.animationController has cognitive complexity 16 (threshold 15). Drivers by points: if/else 8 (13 pts), boolean chains 2, match/switch 1 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
InteractivePresentationController.dismissalTransitionShouldBegin (cognitive 16) Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:135— InteractivePresentationController.dismissalTransitionShouldBegin has cognitive complexity 16 (threshold 15). Drivers by points: boolean chains 12, if/else 4. To reduce it, name the conditions: bind each compound test to a well-named local or a small predicate function, so the body reads as a sequence of named decisions rather than a chain of operators.
PresentationController.layoutDimmingView (cognitive 16) Sources/Transmission/Sources/Transitions/Presentation Controllers/PresentationController.swift:256— PresentationController.layoutDimmingView has cognitive complexity 16 (threshold 15). Drivers by points: if/else 7 (14 pts), boolean chains 2 (nesting depth added 7). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
PresentationControllerTransition.configureTransitionAnimator (cognitive 16) Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:28— PresentationControllerTransition.configureTransitionAnimator has cognitive complexity 16 (threshold 15). Drivers by points: if/else 6 (8 pts), ternaries 4, boolean chains 3, match/switch 1 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, 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.
D22 · Internal API Consistency· Semantic duplication with inconsistent naming. `DestinationCoordinator` uses 'pop' (navigation stack terminology) while `PresentationCoordinator` uses 'dismiss' (modal terminology). However, both classes expose identical method signatures (`pop/dismiss`, `popToRoot/dismissToRoot`, `popToView/dismissToView`) and likely share the same underlying implementation logic for stack manipulation. This forces developers to learn two different verb sets for the same conceptual action (removing items from a presentation stack). · ×1
Semantic duplication with inconsistent naming. `DestinationCoordinator` uses 'pop' (navigation stack terminology) while `PresentationCoordinator` uses 'dismiss' (modal terminology). However, both classes expose identical method signatures (`pop/dismiss`, `popToRoot/dismissToRoot`, `popToView/dismissToView`) and likely share the same underlying implementation logic for stack manipulation. This forces developers to learn two different verb sets for the same conceptual action (removing items from a presentation stack). — Unify the naming convention. If the library supports both navigation controllers and modals, consider a unified `StackCoordinator` or standardizing on one verb (e.g., `pop` for all stack-like behaviors, or `dismiss` for all presentation removals) to reduce cognitive load. (signatures: DestinationCoordinator.pop(...) | DestinationCoordinator.popToRoot(...) | DestinationCoordinator.popToView(...) | PresentationCoordinator.dismiss(...) | PresentationCoordinator.dismissToRoot(...) | PresentationCoordinator.dismissToView(...))
D22 · Internal API Consistency· Redundant types with overlapping intent. `DestinationLink`, `PresentationLink`, `MenuDialogLink`, and `ContextMenuLink` all serve as SwiftUI views that trigger a presentation action. They share nearly identical constructor signatures (transition, animation, isPresented/value bindings, destination/content, label). The distinction between 'Destination' (navigation), 'Presentation' (modal), and 'MenuDialog' (alert/action sheet) is often implementation detail rather than API surface difference, leading to API sprawl where users must choose the correct 'Link' type for the specific UIKit container, despite the SwiftUI usage pattern being identical. · ×1
Redundant types with overlapping intent. `DestinationLink`, `PresentationLink`, `MenuDialogLink`, and `ContextMenuLink` all serve as SwiftUI views that trigger a presentation action. They share nearly identical constructor signatures (transition, animation, isPresented/value bindings, destination/content, label). The distinction between 'Destination' (navigation), 'Presentation' (modal), and 'MenuDialog' (alert/action sheet) is often implementation detail rather than API surface difference, leading to API sprawl where users must choose the correct 'Link' type for the specific UIKit container, despite the SwiftUI usage pattern being identical. — Consolidate into a single `PresentationLink` or `DestinationLink` type that accepts a `PresentationStyle` or `Transition` enum to determine the underlying UIKit behavior (Navigation vs Modal vs Alert), or provide a single `Link` type that infers the behavior from the `Transition` type passed. (signatures: DestinationLink.init(...) | PresentationLink.init(...) | MenuDialogLink.init(...) | ContextMenuLink.init(...))
D22 · Internal API Consistency· Redundant Modifier types. Similar to the Link types, there are distinct Modifier types for every presentation style (`DestinationLinkModifier`, `PresentationLinkModifier`, etc.). They all wrap a view and add presentation logic. This violates the DRY principle and creates maintenance overhead. A user wanting to add a modal presentation to a view must find the specific `PresentationLinkModifier` rather than using a generic `presentation` modifier. · ×1
Redundant Modifier types. Similar to the Link types, there are distinct Modifier types for every presentation style (`DestinationLinkModifier`, `PresentationLinkModifier`, etc.). They all wrap a view and add presentation logic. This violates the DRY principle and creates maintenance overhead. A user wanting to add a modal presentation to a view must find the specific `PresentationLinkModifier` rather than using a generic `presentation` modifier. — Create a single `PresentationModifier` (or extend an existing generic one) that accepts a `PresentationStyle` or `Transition` to handle all presentation types, removing the need for separate modifier types for each UIKit presentation mode. (signatures: DestinationLinkModifier.init(...) | PresentationLinkModifier.init(...) | MenuDialogLinkModifier.init(...) | ContextMenuLinkModifier.init(...))
D4 · Code Duplication· Members sharing a duplicated core (5 members, 50+ identical tokens) · ×1
Members sharing a duplicated core (5 members, 50+ identical tokens) Sources/Transmission/Sources/DestinationLink.swift:136— Sources/Transmission/Sources/DestinationLink.swift:136-152 | Sources/Transmission/Sources/DestinationSourceViewLink.swift:171-191 | Sources/Transmission/Sources/PresentationLink.swift:138-154 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:172-192 | Sources/Transmission/Sources/WindowLink.swift:145-163 — These 5 members share a duplicated core: a run of at least 50 identical tokens appears in every one of them. That run is NOT broken out as duplicated-block rows below — it is what admitted this row, and the blocks below cover only the part of it that clears the block floor, so they understate the correspondence. Read the members as one construct written 5 times. The repair is at the members' grain — factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Extracting the individual blocks below is not the same fix: it leaves every body in place and the next edit still has to be made 5 times.
Duplicated block (31 lines × 2) Sources/Transmission/Sources/MenuSourceViewLink.swift:814— Sources/Transmission/Sources/MenuSourceViewLink.swift:814-844 | Sources/Transmission/Sources/MenuSourceViewLink.swift:848-878 — 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 `Sources/Transmission/Sources/MenuSourceViewLink.swift:814` 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 (23–28 lines × 2) Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:170— Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:170-192 | Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransitionAnimator.swift:30-57 — 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 `Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:170` 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–23 lines × 4) Sources/Transmission/Sources/DestinationLinkAdapter.swift:898— Sources/Transmission/Sources/DestinationLinkAdapter.swift:898-919 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:1349-1371 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:1668-1689 | Sources/Transmission/Sources/Transitions/Presentation Controllers/InteractivePresentationController.swift:616-638 — there are 4 copies across 3 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/DestinationLinkAdapter.swift:898` 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 (23 lines × 3) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1629— Sources/Transmission/Sources/DestinationLinkAdapter.swift:1629-1651 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:1656-1678 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:1683-1705 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/DestinationLinkAdapter.swift:1629` 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 (22 lines × 2) Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:141— Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:141-162 | Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:35-56 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 62 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 `Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:141` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (21 lines × 3) Sources/Transmission/Sources/DestinationLinkAdapter.swift:1529— Sources/Transmission/Sources/DestinationLinkAdapter.swift:1529-1549 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:1564-1584 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:1604-1624 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/DestinationLinkAdapter.swift:1529` 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–20 lines × 2) Sources/Transmission/Sources/PresentationLinkAdapter.swift:1149— Sources/Transmission/Sources/PresentationLinkAdapter.swift:1149-1168 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:1211-1229 — 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 `Sources/Transmission/Sources/PresentationLinkAdapter.swift:1149` 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 (15–18 lines × 3) Sources/Transmission/Sources/DestinationLinkAdapter.swift:181— Sources/Transmission/Sources/DestinationLinkAdapter.swift:181-198 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:182-199 | Sources/Transmission/Sources/TransitionLinkAdapter.swift:197-211 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once.
Duplicated block (16–17 lines × 2) Sources/Transmission/Sources/TransitionSourceHostingView.swift:215— Sources/Transmission/Sources/TransitionSourceHostingView.swift:215-230 | Sources/Transmission/Sources/TransitionSourceHostingView.swift:232-248 — 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 `Sources/Transmission/Sources/TransitionSourceHostingView.swift:215` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (15–16 lines × 3) Sources/Transmission/Sources/TransitionSourceHostingView.swift:216— Sources/Transmission/Sources/TransitionSourceHostingView.swift:216-230 | Sources/Transmission/Sources/TransitionSourceHostingView.swift:233-247 | Sources/Transmission/Sources/TransitionSourceHostingView.swift:249-264 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/TransitionSourceHostingView.swift:216` 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 after the matched lines, `Sources/Transmission/Sources/TransitionSourceHostingView.swift:231` calls `rounded` and `Sources/Transmission/Sources/TransitionSourceHostingView.swift:265` 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 (15 lines × 3) Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:148— Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:148-162 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:144-158 | Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:42-56 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 62 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 `Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:148` 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 × 3) Sources/Transmission/Sources/DestinationSourceViewLink.swift:114— Sources/Transmission/Sources/DestinationSourceViewLink.swift:114-127 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:115-128 | Sources/Transmission/Sources/WindowLink.swift:171-184 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:114` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it.
Duplicated block (13 lines × 4) Sources/Transmission/Sources/DestinationLinkAdapter.swift:109— Sources/Transmission/Sources/DestinationLinkAdapter.swift:109-121 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:129-141 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:110-122 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:130-142 — there are 4 copies across 2 file(s) — more copies than files, so at least one file holds the block twice. Extract it once into a single shared function every call site can reach and call it from all 4 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/DestinationLinkAdapter.swift:109` 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 (12–13 lines × 2) Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:178— Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:178-189 | Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:62-74 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 62 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 `Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:178` 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 (9–10 lines × 3) Sources/Transmission/Sources/DestinationSourceViewLink.swift:198— Sources/Transmission/Sources/DestinationSourceViewLink.swift:198-206 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:199-207 | Sources/Transmission/Sources/WindowLink.swift:169-178 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:198` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (9–10 lines × 2) Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:108— Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:108-117 | Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:135-143 — 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 `Sources/Transmission/Sources/ContextMenuSourceViewLink.swift:108` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (9 lines × 5) Sources/Transmission/Sources/DestinationLink.swift:51— Sources/Transmission/Sources/DestinationLink.swift:51-59 | Sources/Transmission/Sources/DestinationSourceViewLink.swift:71-79 | Sources/Transmission/Sources/PresentationLink.swift:53-61 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:72-80 | Sources/Transmission/Sources/WindowLink.swift:53-61 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/DestinationSourceViewLink.swift` as WHOLE FILES: 87% of the shorter file's lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 3 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it — treat the file pair as the unit. 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 `Sources/Transmission/Sources/DestinationLink.swift:51` 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 (8–9 lines × 5) Sources/Transmission/Sources/DestinationLink.swift:138— Sources/Transmission/Sources/DestinationLink.swift:138-146 | Sources/Transmission/Sources/DestinationSourceViewLink.swift:175-182 | Sources/Transmission/Sources/PresentationLink.swift:140-148 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:176-183 | Sources/Transmission/Sources/WindowLink.swift:148-155 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/DestinationSourceViewLink.swift` as WHOLE FILES: 87% of the shorter file's lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 3 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it — treat the file pair as the unit. 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 `Sources/Transmission/Sources/DestinationLink.swift:138` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (9 lines × 4) Sources/Transmission/Sources/DestinationSourceViewLink.swift:55— Sources/Transmission/Sources/DestinationSourceViewLink.swift:55-63 | Sources/Transmission/Sources/DestinationSourceViewLink.swift:73-81 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:56-64 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:74-82 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:55` 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 (8 lines × 5) Sources/Transmission/Sources/DestinationLink.swift:175— Sources/Transmission/Sources/DestinationLink.swift:175-182 | Sources/Transmission/Sources/DestinationSourceViewLink.swift:220-227 | Sources/Transmission/Sources/PresentationLink.swift:177-184 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:221-228 | Sources/Transmission/Sources/WindowLink.swift:189-196 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLink.swift` and `Sources/Transmission/Sources/DestinationSourceViewLink.swift` as WHOLE FILES: 87% of the shorter file's lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 3 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it — treat the file pair as the unit. 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 `Sources/Transmission/Sources/DestinationLink.swift:175` 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 (8 lines × 4) Sources/Transmission/Sources/DestinationSourceViewLink.swift:223— Sources/Transmission/Sources/DestinationSourceViewLink.swift:223-230 | Sources/Transmission/Sources/DestinationSourceViewLink.swift:246-253 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:224-231 | Sources/Transmission/Sources/PresentationSourceViewLink.swift:247-254 — before extracting anything, compare `Sources/Transmission/Sources/DestinationSourceViewLink.swift` and `Sources/Transmission/Sources/PresentationSourceViewLink.swift` as WHOLE FILES: this scan already matched 20 separate duplicated blocks between them, totalling at least 272 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 `Sources/Transmission/Sources/DestinationSourceViewLink.swift:223` 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 (6–8 lines × 3) Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:33— Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:33-40 | Sources/Transmission/Sources/Transitions/View Controller Transitions/MatchedGeometryViewControllerTransition.swift:48-53 | Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:202-209 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. 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. 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 (5–8 lines × 3) Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:25— Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:25-32 | Sources/Transmission/Sources/Transitions/View Controller Transitions/SlideTransitionAnimator.swift:26-33 | Sources/Transmission/Sources/Transitions/View Controller Transitions/ViewControllerTransition.swift:197-201 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 3 call sites, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `Sources/Transmission/Sources/Transitions/View Controller Transitions/CrossDissolveTransitionAnimator.swift:25` 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 (3–7 lines × 3) Sources/Transmission/Sources/DestinationLinkAdapter.swift:361— Sources/Transmission/Sources/DestinationLinkAdapter.swift:361-367 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:609-611 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:632-638 — 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 `Sources/Transmission/Sources/PresentationLinkAdapter.swift:609` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (5 lines × 4) Example/Example/DynamicIslandTransition.swift:169— Example/Example/DynamicIslandTransition.swift:169-174 | Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift:135-140 | Sources/Transmission/Sources/Transitions/PresentationLink Transitions/PopoverPresentationLinkTransition.swift:114-119 | Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift:30-34 — before extracting anything, compare `Sources/Transmission/Sources/Transitions/Presentation Controllers/ToastPresentationController.swift` and `Sources/Transmission/Sources/Transitions/View Controller Transitions/PresentationControllerTransition.swift` as WHOLE FILES: this scan already matched 5 separate duplicated blocks between them, totalling at least 62 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 `Example/Example/DynamicIslandTransition.swift:169` 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 (5 lines × 3) Sources/Transmission/Sources/DestinationLinkAdapter.swift:353— Sources/Transmission/Sources/DestinationLinkAdapter.swift:353-357 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:603-607 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:624-628 — 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 `Sources/Transmission/Sources/DestinationLinkAdapter.swift:353` 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 (66 lines × 2) Sources/Transmission/Sources/DestinationLinkModifier.swift:285— Sources/Transmission/Sources/DestinationLinkModifier.swift:285-350 | Sources/Transmission/Sources/WindowLinkModifier.swift:310-375 — 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 (81 lines × 2) Sources/Transmission/Sources/DestinationLinkPath.swift:15— Sources/Transmission/Sources/DestinationLinkPath.swift:15-121 | Sources/Transmission/Sources/PresentationLinkPath.swift:25-105 — before extracting anything, compare `Sources/Transmission/Sources/DestinationLinkPath.swift` and `Sources/Transmission/Sources/PresentationLinkPath.swift` as WHOLE FILES: 89% of the shorter file's lines also appear in the other, so this reads as one file having been copied from the other rather than as a helper waiting to be extracted. The 1 duplicated block(s) this scan matched between them are fragments of that copy, not the extent of it — treat the file pair as the unit. 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 `Sources/Transmission/Sources/DestinationLinkPath.swift:15` 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 (8 lines × 8) Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:129— Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:129-136 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:200-207 | Sources/Transmission/Sources/MenuLink.swift:129-136 | Sources/Transmission/Sources/MenuSourceViewLink.swift:253-260 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:201-208 | Sources/Transmission/Sources/TransitionLinkAdapter.swift:213-220 | Sources/Transmission/Sources/TransitionSourceHostingView.swift:319-326 | Sources/Transmission/Sources/VisualEffectView.swift:513-520 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 8 call sites, so a change lands once.
Duplicated block (7 lines × 8) Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:138— Sources/Transmission/Sources/ContextMenuLinkAdapter.swift:138-144 | Sources/Transmission/Sources/DestinationLinkAdapter.swift:209-215 | Sources/Transmission/Sources/MenuLink.swift:138-144 | Sources/Transmission/Sources/MenuSourceViewLink.swift:262-268 | Sources/Transmission/Sources/PresentationLinkAdapter.swift:210-216 | Sources/Transmission/Sources/TransitionLinkAdapter.swift:222-228 | Sources/Transmission/Sources/TransitionSourceHostingView.swift:328-334 | Sources/Transmission/Sources/VisualEffectView.swift:522-528 — the copies sit in sibling files of one directory, so a shared home is within easy reach: extract the block into a single shared function the call sites can all reach — a file they already depend on, or a new one alongside them — and call it from all 8 call sites, so a change lands once. ★ These copies have DRIFTED, and that is worth reading before extracting anything: just after the matched lines, `Sources/Transmission/Sources/DestinationLinkAdapter.swift:217` calls `_modifyBridgedViewInputs`, `bridgeHostingView` and `Sources/Transmission/Sources/TransitionSourceHostingView.swift:335` 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.
Near-duplicate member pair (122 shared lines) Example/Example/DestinationLinkExamples.swift:58— Example/Example/DestinationLinkExamples.swift:58-306 | Example/Example/PresentationLinkExamples.swift:92-502 — These two members are variants of one another: 122 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· Edited copy of a member (33 corresponding lines) · ×1
Edited copy of a member (33 corresponding lines) Example/Example/PresentationLinkExamples.swift:92— Example/Example/PresentationLinkExamples.swift:92-502 | Example/Example/PresentationLinkExamples.swift:612-690 — These two members are one piece of code written twice and then edited apart: 33 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 (33 lines × 2) Example/Example/PresentationLinkExamples.swift:465— Example/Example/PresentationLinkExamples.swift:465-497 | Example/Example/PresentationLinkExamples.swift:655-687 — 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 `Example/Example/PresentationLinkExamples.swift:465` 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 after the matched lines, `Example/Example/PresentationLinkExamples.swift:498` calls `buttonStyle`, `frame` and `Example/Example/PresentationLinkExamples.swift:688` 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 (17–19 lines × 2) Example/Example/PresentationLinkExamples.swift:252— Example/Example/PresentationLinkExamples.swift:252-268 | Example/Example/PresentationLinkExamples.swift:271-289 — 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 `Example/Example/PresentationLinkExamples.swift:252` it runs out through the closing brace of the declaration holding it and carries on into the declaration that follows — the window is the tail of one member plus the head of the next, so no call can be substituted for those exact lines, and the smallest declaration that contains all of them is the type they sit in. The repeated unit is the member each site sits in: where those members' bodies are the same, move one whole member to the shared location and have the others delegate to it; where the copies are a run of near-identical overloads or wrappers that differ only in their signatures, the repetition IS the run — a one-line delegation has no helper inside it to lift — so generate the run from the set it enumerates, or accept it and keep each member's own documentation with it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (17 lines × 3) Example/Example/DestinationLinkExamples.swift:167— Example/Example/DestinationLinkExamples.swift:167-183 | Example/Example/PresentationLinkExamples.swift:252-268 | Example/Example/PresentationLinkExamples.swift:271-287 — before extracting anything, compare `Example/Example/DestinationLinkExamples.swift` and `Example/Example/PresentationLinkExamples.swift` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 105 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 `Example/Example/DestinationLinkExamples.swift:167` 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 (16 lines × 4) Example/Example/DestinationLinkExamples.swift:203— Example/Example/DestinationLinkExamples.swift:203-218 | Example/Example/DestinationLinkExamples.swift:234-249 | Example/Example/DestinationLinkExamples.swift:267-282 | Example/Example/PresentationLinkExamples.swift:421-436 — before extracting anything, compare `Example/Example/DestinationLinkExamples.swift` and `Example/Example/PresentationLinkExamples.swift` as WHOLE FILES: this scan already matched 7 separate duplicated blocks between them, totalling at least 105 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 `Example/Example/DestinationLinkExamples.swift:203` 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.
Documentation: no architecture or design documentation README.md— The document does not mention any architecture or design documentation for Transmission. Add a short Architecture section describing the bridging layer, dependency graph, and how UIKit presentation APIs are exposed to SwiftUI.
D26 · Project Cohesion· Projects may be oversized for their cohesion · ×1
Projects may be oversized for their cohesion — 1 of 1 project(s) overshoot their size bounds, lowering Project Cohesion to 0.0/10. The most over is `(repository root)` (31116 LoC, 220 public types across 9 directories). Review these for cohesion — draw the boundary inside the module first (group each responsibility into its own package or directory and keep the cross-boundary members non-public), since splitting a published package moves types between packages and breaks consumers.
No tests found — No test suite could be collected — no discoverable tests to count. If this repository does test, wiring the suite to a framework a runner can collect (XCTest or Swift Testing) is what makes it countable here; a pipeline step that invokes a runner is not evidence on its own, because a runner over an empty suite passes. Tests written as plain executables or shell/PowerShell harnesses are not collectible this way and are not scored here.
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.
M2 · Architecture documentation· No architecture diagram/doc · ×1
No architecture diagram/doc — No C4/Structurizr/PlantUML/Mermaid/Graphviz/D2 diagram, no drawn diagram named for the architecture, no file named `architecture` or `design` in any markup this check reads, and nothing in the README, docs or contributor guides that announces the shape — no `## Architecture` heading, no "architecture overview"/"high-level design" phrasing, no "the architecture is …" introduction, no guided code tour. A shape laid out in prose that never names itself as the architecture is not visible to this check, and neither is one kept outside the repository, so this row reports the absence of a re-findable shape document — not evidence that nobody wrote the shape down.
README/code drift — README advertises Docker containerisation, but no Dockerfile/compose file exists — searched for: `dockerfile`, `docker-compose`, `compose.yaml`, `compose.yml`. Each was matched case- and separator-insensitively against file and directory NAMES anywhere in the tree, and against the CONTENTS of manifest files (package.json, *.csproj, *.props, *.slnx, *.yml, Dockerfile); the README's own prose never counts, so a claim is never refuted by merely being made. Nothing outside that search was read — a footprint living only in a submodule, in a file type not listed here, or under a name none of those terms matches is not seen, and this row is then wrong.
No SAST — No static application security testing detected. For this repository's stack, add CodeQL's Swift pack (Swift/Xcode) (or `semgrep --config=auto`, which runs on any language) as a CI step. What was searched, so you can tell an absence from a miss: the 2441 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
No 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.)
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.
none (dependency manifest found, not scanned for vulnerabilities here)
—
none (dependency manifest found, not scanned for vulnerabilities here): not applicable — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Swift Package.swift/Package.resolved — not scanned yet).
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 23 file(s) — `Example/Example/DestinationLinkExamples.swift`, `Example/Example/PresentationLinkExamples.swift`, `Example/Example/QuickLookPreviewLinkExamples.swift`, `Example/Example/ShareSheetLinkExamples.swift`, `Example/Example/StatusBarAppearanceExamples.swift`, … (+18 more) — 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.
none (dependency manifest found, not scanned for vulnerabilities here)
—
none (dependency manifest found, not scanned for vulnerabilities here): not applicable — Not scored — no dependency manifest in a supported ecosystem was read for this repository. A gap in the analyzer's language coverage, NOT a finding that the repository is free of vulnerable dependencies (a Swift Package.swift/Package.resolved — not scanned yet).
0
—
Run 01a0f7ad-8d97-71de-a20f-a123aebbed7a · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.
Issues: 4 · Warnings: 304 · Recommendations: 9 — Appendix A · all findings · full markdown report.
Generated by Watchdog — deterministic code-health analysis. 01-10-2026 @ 13:35 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.