Public report — github-mcp-server, published 6 Aug 2026.
Concrete security findings (CVE IDs, secret matches, dependency versions) are hidden in this version;
ask the repo owner for the full report.
370findings with an exact file:lineof 379 — the remainder are repo-wide signals (a dimension-level measurement, not a single line); open any file:line and verify
42/106dimensions across the health lenses40154 LoC — wide & deep
Executive summary
Read through the Production lens — the standard calibration. *Green* means good enough to run in production. The score is absolute and comparable across repos.
github/github-mcp-server carries serious gaps (49%). Several issues below can materially affect correctness, security, or the cost of changing it — and propagate to everything that depends on it.
It is strongest in Architecture (100%) — the structure is clean and changes stay contained.
The area that most needs attention is Code Health (41%) — changes there are slower and more error-prone. Accessibility (48%) is the next concern — it raises ongoing delivery and operational cost.
Leadership focus, highest impact first: Break down the listed branch-heavy functions (Cyclomatic Complexity); each oversized file along the responsibilities already in it (Large Files); Extract the duplicated blocks into shared functions/components (Code Duplication).
For scale: Medium (~40,154 production lines); rebuilding it from scratch would take roughly ~0.7 person-years (~1–2 engineers). Approximate, ±~30%.
It builds on a genuinely strong Architecture foundation (100%); the priorities above are the highest-leverage way to bring the rest up to that level.
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.
Raise Code Health 41 → 70 (the Healthy floor) ⇒ headline 49 → ~55.
Code composition — where the lines go
Tests 100%
New since the last scan (100+)
182 finding(s) are new versus the previous scan (2026-07-29) — surfaced by this scheduled scan itself, no pull request required. Showing the first 100; the full set is in the report.
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 49% 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.7 person-years of build effort (about ~€97,000 to rebuild). Its weakest lens is Code Health at 41% — the part of that asset most exposed by the findings below.
How we model this: boilerplate at a scaffolding rate + logic × domain Standard (×1.2) — CQRS × 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
Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5.
Value concentrated against a weak lens · High · Value at risk
This is a Medium asset (~0.7 person-years to rebuild), and its weakest lens is Code Health at 41%. The operational and business risk on an asset this size concentrates there — that's where remediation buys the most protection.
→ Direct remediation budget at Code Health first — highest risk-reduction per euro on an asset this size.
The top fix pays for itself · High · Economics
The top-ranked fix costs roughly 3–10 engineer-days once. Not doing it costs about 42–251.8 engineer-days every year, paid as drag on the ~221,815 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–3 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 8–17% 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: 54,694 line(s) changed over a 90-day window ⇒ ~221,815/year · D1/D2/D4 code quality: averaging 5.0/10 ⇒ a 8–17% drag on each change · top-ranked remediation: Medium effort ⇒ about 3–10 engineer-day(s)
→ Do the top-ranked fix now if this code will still be yours in 3 months.
Highest-leverage move · Medium · Leverage
Of everything flagged, the best return on effort is: Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5. The rest can wait behind it.
Evidence: priority ranking: top of 5 ranked by impact/effort
→ Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5.
A velocity tax on every change · Medium · Economics
The code-quality signals (complexity, duplication, cohesion) average 5.0/10, which acts as a tax on every change in the weaker areas: modifications there plausibly cost on the order of 8–17% more than in clean code, and the tax compounds as the codebase grows. (A modelled estimate, not a measured fact.)
Evidence: D1/D2/D4 code quality: averaging 5.0/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
35 modules, 34 dependencies — 1 dependency cycle, shown as the red cell(s) above the diagonal. 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.)
At a glance — Code Health · 41% · Weak · gated by D2, R2, R3
Findings mapped to OWASP categories; the specific CVEs/secrets are in the Security dimension cards below and findings.md (redacted only on the public version of this report).
OWASP category
Findings
Severity
A03:2021 — Injection
37
High / Critical
A06:2021 — Vulnerable & Outdated Components
7
High / Critical
A05:2021 — Security Misconfiguration
4
High / Critical
Roadmap
First, reduce cyclomatic complexity by breaking down the most branch-heavy functions to improve readability and maintainability. Next, split the four largest files into smaller, focused modules to align with existing responsibilities. Then, extract duplicated code blocks into shared functions or components to eliminate redundancy. After that, ensure every form control and button has a proper programmatic label to improve accessibility. Finally, fix page structure by adding semantic HTML elements, maintaining heading order, and removing deprecated meta-refresh tags.
Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.
Do this
Helps
Effort
Dimension
Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5.
Enforce accessibility in the toolchain: add eslint-plugin-jsx-a11y, then assert with your test runner's axe binding (jest-axe, vitest-axe, cypress-axe or @axe-core/playwright) in tests, then gate axe/pa11y/Lighthouse in CI.
Stamp a version in your build/package manifest (e.g. csproj <Version>, package.json, pyproject.toml, Cargo.toml, or a VERSION file) or tag releases with semver so builds and releases are traceable.
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. 40 of 42 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); 2 documentation/naming judgement(s) are LLM-assisted and labelled advisory. Overall confidence is 0.6 — 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 — 42 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, 370 of 379 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.
D30 Dependency Vulnerabilities — scanner not present in this environment — The backing tool was not installed where this scan ran, so this dimension was not scored. Install the tool (or run in the hosted environment, where it is always present) for a graded result.
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 (jscpd) — 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.
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.
D16 Bus Factor: Bus-factor is a time-decayed model of commit attribution (who has recently, repeatedly worked a file), not comprehension — pairing, review and reading-without-committing spread knowledge it can't see; bot commits and shared accounts still distort it.
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.
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.
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").
D31 IaC & Container Security: IaC scanning checks Dockerfiles/Terraform/Kubernetes against best-practice rules — it cannot see the live cloud account, runtime configuration, or drift between the committed config and what is actually deployed.
D33 JS/npm Dependency Vulnerabilities: JS/npm CVE matching reads package manifests and lockfiles — risk from how a dependency is used, and advisories not yet published, fall outside this scan.
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.
AC1 Text alternatives: Alt-text is detected structurally — the scan sees that an alternative EXISTS, not whether it meaningfully describes the image, and decorative-vs-missing is judged by attribute shape; runtime-injected images and a non-role=img decorative svg are out of scope. This is accessibility readiness, never a WCAG conformance claim.
AC2 Forms & labels: Label association is read from static markup — a label wired up at runtime (JS-set aria-labelledby, framework-injected ids) reads as missing, a present label says nothing about whether its text is correct. A known UI-library field component (e.g. a JSX <TextField>) is now checked conservatively — flagged only when it carries NO label/aria-label/aria-labelledby/id/name — but wrapper/context-labelled libraries (Chakra/Radix FormControl+FormLabel) aren't statically visible (possible false positive) and non-JSX lowercased components are still skipped. A clean result is "no unlabelled native control found", not a labelling proof.
AC3 Page structure: Page structure is read from the static markup tree — landmarks, headings and lang injected at runtime aren't seen, heading ORDER is checked structurally (not against the rendered visual hierarchy), and lang/title/main fire only on full documents, never partials, and the data-table check sees header-cell presence (a <th> exists), not whether each header correctly associates with its cells. Static readiness, not conformance.
AC6 Visual & motion safety: Contrast and motion safety are PARTIAL by construction — literal colours (hex/rgb/hsl/named) in inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS top-level declarations are read (same-rule/same-element colour+background pairs only); computed/runtime/theme colour, external-CDN stylesheets, CSS-in-JS dynamic (${…}) and nested-selector colours, cross-element pairs and image contrast stay out of reach, so a clean result is bounded by what the static CSS itself shows.
AC7 A11y enforcement: Enforcement is scored from in-repo config/CI evidence only — an a11y gate enforced in external tooling with no in-repo trace can't be credited, and a configured linter is presence, not proof the rules actually run or block a merge.
M4 Documentation accuracy: Onboarding quality is an LLM read of the docs/setup present — it cannot run the onboarding or measure how long a real new joiner takes; the verdict is sampled and advisory.
P4 Deployment & Rollback: Approval/branch-protection rules live in repository settings the scan cannot see — only their in-repo evidence (config files, workflows) is checked, so a control enforced purely in the host's settings reads as "not evidenced".
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 (3): D19, D21, M4 (model: Local LLM). For these, a model reads a bounded sample and sets the numeric score (documentation, ADR quality, naming, comment value, onboarding) — D25 sets the ADR-conformance fraction over sampled code, D22 judges API accuracy over a sample. These 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.
+ 54 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 1 github.GetFileBlame (cyclomatic 50) finding(s) in Cyclomatic Complexity — start with repositories.go. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 github.UpdatePullRequest (cyclomatic 46) finding(s) in Cyclomatic Complexity — start with pullrequests.go. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 github.UpdateIssue (cyclomatic 43) finding(s) in Cyclomatic Complexity — start with issues.go. — 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.
+ 76 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 1 github.UpdateIssue (cognitive 80) finding(s) in Cognitive Complexity — start with issues.go. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 github.UpdatePullRequest (cognitive 68) finding(s) in Cognitive Complexity — start with pullrequests.go. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 github.GranularSetIssueFields (cognitive 64) finding(s) in Cognitive Complexity — start with issues_granular.go. — 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 Classes8.7 / 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 11 FileTooLong finding(s) in God Classes — start with issues.go, repositories.go, pullrequests.go. — One of this dimension's main actionable groups (11 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.
+ 39 more group(s) — more in Appendix A; the complete list is findings.md.
What to do
Resolve the 17 Duplicated block (10 lines × 2) finding(s) in Code Duplication — start with copilot.go (2), issues.go (2), repositories.go (2). — One of this dimension's main actionable groups (17 warning-level).
Resolve the 17 Duplicated block (9 lines × 2) finding(s) in Code Duplication — start with issues.go (3), repositories.go (3), pullrequests.go (2). — One of this dimension's main actionable groups (17 warning-level).
Resolve the 17 Duplicated block (8 lines × 2) finding(s) in Code Duplication — start with issues.go (4), repositories.go (3), issues_granular.go (2). — One of this dimension's main actionable groups (17 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 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.
Detailed fixes: d15_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
D16 · Bus Factor9.4 / 10Exemplary✓ Tool-verified
What it measures: Whether knowledge is concentrated in too few people (the "bus factor").
Method: Living knowledge per author via time-decayed commit attribution (6-month half-life, focus weighting) across largest source files. Deterministic, avoids blame's mechanical-refactor false positives.
6 source file(s) have their living knowledge concentrated in one author (≥90% of recent, decayed contribution). The largest is internal/oauth/manager.go.
Off-boarding risk: anonymized user #1
Further sole-owners (lower concentration)
✓ On the Gold path — maintain.
Detailed fixes: d16_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether the project's documentation is clear, complete, and useful.
Method: Judged by language model at low temperature (0.0-0.1) on a deterministic doc sample (READMEs plus first 25 architecture docs), with two-pass stability filtering. Advisory, sampled.
The GitHub MCP Server project is well documented: the README and a dedicated installation-guides directory cover every host application (Copilot CLI, Antigravity, Claude, Cline, Cursor, Gemini, Codex, OpenCode, Roo Code, Windsurf, Xcode), support by host-application tables, and a comprehensive toolsets-and-icons guide. The e2e test README explains the gated e2e build flag, an example of a diff that changes a tool's login to return foobar, and debugging steps for failing tests. A dedicated testing document covers unit-testing patterns (testify/require), snapshot comparison with toolsnaps, and CI validation. Streamable HTTP mode is detailed with scope-challenge and OAuth metadata discovery examples, while the server-configuration guide lists every configuration option and explains composable defaults. The documentation is clear, complete, and well structured. The GitHub MCP Server documentation is comprehensive and well-structured: the READMEs cover PAT scope filtering, remote server setup, OAuth login, insiders features, host integration, and feature flags; architecture/design docs explain the Model Context Protocol (MCP) standard, authentication modes, security considerations, and scoped toolsets. The PAT Scope Filtering document gives a clear working definition of how scopes are used to hide tools at startup versus how OAuth scope challenges work for remote servers, with a comparison table contrasting classic PATs vs fine-grained OAuth tokens. All the outlined sections appear in the full text. The GitHub MCP server documentation is clear and complete: four README-style installation guides cover Zed, Xcode, Windsurf, Roo Code, Copilot IDEs, and OpenCode for local and remote setup (with Docker/CLI instructions), plus a dedicated error-handling document. The content is well-organized by topic into an outline that every named section appears in; the visible text covers prerequisites, configuration examples, authentication flows, and troubleshooting with clipped trailing sections not flagged as missing.
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.
What it measures: Whether any secrets were ever committed — scanned across the full git history, not just now.
Method: Git-history secret scan via gitleaks detect over full history in an isolated checkout; each match flagged High. Exhaustive; degrades cleanly when tool absent.
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).
High: github-actions-mutable-action-tag · ×37.github/actions/build-ui/action.yml:9detected by semgrep finding
What to do
Resolve the 37 High finding(s) in Static Analysis (SAST) — start with code-scanning.yml (8), license-check.yml (4), mcp-diff.yml (4). — One of this dimension's main actionable groups (37 issue-level).
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.
6 of 91 significant source file(s) are orphaned — their living knowledge has decayed to nothing, so no one currently understands them. The largest is internal/githubv4mock/githubv4mock.go.
Further orphaned files (smaller)
✓ On the Gold path — maintain.
Detailed fixes: d34_recommendation.md · top locations in Appendix A, every location in findings.md.
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; coupling through a build step, config, or non-source file isn't seen.
What it measures: Whether the build pipeline provides supply-chain integrity — generated provenance/attestation, signed artifacts (cosign/sigstore), an SBOM, and pinned build actions. Presence of the configuration, not a runtime guarantee.
Method: Supply-chain provenance/signing read deterministically from CI/build config (.github/workflows, .gitlab-ci.yml, azure-pipelines, Jenkinsfile, .circleci) + the release surface: four signals — generated provenance/attestation (SLSA/in-toto/actions-attest), artifact signing (cosign/sigstore/gitsign), an SBOM (syft/sbom-action/*.spdx.json/*.cdx.json), and SHA-pinned build actions — scored 10·present/denom. NotApplicable without a build pipeline. Detects configuration presence, not runtime enforcement.
Resolve the 1 Unpinned build actions finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 warning-level).
Resolve the 1 No SBOM finding(s) in Supply-chain Provenance & Signing. — One of this dimension's main actionable groups (1 recommendation-level).
Detailed fixes: d36_recommendation.md · top locations in Appendix A, every location in findings.md.
What it measures: Whether the repository publishes a coordinated-vulnerability-disclosure policy (SECURITY.md or security.txt) with a reporting contact, so finders know how to report a vulnerability. Presence of a policy file with a contact, not whether the policy is adequate or honoured.
Method: Vulnerability-disclosure policy read deterministically from the repo: a SECURITY.md (root/.github/docs) or .well-known/security.txt / security.txt, regex-checked for a reporting contact (email / URL / mailto). Present + contact → 10; present without a contact → 4; NotApplicable when no policy file exists (it may live off-repo). Detects the policy file's presence + contact, not its adequacy.
What it measures: Whether dependencies have known published vulnerabilities (CVEs) per the OSV database — read natively from whatever lockfile the repository ships (Cargo, npm, Go, Python, Maven, RubyGems, …). D33 and D30 add ecosystem-specific scanners on top for npm and .NET.
Method: Multi-ecosystem dependency-CVE scan via osv-scanner --recursive (queries the osv.dev database + parses lockfiles natively across ecosystems: npm package-lock/yarn/pnpm/bun, Go go.mod, Rust Cargo.lock, Maven/Gradle pom.xml/gradle.lockfile, PyPI requirements.txt/poetry.lock/Pipfile.lock, Composer composer.lock, RubyGems Gemfile.lock, Hex mix.lock, pub pubspec.lock, Swift Package.resolved); severity tally (Critical/High/Medium/Low) to 0-10 tight normalizer (8.0). NotApplicable only when the repo declares no supported non-.NET dependency lockfile (a NuGet-only repo stays NotApplicable — .NET CVEs are D30's domain); coverage needs a resolved lockfile. Additive to D33 (trivy fs); exhaustive + deterministic, DB kept fresh.
High CVE: [GHSA redacted] · ×2ui/package-lock.jsondetected by osv-scanner finding
High vulnerability: [GHSA redacted]ui/package-lock.jsondetected by osv-scanner finding
Medium CVE: GO-2026-5942 · ×3go.moddetected by osv-scanner finding
Medium vulnerability: [GHSA redacted]ui/package-lock.jsondetected by osv-scanner finding
What to do
Resolve the 2 High CVE finding(s) in OSV Dependency Vulnerabilities — start with package-lock.json (2). — One of this dimension's main actionable groups (2 issue-level).
Resolve the 1 High vulnerability finding(s) in OSV Dependency Vulnerabilities — start with package-lock.json. — One of this dimension's main actionable groups (1 issue-level).
Resolve the 3 Medium CVE finding(s) in OSV Dependency Vulnerabilities — start with go.mod (2), package-lock.json. — One of this dimension's main actionable groups (3 warning-level).
Detailed fixes: d38_recommendation.md · top locations in Appendix A, every location in findings.md.
Do you agree with this assessment?
Frontend & cross-cutting dimensions
R = React/JS · M = Maturity · P = Readiness.
AC1 · Text alternatives10.0 / 10Exemplary○ Nothing flagged
Other · Accessibility — Whether non-text content carries a text alternative — img/area/input[type=image] have alt, a meaningful svg has a title or aria-label, video has a captions track, and object/embed/canvas have a name or fallback content. Static markup readiness, not a WCAG conformance claim.
Method: Static markup-model scan: every img/area/input[type=image] checked for alt, svg[role=img] for a title/aria-label, video for a captions <track>. Components skipped, spreads suppressed. Deterministic, hard fact per element.
Do you agree with this assessment?
AC2 · Forms & labels1.8 / 10Critical✓ Tool-verified
Other · Accessibility — Whether form controls have a programmatic label (an associated label, aria-label or aria-labelledby), buttons have text, links have an accessible name, fieldsets have a non-empty legend, known UI-library field components carry a label prop, and a placeholder isn't used as the only label. Static markup readiness, not a WCAG conformance claim.
Method: Static markup-model scan: inputs/selects/textareas checked for an associated label[for]/wrapping label/aria-label/aria-labelledby (per document), buttons for accessible text, fieldsets for a legend; placeholder-only labelling flagged. Deterministic, hard fact per control.
This UI-library field component has no label / aria-label / aria-labelledby / id / name — and neither does anything it renders — so it likely renders an unlabelled control. Name it whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed. — App.tsx:1197
This UI-library field component is named only by a placeholder — a placeholder is not a label (it vanishes as soon as the user types, and many assistive technologies ignore it). Give it a real name whichever way this library supports: a label prop, an aria-label, or an id on the rendered control with a <label htmlFor> pointing at it. For a group of controls, name the group itself (aria-label, or a fieldset with a legend) — labelling each item leaves the set unnamed. (×13) — App.tsx:1272, App.tsx:1349, App.tsx:1385, …
This control has only a placeholder — a placeholder is not a label (it vanishes on input and many AT ignore it). Add a <label htmlFor>, a wrapping <label>, or aria-label. — MarkdownEditor.tsx:312
What to do
Give every control a programmatic label (a <label for> / wrapping <label> / aria-label) and every button text — a placeholder is not a label.
Do you agree with this assessment?
AC3 · Page structure4.5 / 10Weak✓ Tool-verified
Other · Accessibility — Whether pages declare a language (well-formed BCP-47) and a non-empty title, expose exactly one main landmark and a sane heading order with non-empty headings, keep zoom enabled, title their iframes, give data tables header cells, and avoid meta-refresh. Static markup readiness, not a WCAG conformance claim.
Method: Static markup-model scan: html lang, document <title>, a main landmark and heading order on full documents only, plus zoom-disabling viewports, untitled iframes and meta-refresh anywhere. Deterministic, per structural checkpoint.
No <main> (or role="main") means no "skip to content" target and a weaker landmark map. Wrap the primary content in <main>. (×7) — error.html:2, success.html:2, .placeholder.html:4, …
The page declares no language, so assistive tech can't pick the right pronunciation. Add lang (e.g. lang="en"). — .placeholder.html:4
A page with no <title> gives no name in the tab, history or screen-reader page list. Add a descriptive <title> in <head>. — .placeholder.html:4
What to do
Declare <html lang>, a document <title> and a <main> landmark, keep headings in order, leave zoom enabled, title iframes and drop meta-refresh.
Other · Accessibility — Whether focus outlines aren't removed without a replacement, motion respects prefers-reduced-motion, and literal CSS colour pairs meet contrast — PARTIAL: inline styles, in-repo <style> blocks, in-repo .css files, var() tokens, Tailwind neutral utilities and CSS-in-JS literals are read (hex/rgb/hsl/named), never computed/runtime/external-CDN colour. Static markup readiness, not a WCAG conformance claim.
Method: Static markup/CSS scan: inline outline:none/0, literal inline colour/background contrast against the 4.5:1 AA floor, and <style>-block animation without a prefers-reduced-motion guard. Deterministic but PARTIAL — only inline styles and in-repo CSS literals are visible.
Do you agree with this assessment?
AC7 · A11y enforcement4.0 / 10Weak✓ Tool-verified
Other · Accessibility — Whether accessibility is ENFORCED in the toolchain — an accessibility checker configured over the markup (an a11y lint rule set, e.g. eslint-plugin-jsx-a11y or vuejs-accessibility where the project lints JavaScript) and an automated accessibility assertion wired into tests or CI (axe/pa11y/Lighthouse or an equivalent) — on the Documented→Verified→Prevented ladder.
Method: Repo config/CI scan: an accessibility checker configured over the markup (an a11y lint rule set such as eslint-plugin-jsx-a11y / vuejs-accessibility where JavaScript is linted) and an automated accessibility assertion in tests or CI (axe/pa11y/Lighthouse or equivalent), graded on the Documented→Verified→Prevented rungs. Deterministic, presence/rung detection.
No accessibility enforcement found — no a11y linter (eslint-plugin-jsx-a11y) and no axe/pa11y/Lighthouse in tests or CI. Start with the linter to catch issues at author time.
What to do
Enforce accessibility in the toolchain: add eslint-plugin-jsx-a11y, then assert with your test runner's axe binding (jest-axe, vitest-axe, cypress-axe or @axe-core/playwright) in tests, then gate axe/pa11y/Lighthouse in CI.
Other · Architecture — Whether the codebase has a recognisable, scale-appropriate structure (a named architectural style, or modular enough for its size) rather than being an ad-hoc ball of mud.
Method: Roslyn plus csproj analysis: architecture style detection (DDD, clean, vertical-slice, CQRS) and structure fitness for repo size. Deterministic.
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.
Add a README to the 1 of 1 project(s) that lack one — worth up to 2 pts.
Maturity · Maturity — Whether key decisions (ADRs) and the high-level shape (C4/diagrams) are written down.
Method: Filesystem scan: ADR folder/naming conventions or content, plus Mermaid/PlantUML/C4/architecture.md discovery. Exhaustive, deterministic.
No Architecture Decision Records found — no conventional ADR directory, no `NNNN-title.md` documents and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
What to do
Record significant decisions one document per decision — dated, stating the context, the decision and its consequences — and keep them together wherever your design docs already live (a conventional `docs/adr/` tree with `NNNN-title.md` names is the most discoverable form).
Maturity · Maturity — Whether the README actually describes the code that exists (LLM-judged, advisory).
Method: Judged by language model at low temperature: README accuracy versus actual projects, within a disclosed tolerance. Advisory, not a measured number.
README claims VS Code insiders install but the local GitHub MCP Server is documented
What to do
Reconcile the README with reality: README claims VS Code insiders install but the local GitHub MCP Server is documented.
Readiness · Readiness — Whether SAST, secret/dependency scanning and performance benchmarking are wired in (presence, not runtime).
Method: Filesystem scan: SAST configuration, dependency-update automation, secret scanning, and a benchmark harness or benchmark step — in this repository's own ecosystem. Exhaustive, deterministic.
What to do
Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
Readiness · Readiness — Whether releases are automated and safely reversible (probes, rolling updates, approval gates) — from manifests/pipeline files, not the live environment.
Method: Filesystem scan: deployment manifests/IaC (K8s YAML, Helm, Terraform) for rolling updates, probes, approval gates, migration hooks. Exhaustive, deterministic.
Readiness · 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.
What to do
Stamp a version in your build/package manifest (e.g. csproj <Version>, package.json, pyproject.toml, Cargo.toml, or a VERSION file) or tag releases with semver so builds and releases are traceable.
Do you agree with this assessment?
R1 · Type Safety9.0 / 10Exemplary✓ Tool-verified
React / JS · Code Health — How much of the frontend is typed TypeScript vs untyped JavaScript.
Method: Frontend file inventory: the share of typed TypeScript vs untyped JavaScript across the source tree. Deterministic, exhaustive over frontend files.
What to do
Migrate the remaining .js/.jsx files to TypeScript.
React / JS · Code Health — Copy-pasted token-identical blocks across the frontend (the D4 clone algorithm over JS/TS tokens, D-386).
Method: Copy-pasted token-identical blocks across the frontend (the D4 clone algorithm run over JS/TS tokens). Deterministic.
ui/src/apps/issue-write/App.tsx:296 · ui/src/apps/pr-edit/App.tsx:169 · ui/src/apps/pr-write/App.tsx:82 — the 3 copies are spread across 3 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — App.tsx:296
ui/src/components/MarkdownEditor.tsx:231 · ui/src/components/MarkdownEditor.tsx:247 — 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. — MarkdownEditor.tsx:231
ui/src/apps/issue-write/App.tsx:348 · ui/src/apps/pr-edit/App.tsx:218 · ui/src/apps/pr-write/App.tsx:134 — the 3 copies are spread across 3 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — App.tsx:348
ui/src/apps/issue-write/App.tsx:1240 · ui/src/apps/pr-write/App.tsx:482 — the 2 copies are spread across 2 files, and what repeats is a LIST OF ENTRIES rather than behaviour — the same names written out more than once. Extract them into one shared, exported constant and spread that constant into each site, rather than into a function the sites call: a list like this often lives in declarative metadata (a decorator's options object, a static configuration table) that a build step must be able to read statically, where a function call is not allowed. Adding an entry to one copy and not the other is the failure this prevents. — App.tsx:1240
ui/src/apps/pr-edit/App.tsx:153 · ui/src/apps/pr-write/App.tsx:66 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — App.tsx:153
ui/src/apps/pr-edit/App.tsx:192 · ui/src/apps/pr-write/App.tsx:105 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — App.tsx:192
ui/src/apps/pr-edit/App.tsx:720 · ui/src/apps/pr-write/App.tsx:723 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — App.tsx:720
ui/src/apps/issue-write/App.tsx:491 · ui/src/apps/pr-write/App.tsx:284 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — App.tsx:491
What to do
Extract the duplicated blocks into shared functions/components.
React / JS · Code Health — Per-function cyclomatic/cognitive complexity from the token-level function scanner (D-386) — real branching, not a regex heuristic.
Method: Per-function cyclomatic/cognitive complexity from a token-level function scanner (real branching, not a regex heuristic), computed over every frontend function. Deterministic.
Branch-heavy code is where defects cluster — extract decisions into smaller functions. (×8) — App.tsx:1208, App.tsx:164, App.tsx:981, …
What to do
Break down the listed branch-heavy functions; aim P95 cyclomatic ≤ 5.
Do you agree with this assessment?
R3 · Large Files0.0 / 10Critical✓ Tool-verified
React / JS · Code Health — How many source files exceed the large-file threshold.
Method: Components/modules exceeding the large-file threshold, counted exhaustively across the frontend source tree. Deterministic.
4 file(s) over 400 lines (counted as significant lines — blank lines excluded — over production source only, tests excluded), largest first: ui/src/apps/issue-write/App.tsx (1603), ui/src/apps/pr-write/App.tsx (776), ui/src/apps/pr-edit/App.tsx (714), ui/src/components/MarkdownEditor.tsx (426).
What to do
Split each oversized file along the responsibilities already in it, into smaller focused modules in the same package.
Do you agree with this assessment?
R4 · Test Coverage0.0 / 10Critical✓ Tool-verified
React / JS · Readiness — Static test reachability (D-386): the share of production files reachable from any test via the import graph — measured without running anything.
Method: Static test reachability: the share of production files reachable from any test via the import graph — measured without running anything. Deterministic.
0% of 10 production file(s) reachable from 0 test file(s) via the import graph
What to do
Add tests that import the unreached modules (directly or through their public entry).
React / JS · Readiness — How outdated the npm dependencies are (a maturity signal). JS/npm CVEs are scored separately in D33 (JS/npm Dependency Vulnerabilities).
Method: npm dependency staleness from manifest/registry metadata (a maturity signal; JS/npm CVEs are scored separately in D33). Deterministic.
What to do
Bump outdated dependencies to current versions to limit upgrade debt.
Do you agree with this assessment?
R6 · Tooling6.6 / 10Adequate✓ Tool-verified
React / JS · Readiness — Whether the project wires up test, lint and typecheck — detected from each package.json script's COMMAND (eslint / tsc / vitest / jest / playwright), not just its name, and corroborated against CI-workflow invocations so a tool run only in CI still counts.
Method: package.json scanned for test/lint/typecheck script wiring. Deterministic presence check.
test ✗ · lint ✓ · typecheck ✓
What to do
Add a test runner (vitest / jest / playwright) as package.json scripts and run them in CI.
Do you agree with this assessment?
R7 · Dead Code10.0 / 10Exemplary✓ Tool-verified
React / JS · Code Health — Files unreachable from every application/tooling/test entry point, and exports nothing imports (module-graph reachability, D-386).
Method: Dead code: files unreachable from every application/tooling/test entry point plus exports nothing imports, via module-graph reachability. Deterministic, exhaustive over the import graph.
React / JS · Readiness — npm dependency truthfulness (D-386): unused dependencies, imports not declared anywhere, and type-/test-only packages shipped as production deps.
Method: npm dependency truthfulness: unused dependencies, imports declared nowhere, and type-/test-only packages shipped as production deps — from the manifest + import graph. Deterministic.
Imported only as a TYPE and declared in no reachable package.json. The import is erased at compile time, so nothing is installed and no runtime resolution depends on it — but type-checking a clean clone will fail. Declare the typings it resolves through (or the package itself) in the owning package.json. — useMcpApp.ts:8
What to do
Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.
React / JS · Architecture — Import cycles in the module graph (D-386) — files that can only be understood and changed together.
Method: Import cycles in the module graph, detected exhaustively over JS/TS imports (the same cycle detection as the .NET coupling dimension). Deterministic.
Do you agree with this assessment?
WCAG coverage — what static analysis assessed
Statically assessed 13 of 55 WCAG 2.2 Level A/AA success criteria (24%; ≈26% of the 50 WCAG 2.1 AA criteria for EN 301 549). The other 42 require runtime or manual evaluation. Partial signal only (a clean result is necessary, not sufficient; static analysis fully verifies none). This is accessibility readiness, not a conformance claim — a WCAG conformance claim requires manual evaluation (WCAG-EM 1.0).
The score is the rank-weighted fold of these lenses (worst-heaviest), each including its meta-dimensions; a lens with a Critical contributor is capped at Fair (its band reads "gated by …") and is never the strongest area however high its average.
Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Not included — 64 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.
AC4 Keyboard semantics — No interactive element found in the parsed markup — AC4 not applicable here.
AC5 ARIA correctness — No ARIA usage found in the parsed markup — AC5 not applicable here.
AX1 Captive dependencies — no DI registrations detected
AX10 Code composition — not assessed — code composition is computed by ROLE over a document set that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
AX2 Stateful singletons — no singleton implementations detected
AX3 Project dependency cycles — not assessed — project cycles and dependency direction are computed over a project-reference graph 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
AX4 Dependency direction — not applicable to a CQRS architecture (the inward-dependency rule is for layered/clean styles)
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 — not assessed — test isolation is computed from a project graph (which projects are test projects, and what they reference) 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
AX9 CQS / query purity — no CQRS query handlers detected — query purity is not applicable to this codebase
AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
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.
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.
D10 Test Quality — ~47859 lines of test source are present (.go) but the test-quality collector reads C# only, so skipped/assertion-free tests couldn't be counted. Not scored — this is a gap in the analyzer, not a finding about this repository.
D11 Test Reliability — Test reliability not included
D12 Dependency Hygiene — Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
D14 License Compliance — Not scored — this repository's package manifest is not parsed for licence data yet. A gap in the analyzer's language coverage, NOT a finding that the repository's licenses are compliant (a Go module (go.mod/go.sum) and package.json), which this pass does not parse yet — so this dimension asserts nothing about this repository's licensing in either direction.
D17 Explicit Debt — explicit-debt markers are read through a C# workspace today, so they were not read for this repository's language — this asserts nothing about how many markers the code carries. Not scored — this is a gap in the analyzer, not a finding about this repository
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.
D22 Internal API Consistency — No exposed public API
D23 Boundary Type-Coupling — Production source is present (.go, .ts, .tsx) but bounded contexts are resolved over the C#/VB project set, which exposed none, so context scope could not be assessed. Not scored — this is a gap in the analyzer, not a verdict about this repository. Declaring the codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed — see the recommendation on this dimension for where. 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
D26 Project Cohesion — Project cohesion is assessed over the .NET project set; this target exposed no projects, so project size and spread could not be assessed. Not scored — this is a gap in the analyzer's reach, not a verdict about this repository.
D27 Navigability — No calls could be sampled, so navigability was not assessed — tracing effort is measured over resolved call sites and this target exposed none. Not scored — this is a gap in the analyzer's reach, not a verdict about this repository.
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 Go module (go.mod/go.sum) and package.json — not scanned yet) — where an OSV-supported manifest exists, dependency vulnerabilities for this repository are reported under D38 instead.
D32 Data Compliance (PII/GDPR) — No PII/GDPR-handling patterns detected (p/gdpr ruleset) — no data-compliance surface to assess.
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.
D5 Coupling — Inter-project coupling could not be assessed — no analyzable project graph was found for this repository. Not scored: a gap in the analyzer's reach, not a verdict about this repository. (Coupling here is Martin afferent/efferent/instability plus reference cycles across a project-reference graph, read today from .NET project files; other ecosystems' module graphs are not read yet.)
D6 Cohesion (LCOM4) — Cohesion (LCOM4) is measured over a C#/VB class graph, and this repository's production source is mostly .go, .ts, .tsx, which this pass does not read, so cohesion was not assessed for this repository. Not scored — this is a gap in the analyzer, not a finding about this repository.
D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
D8 Code Coverage — Coverage not included — suite not readable by the collector
D9 Test Distribution — Test source is present (.go) but the test-pyramid classifier reads C# only, so its unit/integration/BDD/E2E split couldn't be counted. Not scored — this is a gap in the analyzer, not a finding about this repository.
DM1 Domain Modelling — not scored — this repository shows none of the 2 signals this check looks for
ED1 Event-Driven — not scored — this repository shows only 1 of the 3 signals this check looks for (1 CQRS handler(s))
ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this check looks for
GD1 Unfinished & placeholder code — no source files
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, 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 — Observability was not assessed: this check reads a source model that does not carry this repository's product — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of a logging idiom this check recognises is NOT evidence that this repo lacks structured logging (it may log through its own ecosystem's logger). This is a gap in the analyzer, not a finding about this repository.
P5 DR & Backup — not evidenced — repo shows no backup/RTO/RPO controls; absence of evidence is not evidence of a working control
P7 Outbound HTTP resilience — not measured — the application kind could not be determined for this repo
P8 Schema migrations — not assessed — schema-migration practice is read from 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 (`go test -coverprofile=coverage.out ./...`) into the repo working tree before the scan — a CI step is the usual place, since the artefact is commonly gitignored, or wire coverage collection into CI, to enable this cross-layer check
PF1 Benchmark discipline — Performance was not assessed: this lens reads a source model that was not loaded for this repository, because the repository is written in a language this lens does not yet model or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository — in particular it is NOT a statement that this repo is unpackaged or performance-careless.
PF2 Allocation hygiene — Performance was not assessed: this lens reads a source model that was not loaded for this repository, because the repository is written in a language this lens does not yet model or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository — in particular it is NOT a statement that this repo is unpackaged or performance-careless.
PF3 Async & latency hygiene — Performance was not assessed: this lens reads a source model that was not loaded for this repository, because the repository is written in a language this lens does not yet model or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository — in particular it is NOT a statement that this repo is unpackaged or performance-careless.
R11 Import Boundaries — No recognizable feature-sliced/layered src layout — boundary rules not applicable.
S1 Web-Security Posture — Not assessed: these web-security controls are read from a source model (declarative annotations, request middleware, entity/column names, guard methods) that was not loaded for this repository — because the repository is written in a language this check does not yet model, or because its projects failed to load. Absence of an idiom this check recognises is NOT evidence that this repository lacks web-security controls: it may implement them entirely in its own ecosystem. This is a gap in the analyzer's language coverage, not a finding about this repository.
SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
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
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
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
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
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.
High: github-actions-mutable-action-tag .github/actions/build-ui/action.yml:9— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/cache@<40-character SHA>`. This step references `actions/cache@v5`; resolve the SHA it points at today with `gh api repos/actions/cache/commits/v5 --jq .sha`.
High: github-actions-mutable-action-tag .github/actions/build-ui/action.yml:21— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-node@<40-character SHA>`. This step references `actions/setup-node@v6`; resolve the SHA it points at today with `gh api repos/actions/setup-node/commits/v6 --jq .sha`.
High: dependabot-missing-cooldown .github/dependabot.yml:8— This Dependabot configuration does not set a cooldown period. Newly published packages can be malicious or unstable. Add a `cooldown` block with `default-days: 7` to each `package-ecosystem` entry under `updates` to wait 7 days before proposing updates to newly published package versions. Reference: https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#cooldown. This is a semgrep security-AUDIT rule reporting a POLICY that is absent or weaker than its recommendation, not an exploitable defect. Confirm whether the current setting is a deliberate decision for this repository — and apply the change where it is not; where it is (a policy your release process already enforces elsewhere, or one this repository has consciously opted out of), record the decision and leave the configuration as it is. This configuration file has 3 such entries; one cooldown decision clears them all — reported once.
High: github-actions-mutable-action-tag .github/workflows/ai-issue-assessment.yml:17— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/close-inactive-issues.yml:17— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/stale@<40-character SHA>`. This step references `actions/stale@v10`; resolve the SHA it points at today with `gh api repos/actions/stale/commits/v10 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/code-scanning.yml:44— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/code-scanning.yml:47— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: github/codeql-action/init@<40-character SHA>`. This step references `github/codeql-action/init@v4`; resolve the SHA it points at today with `gh api repos/github/codeql-action/commits/v4 --jq .sha`. `github/codeql-action/init` is hosted INSIDE the `github/codeql-action` repository (a subdirectory action or a reusable workflow), so the SHA to pin is that repository's commit — keep the full `github/codeql-action/init` path in `uses:` and query only `github/codeql-action`.
High: github-actions-mutable-action-tag .github/workflows/code-scanning.yml:64— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: github/codeql-action/start-proxy@<40-character SHA>`. This step references `github/codeql-action/start-proxy@v4`; resolve the SHA it points at today with `gh api repos/github/codeql-action/commits/v4 --jq .sha`. `github/codeql-action/start-proxy` is hosted INSIDE the `github/codeql-action` repository (a subdirectory action or a reusable workflow), so the SHA to pin is that repository's commit — keep the full `github/codeql-action/start-proxy` path in `uses:` and query only `github/codeql-action`.
High: github-actions-mutable-action-tag .github/workflows/code-scanning.yml:70— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: github/codeql-action/resolve-environment@<40-character SHA>`. This step references `github/codeql-action/resolve-environment@v4`; resolve the SHA it points at today with `gh api repos/github/codeql-action/commits/v4 --jq .sha`. `github/codeql-action/resolve-environment` is hosted INSIDE the `github/codeql-action` repository (a subdirectory action or a reusable workflow), so the SHA to pin is that repository's commit — keep the full `github/codeql-action/resolve-environment` path in `uses:` and query only `github/codeql-action`.
High: github-actions-mutable-action-tag .github/workflows/code-scanning.yml:75— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v7`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/code-scanning.yml:83— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-node@<40-character SHA>`. This step references `actions/setup-node@v7`; resolve the SHA it points at today with `gh api repos/actions/setup-node/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/code-scanning.yml:94— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: github/codeql-action/autobuild@<40-character SHA>`. This step references `github/codeql-action/autobuild@v4`; resolve the SHA it points at today with `gh api repos/github/codeql-action/commits/v4 --jq .sha`. `github/codeql-action/autobuild` is hosted INSIDE the `github/codeql-action` repository (a subdirectory action or a reusable workflow), so the SHA to pin is that repository's commit — keep the full `github/codeql-action/autobuild` path in `uses:` and query only `github/codeql-action`.
High: github-actions-mutable-action-tag .github/workflows/code-scanning.yml:97— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: github/codeql-action/analyze@<40-character SHA>`. This step references `github/codeql-action/analyze@v4`; resolve the SHA it points at today with `gh api repos/github/codeql-action/commits/v4 --jq .sha`. `github/codeql-action/analyze` is hosted INSIDE the `github/codeql-action` repository (a subdirectory action or a reusable workflow), so the SHA to pin is that repository's commit — keep the full `github/codeql-action/analyze` path in `uses:` and query only `github/codeql-action`.
High: github-actions-mutable-action-tag .github/workflows/docker-publish.yml:43— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/docker-publish.yml:90— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/cache@<40-character SHA>`. This step references `actions/cache@v6`; resolve the SHA it points at today with `gh api repos/actions/cache/commits/v6 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/docs-check.yml:17— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/docs-check.yml:23— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v7`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/go.yml:26— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/go.yml:32— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v7`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/goreleaser.yml:17— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/goreleaser.yml:23— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v7`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/goreleaser.yml:45— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/attest-build-provenance@<40-character SHA>`. This step references `actions/attest-build-provenance@v4`; resolve the SHA it points at today with `gh api repos/actions/attest-build-provenance/commits/v4 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/license-check.yml:27— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/checkout@<40-character SHA>`. This step references `actions/checkout@v7`; resolve the SHA it points at today with `gh api repos/actions/checkout/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/license-check.yml:39— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/setup-go@<40-character SHA>`. This step references `actions/setup-go@v7`; resolve the SHA it points at today with `gh api repos/actions/setup-go/commits/v7 --jq .sha`.
High: github-actions-mutable-action-tag .github/workflows/license-check.yml:73— GitHub Actions step uses a mutable tag or branch reference. Tags and branch names can be silently repointed by the action owner, enabling supply-chain attacks — as seen in the trivy-action and kics-github-action compromises. Pin the reference to a full 40-character commit SHA instead, e.g. `uses: actions/github-script@<40-character SHA>`. This step references `actions/github-script@v9`; resolve the SHA it points at today with `gh api repos/actions/github-script/commits/v9 --jq .sha`.
+ 12 more in this group — see findings.md.
D38 · OSV Dependency Vulnerabilities· High CVE · ×2
High CVE: [GHSA redacted] ui/package-lock.json— fast-uri 3.1.4: [GHSA redacted] — fast-uri is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin fast-uri to 3.1.5 with an `overrides` entry).
High CVE: [GHSA redacted] ui/package-lock.json— ip-address 10.2.0: [GHSA redacted] — ip-address is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin ip-address to 10.3.1 with an `overrides` entry). This is 1 of 3 advisories with a published fix this scan raises against ip-address 10.2.0, and their fixed versions do not agree — anything below 10.3.1 still leaves at least one of them open. Take this package to 10.3.1 or later: that is the floor for the package, not this row's target alone. This one row stands for the 3 advisories this scan raises against ip-address 10.2.0: [GHSA redacted], [GHSA redacted], [GHSA redacted].
High IaC: DS-0002 Dockerfile— Image user should not be 'root' A container that starts as root runs your process with root's capabilities inside the namespace, so a compromise of the process starts from there. The step: this image's final stage has no shell, no package manager and no `/etc/passwd`, so there is no account to create and a `USER` naming one would not resolve. Use the numeric form instead — `USER 65532:65532` before the entrypoint (65532 is the conventional nonroot uid) — and give that uid ownership of anything the process writes by copying it in with `COPY --chown=65532:65532` from the build stage, including any `VOLUME` path. Build stages that only compile can stay root; it is the stage that RUNS that needs the account. If the process genuinely requires root — it manages the container runtime, ptraces another process or opens raw devices — say so here rather than making a change that breaks it.
D38 · OSV Dependency Vulnerabilities· High vulnerability · ×1
High vulnerability: [GHSA redacted] ui/package-lock.json— postcss 8.5.15: [GHSA redacted] — postcss is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin postcss to 8.5.18 with an `overrides` entry). This is 1 of 2 advisories with a published fix this scan raises against postcss 8.5.15, and their fixed versions do not agree — anything below 8.5.23 still leaves at least one of them open. Take this package to 8.5.23 or later: that is the floor for the package, not this row's target alone. This one row stands for the 2 advisories this scan raises against postcss 8.5.15: [GHSA redacted], [GHSA redacted].
Duplicated block (10 lines × 2) pkg/github/actions.go:851— pkg/github/actions.go:851-860 | pkg/github/actions.go:901-910 — 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 `pkg/github/actions.go:851` 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 (10 lines × 2) pkg/github/copilot.go:296— pkg/github/copilot.go:296-305 | pkg/github/copilot.go:642-653 — 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 `pkg/github/copilot.go:296` 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 (10 lines × 2) pkg/github/copilot.go:904— pkg/github/copilot.go:904-913 | pkg/github/pullrequests.go:801-810 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/copilot.go:904` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (10 lines × 2) pkg/github/discussions.go:313— pkg/github/discussions.go:313-322 | pkg/github/discussions.go:425-434 — 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 `pkg/github/discussions.go:313` 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) pkg/github/issue_fields.go:139— pkg/github/issue_fields.go:139-148 | pkg/github/ui_tools.go:383-392 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (10 lines × 2) pkg/github/issues.go:1050— pkg/github/issues.go:1050-1059 | pkg/github/labels.go:195-204 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:1050` 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 (10 lines × 2) pkg/github/issues.go:1131— pkg/github/issues.go:1131-1140 | pkg/github/issues.go:1155-1168 — 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 `pkg/github/issues.go:1131` 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 (10 lines × 2) pkg/github/issues_granular.go:1611— pkg/github/issues_granular.go:1611-1620 | pkg/github/issues_granular.go:1693-1702 — 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 `pkg/github/issues_granular.go:1611` 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 (10 lines × 2) pkg/github/minimal_types.go:665— pkg/github/minimal_types.go:665-674 | pkg/github/minimal_types.go:899-908 — 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 `pkg/github/minimal_types.go:665` 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) pkg/github/projects.go:232— pkg/github/projects.go:232-241 | pkg/github/projects.go:703-712 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (10 lines × 2) pkg/github/repositories.go:516— pkg/github/repositories.go:516-525 | pkg/github/repositories.go:546-555 — 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 `pkg/github/repositories.go:516` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (10 lines × 2) pkg/github/repositories.go:1716— pkg/github/repositories.go:1716-1726 | pkg/github/repositories.go:2026-2035 — 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 that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (10 lines × 2) pkg/scopes/fetcher.go:107— pkg/scopes/fetcher.go:107-116 | pkg/http/headers/parse.go:8-17 — 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 `pkg/scopes/fetcher.go:107` 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 (10 lines × 2) pkg/github/dependabot.go:61— pkg/github/dependabot.go:61-70 | pkg/github/dependabot.go:162-171 — 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 `pkg/github/dependabot.go:162` 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 (10 lines × 2) pkg/github/gists.go:208— pkg/github/gists.go:208-217 | pkg/github/gists.go:314-323 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (10 lines × 2) pkg/github/pullrequests_granular.go:700— pkg/github/pullrequests_granular.go:700-709 | pkg/github/pullrequests_granular.go:744-753 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (10 lines × 2) pkg/github/security_advisories.go:202— pkg/github/security_advisories.go:202-211 | pkg/github/security_advisories.go:477-487 — 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 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 × 2) internal/ghmcp/server.go:278— internal/ghmcp/server.go:278-286 | pkg/http/server.go:107-115 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `internal/ghmcp/server.go:278` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (9 lines × 2) pkg/github/discussions.go:951— pkg/github/discussions.go:951-959 | pkg/github/discussions.go:986-994 — 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 `pkg/github/discussions.go:951` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (9 lines × 2) pkg/github/issue_dependencies.go:76— pkg/github/issue_dependencies.go:76-84 | pkg/github/issues.go:665-673 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (9 lines × 2) pkg/github/issues.go:1257— pkg/github/issues.go:1257-1265 | pkg/github/pullrequests.go:1248-1256 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, 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 (9 lines × 2) pkg/github/issues.go:1452— pkg/github/issues.go:1452-1460 | pkg/github/issues_granular.go:1225-1233 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (9 lines × 2) pkg/github/issues.go:1825— pkg/github/issues.go:1825-1833 | pkg/github/issues.go:1896-1905 — 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 `pkg/github/issues.go:1825` 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 (9 lines × 2) pkg/github/issues_granular.go:326— pkg/github/issues_granular.go:326-334 | pkg/github/issues_granular.go:544-552 — 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 `pkg/github/issues_granular.go:326` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (9 lines × 2) pkg/github/projects.go:470— pkg/github/projects.go:470-478 | pkg/github/projects.go:1050-1058 — 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 `pkg/github/projects.go:470` 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) pkg/github/pullrequests.go:937— pkg/github/pullrequests.go:937-947 | pkg/github/pullrequests_granular.go:205-213 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/pullrequests.go:937` 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 (9 lines × 2) pkg/github/pullrequests.go:2374— pkg/github/pullrequests.go:2374-2382 | pkg/github/pullrequests_granular.go:623-631 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/pullrequests.go:2374` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (9 lines × 2) pkg/github/repositories.go:345— pkg/github/repositories.go:345-353 | pkg/github/repositories.go:1617-1625 — 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 `pkg/github/repositories.go:345` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (9 lines × 2) pkg/github/repositories.go:476— pkg/github/repositories.go:476-485 | pkg/github/repositories.go:1105-1113 — 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 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 × 2) pkg/github/repositories.go:1177— pkg/github/repositories.go:1177-1185 | pkg/github/repositories.go:1545-1553 — 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 `pkg/github/repositories.go:1177` 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 (9 lines × 2) pkg/inventory/builder.go:293— pkg/inventory/builder.go:293-301 | pkg/inventory/builder.go:303-311 — 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 `pkg/inventory/builder.go:293` 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) pkg/github/notifications.go:84— pkg/github/notifications.go:84-92 | pkg/github/notifications.go:278-286 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (9 lines × 2) pkg/github/notifications.go:358— pkg/github/notifications.go:358-367 | pkg/github/notifications.go:438-446 — 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 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 × 2) pkg/github/secret_scanning.go:61— pkg/github/secret_scanning.go:61-70 | pkg/github/secret_scanning.go:169-177 — 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 `pkg/github/secret_scanning.go:169` 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 (8 lines × 2) internal/ghmcp/oauth.go:167— internal/ghmcp/oauth.go:167-174 | internal/ghmcp/oauth.go:240-249 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. Read the line range as the matched WINDOW rather than a finished unit: at `internal/ghmcp/oauth.go:167` 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 (8 lines × 2) pkg/github/actions.go:944— pkg/github/actions.go:944-951 | pkg/github/actions.go:1008-1015 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (8 lines × 2) pkg/github/issues.go:726— pkg/github/issues.go:726-733 | pkg/github/issues.go:836-843 — 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 `pkg/github/issues.go:726` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (8 lines × 2) pkg/github/issues.go:1244— pkg/github/issues.go:1244-1251 | pkg/github/pullrequests.go:1241-1248 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:1244` 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 (8 lines × 2) pkg/github/issues.go:1942— pkg/github/issues.go:1942-1949 | pkg/github/search_utils.go:152-159 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (8 lines × 2) pkg/github/issues.go:2705— pkg/github/issues.go:2705-2713 | pkg/github/repositories.go:1824-1831 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (8 lines × 2) pkg/github/issues_granular.go:339— pkg/github/issues_granular.go:339-346 | pkg/github/issues_granular.go:557-564 — 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 `pkg/github/issues_granular.go:339` 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) pkg/github/issues_granular.go:750— pkg/github/issues_granular.go:750-757 | pkg/github/issues_granular.go:920-927 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (8 lines × 2) pkg/github/minimal_types.go:654— pkg/github/minimal_types.go:654-661 | pkg/github/minimal_types.go:885-892 — 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 `pkg/github/minimal_types.go:654` 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) pkg/github/projects.go:272— pkg/github/projects.go:272-279 | pkg/github/projects.go:441-448 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (8 lines × 2) pkg/github/projects.go:450— pkg/github/projects.go:450-457 | pkg/github/projects.go:1032-1041 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (8 lines × 2) pkg/github/pullrequests.go:739— pkg/github/pullrequests.go:739-746 | pkg/github/pullrequests.go:1391-1398 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (8 lines × 2) pkg/github/pullrequests.go:1552— pkg/github/pullrequests.go:1552-1559 | pkg/github/pullrequests.go:1723-1730 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (8 lines × 2) pkg/github/repositories.go:464— pkg/github/repositories.go:464-471 | pkg/github/repositories.go:1097-1104 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (8 lines × 2) pkg/github/repositories.go:642— pkg/github/repositories.go:642-649 | pkg/github/gists.go:309-318 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (8 lines × 2) pkg/github/repositories.go:1277— pkg/github/repositories.go:1277-1284 | pkg/github/repositories.go:1409-1416 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (8 lines × 2) pkg/github/labels.go:57— pkg/github/labels.go:57-64 | pkg/github/labels.go:283-290 — 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 `pkg/github/labels.go:57` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (11 lines × 2) pkg/github/copilot.go:312— pkg/github/copilot.go:312-326 | pkg/github/copilot.go:682-692 — 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 `pkg/github/copilot.go:312` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (11 lines × 2) pkg/github/discussions.go:189— pkg/github/discussions.go:189-199 | pkg/github/issues.go:2742-2752 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, 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 (11 lines × 2) pkg/github/discussions.go:263— pkg/github/discussions.go:263-273 | pkg/github/discussions.go:578-588 — 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 `pkg/github/discussions.go:263` 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) pkg/github/issues.go:236— pkg/github/issues.go:236-246 | pkg/github/issues.go:2927-2937 — 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 `pkg/github/issues.go:236` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (11 lines × 2) pkg/github/issues.go:971— pkg/github/issues.go:971-981 | pkg/github/issues.go:1032-1042 — 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 `pkg/github/issues.go:971` 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) pkg/github/issues.go:2217— pkg/github/issues.go:2217-2227 | pkg/github/pullrequests.go:716-726 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:2217` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (11 lines × 2) pkg/github/issues_granular.go:85— pkg/github/issues_granular.go:85-95 | pkg/github/pullrequests_granular.go:80-90 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (11 lines × 2) pkg/github/minimal_types.go:712— pkg/github/minimal_types.go:712-722 | pkg/github/minimal_types.go:818-828 — 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 `pkg/github/minimal_types.go:712` 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 (11 lines × 2) pkg/github/params.go:328— pkg/github/params.go:328-338 | pkg/github/params.go:347-357 — 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 `pkg/github/params.go:328` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (11 lines × 2) pkg/github/projects_batch.go:689— pkg/github/projects_batch.go:689-699 | pkg/github/projects_batch.go:768-778 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (11 lines × 2) pkg/github/pullrequests.go:170— pkg/github/pullrequests.go:170-180 | pkg/github/pullrequests.go:273-283 — 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 `pkg/github/pullrequests.go:170` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (11 lines × 2) pkg/github/repositories.go:1109— pkg/github/repositories.go:1109-1119 | pkg/github/repositories.go:1716-1726 — 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) pkg/github/repositories.go:1200— pkg/github/repositories.go:1200-1210 | pkg/github/repositories.go:1562-1572 — 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 `pkg/github/repositories.go:1200` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (11 lines × 2) pkg/github/pullrequests_granular.go:98— pkg/github/pullrequests_granular.go:98-108 | pkg/github/pullrequests_granular.go:346-356 — 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 `pkg/github/pullrequests_granular.go:98` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. 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.
FileTooLong: github/issues.go pkg/github/issues.go:0— FileTooLong — 1972 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/repositories.go pkg/github/repositories.go:0— FileTooLong — 1903 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/pullrequests.go pkg/github/pullrequests.go:0— FileTooLong — 1638 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/projects.go pkg/github/projects.go:0— FileTooLong — 1365 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/minimal_types.go pkg/github/minimal_types.go:0— FileTooLong — 1241 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/issues_granular.go pkg/github/issues_granular.go:0— FileTooLong — 1191 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/actions.go pkg/github/actions.go:0— FileTooLong — 754 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/discussions.go pkg/github/discussions.go:0— FileTooLong — 743 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/copilot.go pkg/github/copilot.go:0— FileTooLong — 614 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/pullrequests_granular.go pkg/github/pullrequests_granular.go:0— FileTooLong — 599 significant lines (blank, comment-only and punctuation-only lines excluded). 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: github/projects_batch.go pkg/github/projects_batch.go:0— FileTooLong — 560 significant lines (blank, comment-only and punctuation-only lines excluded). 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.
Hotspot: pkg/github/issues.go pkg/github/issues.go— pkg/github/issues.go changed 40 times in last 90 days, max complexity 43. 7 of those changes were fix/bug commits, and the other 33 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Hotspot: pkg/github/pullrequests.go pkg/github/pullrequests.go— pkg/github/pullrequests.go changed 24 times in last 90 days, max complexity 46. 7 of those changes were fix/bug commits, and the other 17 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Hotspot: pkg/github/repositories.go pkg/github/repositories.go— pkg/github/repositories.go changed 17 times in last 90 days, max complexity 50. 2 of those changes were fix/bug commits, and the other 15 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Hotspot: pkg/github/issues_granular.go pkg/github/issues_granular.go— pkg/github/issues_granular.go changed 13 times in last 90 days, max complexity 41. Frequent change and high complexity in one file compound: schedule the next change to it to include carving out the part being edited, behind tests written first.
Hotspot: pkg/github/minimal_types.go pkg/github/minimal_types.go— pkg/github/minimal_types.go changed 19 times in last 90 days, max complexity 22. 3 of those changes were fix/bug commits, and the other 16 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Hotspot: pkg/github/projects.go pkg/github/projects.go— pkg/github/projects.go changed 11 times in last 90 days, max complexity 35. 3 of those changes were fix/bug commits, and the other 8 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Hotspot: pkg/github/search.go pkg/github/search.go— pkg/github/search.go changed 13 times in last 90 days, max complexity 17. 2 of those changes were fix/bug commits, and the other 11 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Hotspot: ui/src/apps/issue-write/App.tsx ui/src/apps/issue-write/App.tsx— ui/src/apps/issue-write/App.tsx changed 5 times in last 90 days, max complexity 43. 1 of those changes was a fix/bug commit, and the other 4 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Hotspot: ui/src/apps/pr-write/App.tsx ui/src/apps/pr-write/App.tsx— ui/src/apps/pr-write/App.tsx changed 5 times in last 90 days, max complexity 37. 1 of those changes was a fix/bug commit, and the other 4 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Hotspot: internal/ghmcp/server.go internal/ghmcp/server.go— internal/ghmcp/server.go changed 10 times in last 90 days, max complexity 16. 1 of those changes was a fix/bug commit, and the other 9 changed it for other reasons — this file is under both repair and feature pressure. Before the next change lands here, cover the area it touches with tests, 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.
Duplicated block (5 lines × 2) pkg/github/context_tools.go:256— pkg/github/context_tools.go:256-261 | pkg/github/security_advisories.go:430-434 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (5 lines × 2) pkg/github/issue_fields.go:130— pkg/github/issue_fields.go:130-134 | pkg/github/issues.go:1095-1099 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issue_fields.go:130` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) pkg/github/issues.go:2207— pkg/github/issues.go:2207-2211 | pkg/github/pullrequests.go:711-715 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:2207` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) pkg/github/projects.go:227— pkg/github/projects.go:227-231 | pkg/github/projects.go:378-382 — 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 `pkg/github/projects.go:227` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) pkg/github/pullrequests.go:715— pkg/github/pullrequests.go:715-719 | pkg/github/pullrequests.go:932-936 — 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 (5 lines × 2) pkg/github/repositories.go:336— pkg/github/repositories.go:336-340 | pkg/github/repositories.go:1608-1612 — 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 `pkg/github/repositories.go:336` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) pkg/github/repositories.go:455— pkg/github/repositories.go:455-459 | pkg/github/repositories.go:1088-1092 — 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 `pkg/github/repositories.go:455` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) pkg/github/repositories.go:1703— pkg/github/repositories.go:1703-1707 | pkg/github/repositories.go:2013-2017 — 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 `pkg/github/repositories.go:1703` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 2) pkg/github/repositories.go:2105— pkg/github/repositories.go:2105-2109 | pkg/github/gists.go:48-53 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (5 lines × 2) pkg/github/pullrequests_granular.go:398— pkg/github/pullrequests_granular.go:398-402 | pkg/github/pullrequests_granular.go:528-532 — 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 `pkg/github/pullrequests_granular.go:398` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (13 lines × 2) pkg/github/context_tools.go:68— pkg/github/context_tools.go:68-82 | pkg/github/context_tools.go:158-170 — 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 `pkg/github/context_tools.go:68` 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 (13 lines × 2) pkg/github/copilot.go:372— pkg/github/copilot.go:372-386 | pkg/github/copilot.go:739-751 — 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 `pkg/github/copilot.go:372` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (13 lines × 2) pkg/github/copilot.go:417— pkg/github/copilot.go:417-429 | pkg/github/copilot.go:770-782 — 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 `pkg/github/copilot.go:417` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (13 lines × 2) pkg/github/discussions.go:171— pkg/github/discussions.go:171-183 | pkg/github/discussions.go:1033-1045 — 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 `pkg/github/discussions.go:171` 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 (13 lines × 2) pkg/github/discussions.go:510— pkg/github/discussions.go:510-522 | pkg/github/discussions.go:552-564 — 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 `pkg/github/discussions.go:510` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (13 lines × 2) pkg/github/discussions.go:703— pkg/github/discussions.go:703-715 | pkg/github/discussions.go:806-818 — 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 `pkg/github/discussions.go:703` 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) pkg/github/discussions.go:725— pkg/github/discussions.go:725-737 | pkg/github/discussions.go:835-847 — 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 `pkg/github/discussions.go:725` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (13 lines × 2) pkg/github/notifications.go:446— pkg/github/notifications.go:446-458 | pkg/github/notifications.go:550-562 — 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 `pkg/github/notifications.go:446` 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) pkg/github/search.go:80— pkg/github/search.go:80-92 | pkg/github/search.go:576-589 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited.
Duplicated block (10 lines × 3) internal/profiler/profiler.go:91— internal/profiler/profiler.go:91-100 | internal/profiler/profiler.go:125-134 | internal/profiler/profiler.go:159-168 — all 3 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (10 lines × 3) pkg/github/issues.go:673— pkg/github/issues.go:673-683 | pkg/github/pullrequests.go:101-117 | pkg/github/code_scanning.go:176-185 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/pullrequests.go:101` 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 (10 lines × 3) pkg/github/issues_granular.go:1593— pkg/github/issues_granular.go:1593-1602 | pkg/github/issues_granular.go:1675-1684 | pkg/github/pullrequests_granular.go:814-823 — 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.
Duplicated block (10 lines × 3) pkg/github/projects.go:260— pkg/github/projects.go:260-269 | pkg/github/projects.go:419-430 | pkg/github/projects.go:734-745 — 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 `pkg/github/projects.go:260` 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 × 3) pkg/github/repositories.go:677— pkg/github/repositories.go:677-686 | pkg/github/repositories.go:1159-1168 | pkg/github/repositories.go:1183-1192 — 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 `pkg/github/repositories.go:677` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (10 lines × 3) pkg/github/repositories.go:1773— pkg/github/repositories.go:1773-1782 | pkg/github/repositories.go:1967-1977 | pkg/github/repositories.go:2053-2063 — 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 `pkg/github/repositories.go:1967` 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 (10 lines × 3) pkg/github/repositories.go:1944— pkg/github/repositories.go:1944-1953 | pkg/github/repositories.go:2250-2259 | pkg/github/repositories.go:2315-2324 — 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. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (10 lines × 3) pkg/github/search.go:247— pkg/github/search.go:247-256 | pkg/github/search.go:362-371 | pkg/github/search.go:572-581 — 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 `pkg/github/search.go:247` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (14 lines × 2) pkg/github/copilot.go:333— pkg/github/copilot.go:333-352 | pkg/github/copilot.go:699-712 — 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 `pkg/github/copilot.go:333` 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 (14 lines × 2) pkg/github/git.go:171— pkg/github/git.go:171-184 | pkg/github/repositories.go:120-133 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/git.go:171` 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) pkg/github/issues.go:857— pkg/github/issues.go:857-870 | pkg/github/issues.go:921-934 — 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 `pkg/github/issues.go:857` 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 (14 lines × 2) pkg/github/issues.go:1345— pkg/github/issues.go:1345-1358 | pkg/github/pullrequests.go:1309-1322 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:1345` 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) pkg/github/issues.go:1998— pkg/github/issues.go:1998-2011 | pkg/github/search_utils.go:176-189 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:1998` 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) pkg/github/pullrequests.go:823— pkg/github/pullrequests.go:823-836 | pkg/github/pullrequests.go:1122-1135 — 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 `pkg/github/pullrequests.go:823` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (14 lines × 2) pkg/github/labels.go:165— pkg/github/labels.go:165-178 | pkg/github/ui_tools.go:113-126 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/labels.go:165` 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 (12 lines × 2) pkg/github/params.go:47— pkg/github/params.go:47-58 | pkg/github/params.go:76-87 — 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 `pkg/github/params.go:47` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (12 lines × 2) pkg/github/projects.go:413— pkg/github/projects.go:413-424 | pkg/github/projects.go:728-739 — 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 `pkg/github/projects.go:413` 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 (12 lines × 2) pkg/github/pullrequests.go:324— pkg/github/pullrequests.go:324-335 | pkg/github/pullrequests.go:350-361 — 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 `pkg/github/pullrequests.go:324` 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. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (12 lines × 2) pkg/github/repositories.go:694— pkg/github/repositories.go:694-705 | pkg/github/repositories.go:1033-1044 — 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 `pkg/github/repositories.go:694` 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) pkg/github/repositories.go:1333— pkg/github/repositories.go:1333-1344 | pkg/github/repositories.go:1568-1579 — 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 `pkg/github/repositories.go:1333` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (12 lines × 2) pkg/github/repositories.go:1967— pkg/github/repositories.go:1967-1978 | pkg/github/repositories.go:2053-2064 — 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 `pkg/github/repositories.go:1967` 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 (12 lines × 2) pkg/github/gists.go:259— pkg/github/gists.go:259-270 | pkg/github/gists.go:368-379 — 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 `pkg/github/gists.go:259` 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 × 3) pkg/github/actions.go:334— pkg/github/actions.go:334-343 | pkg/github/actions.go:463-471 | pkg/github/actions.go:591-600 — 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.
Duplicated block (9 lines × 3) pkg/github/copilot.go:877— pkg/github/copilot.go:877-886 | pkg/github/pullrequests_granular.go:72-80 | pkg/github/pullrequests_granular.go:537-545 — 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. 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 × 3) pkg/github/issues_granular.go:314— pkg/github/issues_granular.go:314-322 | pkg/github/issues_granular.go:532-540 | pkg/github/issues_granular.go:1357-1365 — 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.
Duplicated block (9 lines × 3) pkg/github/pullrequests.go:1411— pkg/github/pullrequests.go:1411-1419 | pkg/github/repositories.go:1832-1840 | pkg/github/search.go:247-255 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/pullrequests.go:1411` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (9 lines × 3) pkg/github/code_scanning.go:56— pkg/github/code_scanning.go:56-64 | pkg/github/dependabot.go:57-65 | pkg/github/secret_scanning.go:57-65 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once.
Duplicated block (6 lines × 2) pkg/github/issues.go:1290— pkg/github/issues.go:1290-1295 | pkg/github/issues_granular.go:1685-1690 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:1290` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. 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) pkg/github/issues.go:1301— pkg/github/issues.go:1301-1306 | pkg/github/issues_granular.go:1603-1608 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:1301` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. 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) pkg/github/pullrequests.go:1273— pkg/github/pullrequests.go:1273-1278 | pkg/github/pullrequests_granular.go:824-829 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/pullrequests.go:1273` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. 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) pkg/github/gists.go:134— pkg/github/gists.go:134-139 | pkg/github/gists.go:308-313 — 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 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) pkg/github/security_advisories.go:86— pkg/github/security_advisories.go:86-91 | pkg/github/security_advisories.go:350-355 — 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 `pkg/github/security_advisories.go:86` 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 (7 lines × 2) pkg/github/issue_dependencies.go:352— pkg/github/issue_dependencies.go:352-358 | pkg/github/issues.go:1497-1507 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issue_dependencies.go:352` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (7 lines × 2) pkg/github/issues.go:1653— pkg/github/issues.go:1653-1659 | pkg/github/pullrequests.go:1663-1669 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:1653` 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 (7 lines × 2) pkg/github/issues_granular.go:66— pkg/github/issues_granular.go:66-72 | pkg/github/pullrequests_granular.go:61-67 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues_granular.go:66` 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 (7 lines × 2) pkg/github/projects.go:285— pkg/github/projects.go:285-291 | pkg/github/projects.go:480-486 — both copies are in the same file, so extract the block into one function there and call it from each site — the copies drift apart the first time only one of them is edited. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
D38 · OSV Dependency Vulnerabilities· Medium CVE · ×3
Medium CVE: GO-2026-5942 go.mod— golang.org/x/net 0.55.0 (golang.org/x/net/dns/dnsmessage): GO-2026-5942 — golang.org/x/net is not a DIRECT requirement of this module: go.mod records it as `// indirect`, pulled in transitively, so raise it in place (run `go get golang.org/x/net@v0.56.0`, which updates the require line go.mod already holds for it).
Medium CVE: GO-2026-5970 go.mod— golang.org/x/text 0.37.0 (golang.org/x/text/unicode/norm): GO-2026-5970 — golang.org/x/text is not a DIRECT requirement of this module: go.mod records it as `// indirect`, pulled in transitively, so raise it in place (run `go get golang.org/x/text@v0.39.0`, which updates the require line go.mod already holds for it).
Medium CVE: [GHSA redacted] ui/package-lock.json— hono 4.12.31: [GHSA redacted] — hono is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (or pin hono to 4.12.34 with an `overrides` entry).
Duplicated block (15 lines × 2) pkg/github/actions.go:355— pkg/github/actions.go:355-369 | pkg/github/actions.go:478-492 — 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 `pkg/github/actions.go:355` 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) cmd/github-mcp-server/generate_docs.go:399— cmd/github-mcp-server/generate_docs.go:399-413 | cmd/github-mcp-server/generate_docs.go:439-453 — 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 `cmd/github-mcp-server/generate_docs.go:399` 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 (15 lines × 2) pkg/github/security_advisories.go:283— pkg/github/security_advisories.go:283-297 | pkg/github/security_advisories.go:449-463 — 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 `pkg/github/security_advisories.go:283` 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 (5 lines × 3) pkg/github/issues_granular.go:1576— pkg/github/issues_granular.go:1576-1580 | pkg/github/issues_granular.go:1658-1662 | pkg/github/pullrequests_granular.go:797-801 — 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 `pkg/github/issues_granular.go:1576` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 3) pkg/github/repositories.go:637— pkg/github/repositories.go:637-641 | pkg/github/labels.go:48-52 | pkg/github/labels.go:267-272 — 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 `pkg/github/repositories.go:637` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 3) pkg/github/code_scanning.go:47— pkg/github/code_scanning.go:47-51 | pkg/github/dependabot.go:48-52 | pkg/github/secret_scanning.go:48-52 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/code_scanning.go:47` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (10 lines × 13) pkg/github/projects.go:1173— pkg/github/projects.go:1173-1182 | pkg/github/projects.go:1215-1224 | pkg/github/projects.go:1259-1268 | pkg/github/repositories.go:369-378 | pkg/github/repositories.go:1130-1139 | pkg/github/repositories.go:1206-1215 | pkg/github/repositories.go:1639-1648 | pkg/github/repositories.go:1730-1739 | pkg/github/repositories.go:1759-1768 | pkg/github/repositories.go:2039-2048 | pkg/github/repositories.go:2838-2847 | pkg/github/secret_scanning.go:74-83 | pkg/github/secret_scanning.go:189-198 — there are 13 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 13 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/projects.go:1173` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (10 lines × 13) pkg/github/pullrequests.go:1027— pkg/github/pullrequests.go:1027-1036 | pkg/github/pullrequests.go:1439-1448 | pkg/github/pullrequests.go:1585-1594 | pkg/github/code_scanning.go:73-82 | pkg/github/code_scanning.go:198-207 | pkg/github/dependabot.go:74-83 | pkg/github/dependabot.go:182-191 | pkg/github/notifications.go:140-149 | pkg/github/notifications.go:371-380 | pkg/github/search.go:100-109 | pkg/github/search.go:274-283 | pkg/github/search.go:392-401 | pkg/github/search.go:597-606 — there are 13 copies across 5 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 13 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/pullrequests.go:1027` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (10 lines × 4) pkg/github/dependabot.go:74— pkg/github/dependabot.go:74-83 | pkg/github/dependabot.go:182-191 | pkg/github/search.go:392-401 | pkg/github/secret_scanning.go:189-198 — 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 `pkg/github/dependabot.go:74` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register. Note that the copies do not run to the end of the range shown: their LAST lines are different code, not the same code under different names — the matched region ends inside that line. Extract the lines above it, and read the last line of each site separately.
Duplicated block (10 lines × 4) pkg/github/ui_tools.go:183— pkg/github/ui_tools.go:183-192 | pkg/github/ui_tools.go:237-246 | pkg/github/ui_tools.go:330-339 | pkg/github/ui_tools.go:468-477 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/ui_tools.go:237` 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 (8 lines × 4) pkg/github/issues_granular.go:359— pkg/github/issues_granular.go:359-366 | pkg/github/issues_granular.go:577-584 | pkg/github/issues_granular.go:762-769 | pkg/github/issues_granular.go:932-939 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
Duplicated block (8 lines × 4) pkg/github/search.go:64— pkg/github/search.go:64-71 | pkg/github/search.go:235-242 | pkg/github/search.go:354-361 | pkg/github/search.go:564-571 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited.
Duplicated block (8 lines × 3) pkg/github/issues_granular.go:742— pkg/github/issues_granular.go:742-749 | pkg/github/issues_granular.go:908-915 | pkg/github/issues_granular.go:1585-1592 — 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.
Duplicated block (8 lines × 3) pkg/github/repositories.go:212— pkg/github/repositories.go:212-219 | pkg/github/gists.go:49-58 | pkg/github/notifications.go:74-83 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, 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 (7 lines × 3) pkg/github/code_scanning.go:145— pkg/github/code_scanning.go:145-151 | pkg/github/dependabot.go:138-144 | pkg/github/secret_scanning.go:141-147 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/code_scanning.go:145` 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 (7 lines × 3) pkg/github/gists.go:98— pkg/github/gists.go:98-104 | pkg/github/gists.go:158-164 | pkg/github/notifications.go:385-395 — 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.
github.GetFileBlame (cyclomatic 50) pkg/github/repositories.go:2466— github.GetFileBlame has cyclomatic complexity 50 (threshold 15). Most of this is not in the body itself: 1 of the 50 points is its own statement and the rest belongs to one function literal inside it that branches (line 2516). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.UpdatePullRequest (cyclomatic 46) pkg/github/pullrequests.go:861— github.UpdatePullRequest has cyclomatic complexity 46 (threshold 15). Most of this is not in the body itself: 1 of the 46 points is its own statement and the rest belongs to one function literal inside it that branches (line 931). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.UpdateIssue (cyclomatic 43) pkg/github/issues.go:2411— github.UpdateIssue has cyclomatic complexity 43 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
github.GranularSetIssueFields (cyclomatic 41) pkg/github/issues_granular.go:1267— github.GranularSetIssueFields has cyclomatic complexity 41 (threshold 15). Most of this is not in the body itself: 1 of the 41 points is its own statement and the rest belongs to one function literal inside it that branches (line 1351). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.PushFiles (cyclomatic 38) pkg/github/repositories.go:1350— github.PushFiles has cyclomatic complexity 38 (threshold 15). Most of this is not in the body itself: 1 of the 38 points is its own statement and the rest belongs to one function literal inside it that branches (line 1403). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.AddIssueComment (cyclomatic 35) pkg/github/issues.go:1174— github.AddIssueComment has cyclomatic complexity 35 (threshold 15). Most of this is not in the body itself: 1 of the 35 points is its own statement and the rest belongs to one function literal inside it that branches (line 1218). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ProjectsWrite (cyclomatic 35) pkg/github/projects.go:573— github.ProjectsWrite has cyclomatic complexity 35 (threshold 15). Most of this is not in the body itself: 1 of the 35 points is its own statement and the rest belongs to one function literal inside it that branches (line 701). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularUpdateIssueState (cyclomatic 33) pkg/github/issues_granular.go:838— github.GranularUpdateIssueState has cyclomatic complexity 33 (threshold 15). Most of this is not in the body itself: 1 of the 33 points is its own statement and the rest belongs to one function literal inside it that branches (line 902). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ListIssues (cyclomatic 32) pkg/github/issues.go:2626— github.ListIssues has cyclomatic complexity 32 (threshold 15). Most of this is not in the body itself: 1 of the 32 points is its own statement and the rest belongs to one function literal inside it that branches (line 2703). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.AssignCopilotToIssueWithIntent (cyclomatic 30) pkg/github/copilot.go:502— github.AssignCopilotToIssueWithIntent has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 1 of the 30 points is its own statement and the rest belongs to one function literal inside it that branches (line 568). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GetFileContents (cyclomatic 30) pkg/github/repositories.go:723— github.GetFileContents has cyclomatic complexity 30 (threshold 15). Most of this is not in the body itself: 1 of the 30 points is its own statement and the rest belongs to one function literal inside it that branches (line 768). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.IssueWrite (cyclomatic 29) pkg/github/issues.go:2086— github.IssueWrite has cyclomatic complexity 29 (threshold 15). Most of this is not in the body itself: 1 of the 29 points is its own statement and the rest belongs to one function literal inside it that branches (line 2210). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularUpdateIssueAssignees (cyclomatic 29) pkg/github/issues_granular.go:240— github.GranularUpdateIssueAssignees has cyclomatic complexity 29 (threshold 15). Most of this is not in the body itself: 1 of the 29 points is its own statement and the rest belongs to one function literal inside it that branches (line 308). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularUpdateIssueLabels (cyclomatic 29) pkg/github/issues_granular.go:458— github.GranularUpdateIssueLabels has cyclomatic complexity 29 (threshold 15). Most of this is not in the body itself: 1 of the 29 points is its own statement and the rest belongs to one function literal inside it that branches (line 526). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ProjectsGet (cyclomatic 28) pkg/github/projects.go:312— github.ProjectsGet has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 1 of the 28 points is its own statement and the rest belongs to one function literal inside it that branches (line 381). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.CreateOrUpdateFile (cyclomatic 28) pkg/github/repositories.go:405— github.CreateOrUpdateFile has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 1 of the 28 points is its own statement and the rest belongs to one function literal inside it that branches (line 458). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ListGlobalSecurityAdvisories (cyclomatic 28) pkg/github/security_advisories.go:21— github.ListGlobalSecurityAdvisories has cyclomatic complexity 28 (threshold 15). Most of this is not in the body itself: 1 of the 28 points is its own statement and the rest belongs to one function literal inside it that branches (line 89). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.CreatePullRequest (cyclomatic 27) pkg/github/pullrequests.go:651— github.CreatePullRequest has cyclomatic complexity 27 (threshold 15). Most of this is not in the body itself: 1 of the 27 points is its own statement and the rest belongs to one function literal inside it that branches (line 714). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.completePath (cyclomatic 27) pkg/github/repository_resource_completions.go:234— github.completePath 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.
github.AddReplyToPullRequestComment (cyclomatic 26) pkg/github/pullrequests.go:1178— github.AddReplyToPullRequestComment has cyclomatic complexity 26 (threshold 15). Most of this is not in the body itself: 1 of the 26 points is its own statement and the rest belongs to one function literal inside it that branches (line 1224). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.AssignCopilotToIssue (cyclomatic 25) pkg/github/copilot.go:154— github.AssignCopilotToIssue has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 1 of the 25 points is its own statement and the rest belongs to one function literal inside it that branches (line 204). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.RepositoryResourceContentsHandler (cyclomatic 25) pkg/github/repository_resource.go:112— github.RepositoryResourceContentsHandler has cyclomatic complexity 25 (threshold 15). Most of this is not in the body itself: 1 of the 25 points is its own statement and the rest belongs to one function literal inside it that branches (line 113). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
Builder.processToolsets (cyclomatic 24) pkg/inventory/builder.go:285— Builder.processToolsets 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.
tooldiscovery.scoreTool (cyclomatic 24) pkg/tooldiscovery/search.go:101— tooldiscovery.scoreTool 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.
github.LabelWrite (cyclomatic 23) pkg/github/labels.go:222— github.LabelWrite has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to one function literal inside it that branches (line 270). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.updateProjectItemsBatch (cyclomatic 23) pkg/github/projects_batch.go:66— github.updateProjectItemsBatch has cyclomatic complexity 23 (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.
github.ListPullRequests (cyclomatic 23) pkg/github/pullrequests.go:1325— github.ListPullRequests has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to one function literal inside it that branches (line 1381). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ListCommits (cyclomatic 23) pkg/github/repositories.go:137— github.ListCommits has cyclomatic complexity 23 (threshold 15). Most of this is not in the body itself: 1 of the 23 points is its own statement and the rest belongs to one function literal inside it that branches (line 190). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
main.addCommandFromTool (cyclomatic 22) cmd/mcpcurl/main.go:205— main.addCommandFromTool has cyclomatic complexity 22 (threshold 15). Of this number, 13 points are the body's own statements and 9 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
github.minimalProjectFieldValue (cyclomatic 22) pkg/github/minimal_types.go:1131— github.minimalProjectFieldValue has cyclomatic complexity 22 (threshold 15). To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function taking that case's concrete type, so the dispatch reads one line per case. These arms are selected by TYPE rather than by value, so there is no key a lookup table could be built on; where you own the matched types, giving them one shared interface method and calling that is the form a table would have taken, and where you do not, keep the cases — they stay explicit and reviewable.
github.buildUpdateProjectItem (cyclomatic 22) pkg/github/projects.go:1618— github.buildUpdateProjectItem 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.
github.resolveIssueRequestFieldValues (cyclomatic 21) pkg/github/issues.go:303— github.resolveIssueRequestFieldValues 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.
github.DeleteFile (cyclomatic 21) pkg/github/repositories.go:1052— github.DeleteFile has cyclomatic complexity 21 (threshold 15). Most of this is not in the body itself: 1 of the 21 points is its own statement and the rest belongs to one function literal inside it that branches (line 1091). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
buffer.ProcessResponseAsRingBufferToEnd (cyclomatic 20) pkg/buffer/buffer.go:34— buffer.ProcessResponseAsRingBufferToEnd has cyclomatic complexity 20 (threshold 15). Of this number, 13 points are the body's own statements and 7 belong to 2 function literals inside it that branch. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
github.IssueDependencyWrite (cyclomatic 20) pkg/github/issue_dependencies.go:190— github.IssueDependencyWrite has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 1 of the 20 points is its own statement and the rest belongs to one function literal inside it that branches (line 252). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularUpdateIssueType (cyclomatic 20) pkg/github/issues_granular.go:683— github.GranularUpdateIssueType has cyclomatic complexity 20 (threshold 15). Most of this is not in the body itself: 1 of the 20 points is its own statement and the rest belongs to one function literal inside it that branches (line 736). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.createIterationField (cyclomatic 20) pkg/github/projects.go:1840— github.createIterationField 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.
github.resolveGitReference (cyclomatic 20) pkg/github/repositories_helper.go:207— github.resolveGitReference 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.
github.uiGetReviewers (cyclomatic 20) pkg/github/ui_tools.go:466— github.uiGetReviewers 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.
github.ListDiscussions (cyclomatic 19) pkg/github/discussions.go:128— github.ListDiscussions has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to one function literal inside it that branches (line 168). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.optionalIssueWriteFields (cyclomatic 19) pkg/github/issues.go:234— github.optionalIssueWriteFields has cyclomatic complexity 19 (threshold 15). To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
github.ProjectsList (cyclomatic 19) pkg/github/projects.go:156— github.ProjectsList has cyclomatic complexity 19 (threshold 15). Most of this is not in the body itself: 1 of the 19 points is its own statement and the rest belongs to one function literal inside it that branches (line 230). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
main.writeToolDoc (cyclomatic 18) cmd/github-mcp-server/generate_docs.go:218— main.writeToolDoc 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.
github.searchIssuesHandler (cyclomatic 18) pkg/github/issues.go:1933— github.searchIssuesHandler 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.
github.ListNotifications (cyclomatic 18) pkg/github/notifications.go:29— github.ListNotifications has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 1 of the 18 points is its own statement and the rest belongs to one function literal inside it that branches (line 67). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.convertProjectFieldValue (cyclomatic 18) pkg/github/projects_batch.go:573— github.convertProjectFieldValue 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.
github.PullRequestRead (cyclomatic 18) pkg/github/pullrequests.go:27— github.PullRequestRead has cyclomatic complexity 18 (threshold 15). Most of this is not in the body itself: 1 of the 18 points is its own statement and the rest belongs to one function literal inside it that branches (line 83). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
main.buildArgumentsMap (cyclomatic 17) cmd/mcpcurl/main.go:311— main.buildArgumentsMap 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.
github.ActionsGetJobLogs (cyclomatic 17) pkg/github/actions.go:647— github.ActionsGetJobLogs has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to one function literal inside it that branches (line 697). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.SearchRepositories (cyclomatic 17) pkg/github/search.go:22— github.SearchRepositories has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to one function literal inside it that branches (line 62). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.SearchCode (cyclomatic 17) pkg/github/search.go:195— github.SearchCode has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to one function literal inside it that branches (line 233). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
middleware.WithScopeChallenge (cyclomatic 17) pkg/http/middleware/scope_challenge.go:19— middleware.WithScopeChallenge has cyclomatic complexity 17 (threshold 15). Most of this is not in the body itself: 1 of the 17 points is its own statement and the rest belongs to one function literal inside it that branches (line 20). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
ghmcp.RunStdioServer (cyclomatic 16) internal/ghmcp/server.go:266— ghmcp.RunStdioServer has cyclomatic complexity 16 (threshold 15). Of this number, 15 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, separate the cases: extract each independent branch into its own named function, and where the body has guards that only reject input, fold those into early returns at the top.
github.GetRepositoryTree (cyclomatic 16) pkg/github/git.go:43— github.GetRepositoryTree has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to one function literal inside it that branches (line 82). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GetIssue (cyclomatic 16) pkg/github/issues.go:715— github.GetIssue 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.
github.listProjectsFromBothOwnerTypes (cyclomatic 16) pkg/github/projects.go:917— github.listProjectsFromBothOwnerTypes has cyclomatic complexity 16 (threshold 15). To reduce it, separate the branches: extract each independent case into its own named function so the top-level body reads as a short sequence of named decisions.
github.createProjectStatusUpdate (cyclomatic 16) pkg/github/projects.go:1419— github.createProjectStatusUpdate has cyclomatic complexity 16 (threshold 15). To reduce it, split the body: these branches sit side by side rather than nested inside one another, so extracting each one on its own would leave a function per branch. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
github.ListReleases (cyclomatic 16) pkg/github/repositories.go:1789— github.ListReleases has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to one function literal inside it that branches (line 1822). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ListStarredRepositories (cyclomatic 16) pkg/github/repositories.go:2073— github.ListStarredRepositories has cyclomatic complexity 16 (threshold 15). Most of this is not in the body itself: 1 of the 16 points is its own statement and the rest belongs to one function literal inside it that branches (line 2104). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.UpdateIssue (cognitive 80) pkg/github/issues.go:2411— github.UpdateIssue has cognitive complexity 80 (threshold 15). Drivers by points: if/else 58, loops 15, boolean chains 5, match/switch 2 (nesting depth added 39). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.UpdatePullRequest (cognitive 68) pkg/github/pullrequests.go:861— github.UpdatePullRequest has cognitive complexity 68 (threshold 15). Drivers by points: if/else 64, boolean chains 4 (nesting depth added 23). Most of this is not in the body itself: 0 of the 68 points are its own statements and the rest belongs to one function literal inside it that branches (line 931). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularSetIssueFields (cognitive 64) pkg/github/issues_granular.go:1267— github.GranularSetIssueFields has cognitive complexity 64 (threshold 15). Drivers by points: if/else 55, boolean chains 5, loops 3, match/switch 1 (nesting depth added 27). Most of this is not in the body itself: 0 of the 64 points are its own statements and the rest belongs to one function literal inside it that branches (line 1351). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GetFileBlame (cognitive 64) pkg/github/repositories.go:2466— github.GetFileBlame has cognitive complexity 64 (threshold 15). Drivers by points: if/else 54, boolean chains 9, loops 1 (nesting depth added 15). Most of this is not in the body itself: 0 of the 64 points are its own statements and the rest belongs to one function literal inside it that branches (line 2516). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.PushFiles (cognitive 54) pkg/github/repositories.go:1350— github.PushFiles has cognitive complexity 54 (threshold 15). Drivers by points: if/else 46, boolean chains 7, loops 1 (nesting depth added 16). Most of this is not in the body itself: 0 of the 54 points are its own statements and the rest belongs to one function literal inside it that branches (line 1403). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ProjectsWrite (cognitive 53) pkg/github/projects.go:573— github.ProjectsWrite has cognitive complexity 53 (threshold 15). Drivers by points: if/else 49, match/switch 3, boolean chains 1 (nesting depth added 24). Most of this is not in the body itself: 0 of the 53 points are its own statements and the rest belongs to one function literal inside it that branches (line 701). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.AddIssueComment (cognitive 51) pkg/github/issues.go:1174— github.AddIssueComment has cognitive complexity 51 (threshold 15). Drivers by points: if/else 44, boolean chains 6, match/switch 1 (nesting depth added 17). Most of this is not in the body itself: 0 of the 51 points are its own statements and the rest belongs to one function literal inside it that branches (line 1218). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.resolveGitReference (cognitive 49) pkg/github/repositories_helper.go:207— github.resolveGitReference has cognitive complexity 49 (threshold 15). Drivers by points: if/else 45, boolean chains 3, match/switch 1 (nesting depth added 28). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.ProjectsGet (cognitive 47) pkg/github/projects.go:312— github.ProjectsGet has cognitive complexity 47 (threshold 15). Drivers by points: if/else 45, boolean chains 1, match/switch 1 (nesting depth added 22). Most of this is not in the body itself: 0 of the 47 points are its own statements and the rest belongs to one function literal inside it that branches (line 381). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularUpdateIssueAssignees (cognitive 46) pkg/github/issues_granular.go:240— github.GranularUpdateIssueAssignees has cognitive complexity 46 (threshold 15). Drivers by points: if/else 36, loops 6, boolean chains 2, match/switch 2 (nesting depth added 19). Most of this is not in the body itself: 0 of the 46 points are its own statements and the rest belongs to one function literal inside it that branches (line 308). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularUpdateIssueLabels (cognitive 46) pkg/github/issues_granular.go:458— github.GranularUpdateIssueLabels has cognitive complexity 46 (threshold 15). Drivers by points: if/else 36, loops 6, boolean chains 2, match/switch 2 (nesting depth added 19). Most of this is not in the body itself: 0 of the 46 points are its own statements and the rest belongs to one function literal inside it that branches (line 526). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.completePath (cognitive 45) pkg/github/repository_resource_completions.go:234— github.completePath has cognitive complexity 45 (threshold 15). Drivers by points: if/else 39, boolean chains 3, loops 3 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
Builder.processToolsets (cognitive 43) pkg/inventory/builder.go:285— Builder.processToolsets has cognitive complexity 43 (threshold 15). Drivers by points: if/else 32, loops 11 (nesting depth added 19). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.buildUpdateProjectItem (cognitive 40) pkg/github/projects.go:1618— github.buildUpdateProjectItem has cognitive complexity 40 (threshold 15). Drivers by points: if/else 30, boolean chains 5, loops 4, match/switch 1 (nesting depth added 18). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
main.addCommandFromTool (cognitive 38) cmd/mcpcurl/main.go:205— main.addCommandFromTool has cognitive complexity 38 (threshold 15). Drivers by points: if/else 26, match/switch 6, loops 5, boolean chains 1 (nesting depth added 22). Of this number, 17 points are the body's own statements and 21 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
main.buildArgumentsMap (cognitive 38) cmd/mcpcurl/main.go:311— main.buildArgumentsMap has cognitive complexity 38 (threshold 15). Drivers by points: if/else 31, match/switch 6, loops 1 (nesting depth added 27). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.AssignCopilotToIssueWithIntent (cognitive 37) pkg/github/copilot.go:502— github.AssignCopilotToIssueWithIntent has cognitive complexity 37 (threshold 15). Drivers by points: if/else 32, boolean chains 2, loops 2, match/switch 1 (nesting depth added 8). Most of this is not in the body itself: 0 of the 37 points are its own statements and the rest belongs to one function literal inside it that branches (line 568). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ListIssues (cognitive 37) pkg/github/issues.go:2626— github.ListIssues has cognitive complexity 37 (threshold 15). Drivers by points: if/else 32, match/switch 3, loops 2 (nesting depth added 5). Most of this is not in the body itself: 0 of the 37 points are its own statements and the rest belongs to one function literal inside it that branches (line 2703). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GetFileContents (cognitive 36) pkg/github/repositories.go:723— github.GetFileContents has cognitive complexity 36 (threshold 15). Drivers by points: if/else 32, boolean chains 4 (nesting depth added 10). Most of this is not in the body itself: 0 of the 36 points are its own statements and the rest belongs to one function literal inside it that branches (line 768). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.CreateOrUpdateFile (cognitive 35) pkg/github/repositories.go:405— github.CreateOrUpdateFile has cognitive complexity 35 (threshold 15). Drivers by points: if/else 28, match/switch 4, boolean chains 3 (nesting depth added 11). Most of this is not in the body itself: 0 of the 35 points are its own statements and the rest belongs to one function literal inside it that branches (line 458). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.RepositoryResourceContentsHandler (cognitive 35) pkg/github/repository_resource.go:112— github.RepositoryResourceContentsHandler has cognitive complexity 35 (threshold 15). Drivers by points: if/else 31, match/switch 3, boolean chains 1 (nesting depth added 11). Most of this is not in the body itself: 0 of the 35 points are its own statements and the rest belongs to one function literal inside it that branches (line 113). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
main.writeToolDoc (cognitive 34) cmd/github-mcp-server/generate_docs.go:218— main.writeToolDoc has cognitive complexity 34 (threshold 15). Drivers by points: if/else 24, loops 4, boolean chains 3, match/switch 3 (nesting depth added 14). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.ProjectsList (cognitive 34) pkg/github/projects.go:156— github.ProjectsList has cognitive complexity 34 (threshold 15). Drivers by points: if/else 31, match/switch 3 (nesting depth added 19). Most of this is not in the body itself: 0 of the 34 points are its own statements and the rest belongs to one function literal inside it that branches (line 230). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.AssignCopilotToIssue (cognitive 33) pkg/github/copilot.go:154— github.AssignCopilotToIssue has cognitive complexity 33 (threshold 15). Drivers by points: if/else 26, loops 5, boolean chains 2 (nesting depth added 9). Most of this is not in the body itself: 0 of the 33 points are its own statements and the rest belongs to one function literal inside it that branches (line 204). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
tooldiscovery.scoreTool (cognitive 33) pkg/tooldiscovery/search.go:101— tooldiscovery.scoreTool has cognitive complexity 33 (threshold 15). Drivers by points: if/else 23, loops 8, boolean chains 2 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.IssueWrite (cognitive 32) pkg/github/issues.go:2086— github.IssueWrite has cognitive complexity 32 (threshold 15). Drivers by points: if/else 28, boolean chains 3, match/switch 1 (nesting depth added 5). Most of this is not in the body itself: 0 of the 32 points are its own statements and the rest belongs to one function literal inside it that branches (line 2210). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularUpdateIssueState (cognitive 32) pkg/github/issues_granular.go:838— github.GranularUpdateIssueState has cognitive complexity 32 (threshold 15). Drivers by points: if/else 27, boolean chains 5 (nesting depth added 4). Most of this is not in the body itself: 0 of the 32 points are its own statements and the rest belongs to one function literal inside it that branches (line 902). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.CreatePullRequest (cognitive 32) pkg/github/pullrequests.go:651— github.CreatePullRequest has cognitive complexity 32 (threshold 15). Drivers by points: if/else 30, boolean chains 2 (nesting depth added 6). Most of this is not in the body itself: 0 of the 32 points are its own statements and the rest belongs to one function literal inside it that branches (line 714). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.LabelWrite (cognitive 31) pkg/github/labels.go:222— github.LabelWrite has cognitive complexity 31 (threshold 15). Drivers by points: if/else 29, boolean chains 1, match/switch 1 (nesting depth added 12). Most of this is not in the body itself: 0 of the 31 points are its own statements and the rest belongs to one function literal inside it that branches (line 270). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
buffer.ProcessResponseAsRingBufferToEnd (cognitive 30) pkg/buffer/buffer.go:34— buffer.ProcessResponseAsRingBufferToEnd has cognitive complexity 30 (threshold 15). Drivers by points: if/else 24, loops 5, boolean chains 1 (nesting depth added 11). Of this number, 23 points are the body's own statements and 7 belong to 2 function literals inside it that branch. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.createIterationField (cognitive 30) pkg/github/projects.go:1840— github.createIterationField has cognitive complexity 30 (threshold 15). Drivers by points: if/else 23, boolean chains 4, loops 3 (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.
github.updateProjectItemsBatch (cognitive 30) pkg/github/projects_batch.go:66— github.updateProjectItemsBatch has cognitive complexity 30 (threshold 15). Drivers by points: if/else 25, loops 4, boolean chains 1 (nesting depth added 6). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, and where an else follows a branch that already returns, drop the trailing else and let the rest of the body continue at one level.
github.AddReplyToPullRequestComment (cognitive 30) pkg/github/pullrequests.go:1178— github.AddReplyToPullRequestComment has cognitive complexity 30 (threshold 15). Drivers by points: if/else 25, boolean chains 4, match/switch 1 (nesting depth added 6). Most of this is not in the body itself: 0 of the 30 points are its own statements and the rest belongs to one function literal inside it that branches (line 1224). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.resolveIssueRequestFieldValues (cognitive 29) pkg/github/issues.go:303— github.resolveIssueRequestFieldValues has cognitive complexity 29 (threshold 15). Drivers by points: if/else 20, loops 5, match/switch 4 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.optionalIssueWriteFields (cognitive 28) pkg/github/issues.go:234— github.optionalIssueWriteFields has cognitive complexity 28 (threshold 15). Drivers by points: if/else 19, boolean chains 5, loops 3, match/switch 1 (nesting depth added 11). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.convertProjectFieldValue (cognitive 28) pkg/github/projects_batch.go:573— github.convertProjectFieldValue has cognitive complexity 28 (threshold 15). Drivers by points: if/else 22, loops 3, boolean chains 2, match/switch 1 (nesting depth added 14). 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.
github.ListPullRequests (cognitive 28) pkg/github/pullrequests.go:1325— github.ListPullRequests has cognitive complexity 28 (threshold 15). Drivers by points: if/else 26, loops 2 (nesting depth added 6). Most of this is not in the body itself: 0 of the 28 points are its own statements and the rest belongs to one function literal inside it that branches (line 1381). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ListGlobalSecurityAdvisories (cognitive 28) pkg/github/security_advisories.go:21— github.ListGlobalSecurityAdvisories has cognitive complexity 28 (threshold 15). Drivers by points: if/else 28 (nesting depth added 1). Most of this is not in the body itself: 0 of the 28 points are its own statements and the rest belongs to one function literal inside it that branches (line 89). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.uiGetReviewers (cognitive 28) pkg/github/ui_tools.go:466— github.uiGetReviewers has cognitive complexity 28 (threshold 15). Drivers by points: if/else 21, loops 4, boolean chains 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.GetPullRequestReviewComments (cognitive 27) pkg/github/pullrequests.go:487— github.GetPullRequestReviewComments has cognitive complexity 27 (threshold 15). Drivers by points: if/else 22, loops 5 (nesting depth added 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.SearchRepositories (cognitive 27) pkg/github/search.go:22— github.SearchRepositories has cognitive complexity 27 (threshold 15). Drivers by points: if/else 25, loops 2 (nesting depth added 10). Most of this is not in the body itself: 0 of the 27 points are its own statements and the rest belongs to one function literal inside it that branches (line 62). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.resolveFieldFilters (cognitive 26) pkg/github/issues.go:2966— github.resolveFieldFilters has cognitive complexity 26 (threshold 15). Drivers by points: if/else 15, loops 9, match/switch 2 (nesting depth added 16). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.ListCommits (cognitive 26) pkg/github/repositories.go:137— github.ListCommits has cognitive complexity 26 (threshold 15). Drivers by points: if/else 25, loops 1 (nesting depth added 4). Most of this is not in the body itself: 0 of the 26 points are its own statements and the rest belongs to one function literal inside it that branches (line 190). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.DeleteFile (cognitive 24) pkg/github/repositories.go:1052— github.DeleteFile has cognitive complexity 24 (threshold 15). Drivers by points: if/else 24 (nesting depth added 4). Most of this is not in the body itself: 0 of the 24 points are its own statements and the rest belongs to one function literal inside it that branches (line 1091). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GetIssueComments (cognitive 23) pkg/github/issues.go:818— github.GetIssueComments has cognitive complexity 23 (threshold 15). Drivers by points: if/else 20, loops 3 (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.
github.GetSubIssues (cognitive 23) pkg/github/issues.go:878— github.GetSubIssues has cognitive complexity 23 (threshold 15). Drivers by points: if/else 21, loops 2 (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.
github.listAllProjectFields (cognitive 23) pkg/github/projects_resolver.go:82— github.listAllProjectFields has cognitive complexity 23 (threshold 15). Drivers by points: if/else 13, loops 7, match/switch 3 (nesting depth added 13). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.GetDiscussionComments (cognitive 22) pkg/github/discussions.go:393— github.GetDiscussionComments has cognitive complexity 22 (threshold 15). Drivers by points: if/else 15, loops 7 (nesting depth added 6). Most of this is not in the body itself: 0 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 427). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.searchIssuesHandler (cognitive 22) pkg/github/issues.go:1933— github.searchIssuesHandler has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, loops 2, boolean chains 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.
middleware.WithScopeChallenge (cognitive 22) pkg/http/middleware/scope_challenge.go:19— middleware.WithScopeChallenge has cognitive complexity 22 (threshold 15). Drivers by points: if/else 19, boolean chains 3 (nesting depth added 5). Most of this is not in the body itself: 0 of the 22 points are its own statements and the rest belongs to one function literal inside it that branches (line 20). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GetRepositoryTree (cognitive 21) pkg/github/git.go:43— github.GetRepositoryTree has cognitive complexity 21 (threshold 15). Drivers by points: if/else 18, loops 3 (nesting depth added 5). Most of this is not in the body itself: 0 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 82). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GetIssue (cognitive 21) pkg/github/issues.go:715— github.GetIssue has cognitive complexity 21 (threshold 15). Drivers by points: if/else 19, 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.
github.ListNotifications (cognitive 21) pkg/github/notifications.go:29— github.ListNotifications has cognitive complexity 21 (threshold 15). Drivers by points: if/else 20, boolean chains 1 (nesting depth added 3). Most of this is not in the body itself: 0 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 67). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
middleware.WithMCPParse (cognitive 21) pkg/http/middleware/mcp_parse.go:37— middleware.WithMCPParse has cognitive complexity 21 (threshold 15). Drivers by points: if/else 19, boolean chains 1, match/switch 1 (nesting depth added 9). Most of this is not in the body itself: 0 of the 21 points are its own statements and the rest belongs to one function literal inside it that branches (line 38). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ListDiscussions (cognitive 20) pkg/github/discussions.go:128— github.ListDiscussions has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, loops 2, boolean chains 1 (nesting depth added 1). Most of this is not in the body itself: 0 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 168). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.ListIssueTypes (cognitive 20) pkg/github/issues.go:1072— github.ListIssueTypes has cognitive complexity 20 (threshold 15). Drivers by points: if/else 20 (nesting depth added 7). Most of this is not in the body itself: 0 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 1098). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.executeBatchWrites (cognitive 20) pkg/github/projects_batch.go:248— github.executeBatchWrites has cognitive complexity 20 (threshold 15). Drivers by points: if/else 15, loops 5 (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.
github.GetPullRequestReviews (cognitive 20) pkg/github/pullrequests.go:557— github.GetPullRequestReviews has cognitive complexity 20 (threshold 15). Drivers by points: if/else 17, loops 3 (nesting depth added 9). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.SearchCode (cognitive 20) pkg/github/search.go:195— github.SearchCode has cognitive complexity 20 (threshold 15). Drivers by points: if/else 18, loops 2 (nesting depth added 4). Most of this is not in the body itself: 0 of the 20 points are its own statements and the rest belongs to one function literal inside it that branches (line 233). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
main.printResponse (cognitive 19) cmd/mcpcurl/main.go:511— main.printResponse has cognitive complexity 19 (threshold 15). Drivers by points: if/else 18, loops 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
ghmcp.RunStdioServer (cognitive 19) internal/ghmcp/server.go:266— ghmcp.RunStdioServer has cognitive complexity 19 (threshold 15). Drivers by points: if/else 16, match/switch 2, loops 1 (nesting depth added 4). Of this number, 18 points are the body's own statements and 1 belongs to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.ListReleases (cognitive 19) pkg/github/repositories.go:1789— github.ListReleases has cognitive complexity 19 (threshold 15). Drivers by points: if/else 17, loops 2 (nesting depth added 4). Most of this is not in the body itself: 0 of the 19 points are its own statements and the rest belongs to one function literal inside it that branches (line 1822). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
main.main (cognitive 18) cmd/mcpcurl/main.go:155— main.main has cognitive complexity 18 (threshold 15). Drivers by points: if/else 12, loops 5, boolean chains 1 (nesting depth added 10). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.IssueDependencyWrite (cognitive 18) pkg/github/issue_dependencies.go:190— github.IssueDependencyWrite has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, boolean chains 3. Most of this is not in the body itself: 0 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 252). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.convertToMinimalIssue (cognitive 18) pkg/github/minimal_types.go:639— github.convertToMinimalIssue has cognitive complexity 18 (threshold 15). Drivers by points: if/else 15, loops 3 (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.
github.listProjectItems (cognitive 18) pkg/github/projects.go:1025— github.listProjectItems has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, boolean chains 1, loops 1 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition, 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.
github.ListStarredRepositories (cognitive 18) pkg/github/repositories.go:2073— github.ListStarredRepositories has cognitive complexity 18 (threshold 15). Drivers by points: if/else 16, loops 2 (nesting depth added 2). Most of this is not in the body itself: 0 of the 18 points are its own statements and the rest belongs to one function literal inside it that branches (line 2104). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GranularUpdateIssueType (cognitive 17) pkg/github/issues_granular.go:683— github.GranularUpdateIssueType has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2. Most of this is not in the body itself: 0 of the 17 points are its own statements and the rest belongs to one function literal inside it that branches (line 736). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.convertToMinimalPullRequest (cognitive 17) pkg/github/minimal_types.go:867— github.convertToMinimalPullRequest has cognitive complexity 17 (threshold 15). Drivers by points: if/else 14, loops 3 (nesting depth added 3). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
github.createProjectStatusUpdate (cognitive 17) pkg/github/projects.go:1419— github.createProjectStatusUpdate has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 2 (nesting depth added 2). To reduce it, split the body: most of this score is breadth rather than depth — checks laid out side by side rather than stacked — so group the statements between the checks into named steps and move each step into its own function. Some of it IS depth: where a check sits inside another whose only job is to reach it, merge the two into one condition.
github.listProjectStatusUpdates (cognitive 17) pkg/github/projects.go:1490— github.listProjectStatusUpdates has cognitive complexity 17 (threshold 15). Drivers by points: if/else 15, boolean chains 1, loops 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.
toolvalidation.ScanReadOnlyHint (cognitive 17) pkg/toolvalidation/readonlyhint.go:59— toolvalidation.ScanReadOnlyHint has cognitive complexity 17 (threshold 15). Drivers by points: if/else 13, loops 3, boolean chains 1 (nesting depth added 9). Of this number, 11 points are the body's own statements and 6 belong to one function literal inside it that branches. To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
github.ActionsGetJobLogs (cognitive 16) pkg/github/actions.go:647— github.ActionsGetJobLogs has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, boolean chains 3. Most of this is not in the body itself: 0 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 697). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.writeIssueDependency (cognitive 16) pkg/github/issue_dependencies.go:336— github.writeIssueDependency has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, 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.
github.minimalProjectFieldValue (cognitive 16) pkg/github/minimal_types.go:1131— github.minimalProjectFieldValue has cognitive complexity 16 (threshold 15). Drivers by points: if/else 9, loops 6, match/switch 1 (nesting depth added 9). The drivers above price the dispatch low by construction — a dispatch is charged once however many cases it lists, while each branch inside an arm is charged in full — so most of this count is what the case bodies hold, and the arms are where it can be reduced. To reduce it, keep the dispatch but shrink the arms: move each non-trivial case body into its own named function (or onto the value being matched) so the dispatch reads one line per case, and group related cases into a sub-dispatch. Keep every case explicit, and make the behaviour for cases you do not list a deliberate choice rather than an accident.
github.MarkAllNotificationsRead (cognitive 16) pkg/github/notifications.go:242— github.MarkAllNotificationsRead has cognitive complexity 16 (threshold 15). Drivers by points: if/else 14, boolean chains 2 (nesting depth added 2). Most of this is not in the body itself: 0 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 271). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.GetTag (cognitive 16) pkg/github/repositories.go:1676— github.GetTag has cognitive complexity 16 (threshold 15). Drivers by points: if/else 16 (nesting depth added 3). Most of this is not in the body itself: 0 of the 16 points are its own statements and the rest belongs to one function literal inside it that branches (line 1706). The decisions are inside the literal, which nothing outside this body can call, review or test on its own, so splitting the enclosing body is not the move available here. To reduce it, lift the literal's work into a named function or method at the enclosing scope and have the literal call it, then reduce whichever part then reads as the largest.
github.completeOwner (cognitive 16) pkg/github/repository_resource_completions.go:76— github.completeOwner has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, loops 4, boolean chains 2 (nesting depth added 3). To reduce it, split the body: this score is breadth rather than depth — many checks laid out side by side rather than nested inside one another, so inverting conditions into early returns has nothing left to flatten. Group the statements between the checks into named steps and move each step into its own function, so the body reads as a short sequence of named stages.
github.userOrOrgHandler (cognitive 16) pkg/github/search.go:352— github.userOrOrgHandler has cognitive complexity 16 (threshold 15). Drivers by points: if/else 15, loops 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.
github.uiGetMilestones (cognitive 16) pkg/github/ui_tools.go:235— github.uiGetMilestones has cognitive complexity 16 (threshold 15). Drivers by points: if/else 13, loops 2, boolean chains 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.
parsedBatchItem.parseItemRef (cognitive 16) pkg/github/projects_batch.go:386— parsedBatchItem.parseItemRef has cognitive complexity 16 (threshold 15). Drivers by points: if/else 10, boolean chains 2, loops 2, match/switch 2 (nesting depth added 5). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
Unpinned build actions — CI references GitHub Actions by a floating ref (@main / @tag) rather than a pinned commit SHA, weakening build integrity. 34 floating ref(s) across 12 workflow file(s). Each floating ref is itemized at file:line by the SAST (D29) lens.
D38 · OSV Dependency Vulnerabilities· Medium vulnerability · ×1
Medium vulnerability: [GHSA redacted] ui/package-lock.json— @hono/node-server 1.19.14: [GHSA redacted] — @hono/node-server is not declared in this repo's manifests: it is pulled in transitively, so upgrade the dependency that requires it (— 2.0.5 is a MAJOR ahead of the resolved 1.19.14, so an `overrides` pin would force a breaking version under a dependent written against 1.19.14; upgrading the declaring package is the remedy, and where no patched release exists in your major line, record the exposure instead).
Duplicated block (22 lines × 2) pkg/github/minimal_types.go:1025— pkg/github/minimal_types.go:1025-1046 | pkg/github/minimal_types.go:1062-1084 — 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 `pkg/github/minimal_types.go:1025` 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) pkg/github/pullrequests.go:1954— pkg/github/pullrequests.go:1954-1974 | pkg/github/pullrequests.go:2039-2059 | pkg/github/pullrequests.go:2188-2208 — 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 `pkg/github/pullrequests.go:1954` 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 (17 lines × 2) pkg/github/pullrequests.go:2386— pkg/github/pullrequests.go:2386-2402 | pkg/github/pullrequests_granular.go:636-654 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/pullrequests.go:2386` 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 (16 lines × 2) pkg/github/discussions.go:450— pkg/github/discussions.go:450-465 | pkg/github/issues.go:2803-2818 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/discussions.go:450` 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 (15 lines × 5) pkg/github/ui_tools.go:201— pkg/github/ui_tools.go:201-215 | pkg/github/ui_tools.go:258-272 | pkg/github/ui_tools.go:350-364 | pkg/github/ui_tools.go:488-502 | pkg/github/ui_tools.go:509-523 — all 5 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 `pkg/github/ui_tools.go:201` 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 (13 lines × 3) pkg/github/repositories.go:390— pkg/github/repositories.go:390-402 | pkg/github/repositories.go:1661-1673 | pkg/github/repositories.go:1774-1786 — 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 `pkg/github/repositories.go:390` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (12 lines × 3) pkg/github/repositories.go:84— pkg/github/repositories.go:84-95 | pkg/github/repositories.go:1620-1631 | pkg/github/repositories.go:1835-1846 — 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 `pkg/github/repositories.go:84` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (11 lines × 6) pkg/github/issues_granular.go:103— pkg/github/issues_granular.go:103-113 | pkg/github/issues_granular.go:187-197 | pkg/github/issues_granular.go:413-423 | pkg/github/issues_granular.go:631-641 | pkg/github/issues_granular.go:808-818 | pkg/github/issues_granular.go:1006-1016 — all 6 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 `pkg/github/issues_granular.go:103` 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 (11 lines × 5) pkg/github/actions.go:1047— pkg/github/actions.go:1047-1057 | pkg/github/actions.go:1069-1079 | pkg/github/actions.go:1091-1101 | pkg/github/actions.go:1116-1126 | pkg/github/actions.go:1138-1148 — all 5 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 `pkg/github/actions.go:1047` 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 (10 lines × 10) pkg/github/issues.go:894— pkg/github/issues.go:894-904 | pkg/github/issues.go:1527-1536 | pkg/github/issues.go:1575-1585 | pkg/github/issues.go:2496-2505 | pkg/github/pullrequests.go:174-183 | pkg/github/pullrequests.go:277-286 | pkg/github/pullrequests.go:296-305 | pkg/github/pullrequests.go:396-405 | pkg/github/pullrequests.go:424-433 | pkg/github/pullrequests.go:571-580 — there are 10 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 10 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:894` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (10 lines × 5) pkg/github/repositories.go:102— pkg/github/repositories.go:102-111 | pkg/github/repositories.go:264-273 | pkg/github/repositories.go:2153-2162 | pkg/github/repositories.go:2263-2272 | pkg/github/repositories.go:2328-2337 — all 5 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 `pkg/github/repositories.go:102` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (9 lines × 4) pkg/github/issues_granular.go:401— pkg/github/issues_granular.go:401-409 | pkg/github/issues_granular.go:619-627 | pkg/github/issues_granular.go:796-804 | pkg/github/issues_granular.go:994-1002 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues_granular.go:401` 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 register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (8 lines × 10) pkg/github/git.go:84— pkg/github/git.go:84-91 | pkg/github/pullrequests.go:1383-1390 | pkg/github/repositories.go:192-199 | pkg/github/repositories.go:770-778 | pkg/github/repositories.go:986-993 | pkg/github/repositories.go:2805-2812 | pkg/github/code_scanning.go:152-159 | pkg/github/dependabot.go:145-152 | pkg/github/secret_scanning.go:148-155 | pkg/github/security_advisories.go:260-268 — there are 10 copies across 7 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 10 sites; resolving a subset leaves the remainder to drift apart.
Duplicated block (8 lines × 9) pkg/github/discussions.go:762— pkg/github/discussions.go:762-770 | pkg/github/issue_dependencies.go:68-75 | pkg/github/issue_dependencies.go:258-265 | pkg/github/issues.go:656-664 | pkg/github/issues.go:1427-1435 | pkg/github/issues.go:2212-2220 | pkg/github/projects.go:232-241 | pkg/github/projects.go:703-712 | pkg/github/pullrequests.go:85-93 — there are 9 copies across 5 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 9 sites; resolving a subset leaves the remainder to drift apart.
Duplicated block (8 lines × 7) pkg/github/issues.go:2279— pkg/github/issues.go:2279-2289 | pkg/github/pullrequests.go:1387-1394 | pkg/github/code_scanning.go:160-167 | pkg/github/dependabot.go:149-156 | pkg/github/secret_scanning.go:152-159 | pkg/github/security_advisories.go:273-281 | pkg/github/security_advisories.go:439-447 — there are 7 copies across 6 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 7 sites; resolving a subset leaves the remainder to drift apart. 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 (8 lines × 6) pkg/github/repositories.go:1854— pkg/github/repositories.go:1854-1861 | pkg/github/repositories.go:1957-1964 | pkg/github/security_advisories.go:192-199 | pkg/github/security_advisories.go:301-308 | pkg/github/security_advisories.go:368-375 | pkg/github/security_advisories.go:467-474 — there are 6 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 6 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/repositories.go:1854` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (8 lines × 5) pkg/github/issue_dependencies.go:266— pkg/github/issue_dependencies.go:266-273 | pkg/github/issues.go:1436-1443 | pkg/github/issues_granular.go:1066-1073 | pkg/github/issues_granular.go:1136-1143 | pkg/github/issues_granular.go:1213-1220 — there are 5 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 5 sites; resolving a subset leaves the remainder to drift apart.
Duplicated block (7 lines × 14) pkg/github/issue_dependencies.go:116— pkg/github/issue_dependencies.go:116-123 | pkg/github/issue_dependencies.go:134-141 | pkg/github/issue_dependencies.go:366-372 | pkg/github/issues.go:896-906 | pkg/github/issues.go:1529-1538 | pkg/github/issues.go:1577-1587 | pkg/github/issues.go:2498-2507 | pkg/github/pullrequests.go:176-185 | pkg/github/pullrequests.go:225-232 | pkg/github/pullrequests.go:279-288 | pkg/github/pullrequests.go:298-307 | pkg/github/pullrequests.go:398-407 | pkg/github/pullrequests.go:426-435 | pkg/github/pullrequests.go:573-582 — there are 14 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 14 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issue_dependencies.go:116` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (7 lines × 5) pkg/github/copilot.go:865— pkg/github/copilot.go:865-871 | pkg/github/pullrequests.go:1219-1225 | pkg/github/pullrequests.go:1541-1547 | pkg/github/pullrequests.go:1712-1718 | pkg/github/pullrequests.go:2339-2345 — there are 5 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 5 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/copilot.go:865` 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 (7 lines × 4) pkg/github/issues_granular.go:350— pkg/github/issues_granular.go:350-356 | pkg/github/issues_granular.go:568-574 | pkg/github/issues_granular.go:753-759 | pkg/github/issues_granular.go:923-929 — all 4 copies are in the same file, so extract the block into one function there and call it from every one of those sites — resolving only two of them leaves the rest to drift apart the first time one is edited. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues_granular.go:350` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
Duplicated block (6 lines × 6) pkg/github/notifications.go:68— pkg/github/notifications.go:68-73 | pkg/github/notifications.go:194-199 | pkg/github/notifications.go:272-277 | pkg/github/notifications.go:357-362 | pkg/github/notifications.go:437-442 | pkg/github/notifications.go:537-542 — all 6 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.
Duplicated block (6 lines × 3) pkg/github/issues.go:1322— pkg/github/issues.go:1322-1327 | pkg/github/pullrequests.go:1291-1296 | pkg/github/gists.go:247-252 — the copies sit in sibling files of one directory: extract the block into a single shared function in that directory and call it from each site, so a change lands once. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/issues.go:1322` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also register a scope-exit action (a `defer`-style statement) that runs when the function holding them returns: moved into a called unit it would run when THAT unit returns instead — before the caller uses what it releases — so keep the registration at the call site and extract only the work around it, or have the extracted unit hand the resource back for the caller to register.
Duplicated block (5 lines × 10) pkg/github/discussions.go:655— pkg/github/discussions.go:655-660 | pkg/github/issue_dependencies.go:67-71 | pkg/github/issue_dependencies.go:253-257 | pkg/github/issues.go:655-660 | pkg/github/issues.go:1426-1431 | pkg/github/projects.go:231-236 | pkg/github/projects.go:702-707 | pkg/github/pullrequests.go:84-89 | pkg/github/labels.go:272-276 | pkg/github/ui_tools.go:73-78 — there are 10 copies across 7 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 10 sites; resolving a subset leaves the remainder to drift apart. 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 × 7) pkg/github/actions.go:693— pkg/github/actions.go:693-697 | pkg/github/git.go:78-82 | pkg/github/repositories.go:980-984 | pkg/github/repositories.go:1934-1938 | pkg/github/repositories.go:2240-2244 | pkg/github/repositories.go:2305-2309 | pkg/github/labels.go:149-153 — there are 7 copies across 4 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 7 sites; resolving a subset leaves the remainder to drift apart. Read the line range as the matched WINDOW rather than a finished unit: at `pkg/github/actions.go:693` it begins part-way through the construct above it, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
Duplicated block (5 lines × 4) pkg/github/issues.go:1422— pkg/github/issues.go:1422-1426 | pkg/github/issues_granular.go:1057-1061 | pkg/github/issues_granular.go:1127-1131 | pkg/github/issues_granular.go:1204-1208 — 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 `pkg/github/issues.go:1422` 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.
Recommendation — 7 finding(s)
D11 · Test Reliability· Test reliability not included · ×1
Test reliability not included — Test source is present (.go) but the built-in reliability runner does not support this repository's ecosystem, so flakiness couldn't be assessed. Not scored — this is a gap in the analyzer's language coverage, not a finding about this repository.
Off-boarding risk: anonymized user #1 — If anonymized user #1 becomes unavailable, 3 significant file(s) lose their only recent owner: internal/oauth/manager.go, internal/ghmcp/oauth.go, pkg/toolvalidation/readonlyhint.go. Pair on, review, or document these before any departure.
D16 · Bus Factor· Further sole-owners (lower concentration) · ×1
Further sole-owners (lower concentration) — 3 other contributor(s) are each the sole owner of a small amount of code below the off-boarding threshold — folded into the bus-factor score and metrics (6 single-owned of 91 analysed files in total, counted over production source files of roughly 100 lines or more, excluding tests, vendored, generated and example/demo trees, largest first). They are anonymized user #2 (1 file(s)), anonymized user #3 (1 file(s)), anonymized user #4 (1 file(s)) — spread or document their files in the same way, at lower priority than the named off-boarding risks above.
Low IaC: DS-0026 Dockerfile— No HEALTHCHECK defined Without one the runtime only knows whether the process is alive, not whether it is serving, so a wedged container is restarted by nobody. The step: add a `HEALTHCHECK` to the image that probes the service the way a client would — this image already declares `EXPOSE 8082`, so a request to `localhost:8082` on the service's own health or root route, exiting non-zero when it does not answer, is the probe — and give it an `--interval`, a `--timeout` and a `--start-period` long enough to cover startup. If the image ships no HTTP client, probe with whatever the runtime already has, or declare the check in the orchestrator instead and say so here.
D34 · Knowledge Freshness· Further orphaned files (smaller) · ×1
Further orphaned files (smaller) — 6 of 91 analysed file(s) have no living knowledge left — their last meaningful change has decayed away, so if one breaks, no one currently understands it (counted over production source files of roughly 100 lines or more, excluding tests, vendored, generated and example/demo trees, largest first). None is large enough to earn a read-through of its own, so this row stands in for the per-file rows rather than raising one each — largest first: internal/githubv4mock/githubv4mock.go, internal/githubv4mock/query.go, internal/githubv4mock/objects_are_equal_values.go (and 3 more). Attach the read to the next change that touches one of them: have a second person review that change, and leave behind a short comment or test recording what the file is for, so the knowledge comes back at the cost of a change you were making anyway.
D36 · Supply-chain Provenance & Signing· No SBOM · ×1
No SBOM — No SBOM generation or committed SBOM found — produce one with what your ecosystem ships (an `sboms:` block in `.goreleaser.yml`, which GoReleaser runs on the release you already cut and attaches the document beside the artifacts, `cyclonedx-gomod` over the module graph — or Go's own build info, which already records the module set in the binary, `syft` (or `anchore/sbom-action` in CI) over the source tree or released image). Your CI already runs an attestation step, so the cheapest route is to emit the SBOM there and attach it as a subject rather than adding a separate pipeline.
Coverage not included — suite not readable by the collector — Coverage NOT MEASURED: test source is present (.go) but the built-in coverage collector has no runner for this repository's ecosystem — so this suite was never executed by it. Not scored — this is a gap in the analyzer's language coverage, not a defect in the repo. To have real coverage read, produce a coverage report in a standard format (`go test -coverprofile=coverage.out ./...`) into the repo working tree before the scan — a CI step is the usual place, since the artefact is commonly gitignored.
Info — 2 finding(s)
D12 · Dependency Hygiene· Dependency hygiene not measured · ×1
Dependency hygiene not measured — dependency manifest found but not parsed for hygiene — This repository's dependency manifests (a Go module (go.mod/go.sum) and package.json) were found, but this pass cannot parse them for hygiene, so no package was assessed. Zero packages read is NOT a clean dependency tree, so this is NOT SCORED — a gap in the analyzer, not a verdict about this repository. This row is about dependency HYGIENE — outdated, deprecated or unmaintained direct dependencies; known CVEs in the same dependency graph are a separate question, reported under D38 wherever the manifest is OSV-readable.
D22 · Internal API Consistency· No exposed public API · ×1
No exposed public API — No intentionally-exposed types (IsPackable or .Contracts) to evaluate.
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.
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.
0
—
Run 019fd617-cbc5-7a38-9799-7887413fa6b7 · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.
Issues: 41 · Warnings: 329 · Recommendations: 7 · Info: 2 — Appendix A · all findings · full markdown report.
Generated by Watchdog — deterministic code-health analysis. 06-08-2026 @ 08:01 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.