Public report of vdemydiuk/mtapi, published 17 November 2026. It has the same score, grades and number of findings as the full report. The details of security findings (where they are in the code, which known vulnerabilities and which passwords or keys were found) are left out, so nobody can use them against the project.
Public
Executive report Measured under the Code Assurance Index, an open standard for code quality, using its published scoring rules (rubric version 2026.11.4). Assert signed this survey and filed it in the standard's public register, where anyone can look it up by its survey ID. Check this survey → Signed and filed in the standard's public register, 17 November 2026, 21:43 UTC · Survey ID cd_a542960b437244cb80dbf7b67573b3a5

vdemydiuk/mtapi

Measured 17 November 2026, 21:43 UTC, at code version dac342d

First survey, so nothing to compare with yet Test reliability: not measured

Test reliability is not measured: No test run produced results.

CAI score 32.8out of 100 Provisional

The score is built from these lenses. Each lens grades one area of the code, such as how easy it is to change or how well it is protected. The weakest lens counts most, so one weak area pulls the score down instead of being averaged away.

A medium codebase: 25,322 lines of product code in 10 projects, tests not counted · Estimated rebuild effort: about 0.2 person-years · Weakest lens: Production Readiness, 19.3

Findings by how serious they are

8 critical 221 serious 100 minor

8 dimensions are left out of the score. For each one, we either couldn't measure it in this code, or found no evidence of the safeguard we look for, such as a tested backup restore. They count neither for nor against the score, and Limitations lists each one with its reason.

This survey was produced by

Assert small markCanine Code Analyzer
Producer
Canine Development
Analyzer
Canine Code Analyzer engine 1.0.0
Measured
17 November 2026, 21:43 UTC

A measurement, not a certificate. The Code Assurance Index records a number together with the evidence it was worked out from, so anyone can recalculate it, but it doesn't certify or guarantee the code. The standard was written by Canine Development, which also builds the Canine Code Analyzer. It is open to any tool that implements it, and today the Canine Code Analyzer is the only one that does.

The code didn't build, so the score is provisional
We couldn't build the code: the build stopped with 7 errors. The dimensions that need a working build, such as complexity, duplication and dead code, were measured on an incomplete picture of the code, so their grades and the score are provisional. Fix the build errors and run the survey again for a final score. The first errors: MSB4278: The imported file "$(VCTargetsPath)/Microsoft.Cpp.Default.props" does not exist and appears to be part of a Visual Studio component. This file may require MSBuild.exe in order to be imported successfully, and so may fail to build in the dotnet CLI.; CS0246: The type or namespace name 'MtApi5' could not be found (are you missing a using directive or an assembly reference?)

The score is deterministic, which means the same code always gets the same score. We work it out with tools that follow published rules, and an AI model never decides it, so anyone who applies the same rules to the same code gets the same number. How it is done is explained under Methodology ▸

54of 54 dimensions measured by tools.
320of 329 findings point to an exact file and line, so you can open each one in the code. The other 9 concern the repository as a whole, such as missing documentation.
54dimensions across 6 lenses, read from 25,322 lines of product code in 10 projects.
Chapters

Executive summary

vdemydiuk/mtapi has a provisional result, because the code didn't build. Its score is held back because the project has no automated tests and we found no working pipeline that builds or tests changes to the code. It scores 32.8 out of 100, and the ratings may change once the code builds. Two of its eight critical findings are leaked passwords or keys.

Production Readiness, at 19.3, is the weakest lens and counts most in the score. The best first step for the work it takes is fixing the password or key in the code, worth about 8.4 points. Adding automated tests would lift Production Readiness itself, worth about 12.9 points. Raising Production Readiness to 70 would lift the score to about 44.4.

One password or key in the code and one in the code's history are open to anyone who can read the repository. The project has no automated tests, so a change can break it without warning, and three errors are caught and ignored, so failures can go unnoticed. Replacing each exposed password or key, adding automated tests and handling or logging the ignored errors would close these risks. The data field that is written but never read needs removing.

The product code is 25,322 lines, about €23,000 to rebuild.

A lens is capped at Adequate while one of its dimensions scores below 4 out of 10, however well the rest of the lens does. That way a serious problem in one place always shows in the lens's rating.

How the score is built: what each lens counts for The lenses don't count equally. The weakest lens counts most, the next weakest a little less, and so on, so a weak area pulls the score down instead of being averaged away. In the bar below, each part's width shows how much that lens counts and its colour shows its rating. Improving the widest part moves the score most, and as that lens improves, it counts for less, because another lens becomes the weakest.
Production Readiness 19.3 · counts for 46%Security and Compliance 29.3 · counts for 25%Code Health 46.7 · counts for 14%Maturity 58.5 · counts for 8%Architecture 71.6 · counts for 4%Performance 100.0 · counts for 2%

If Production Readiness rose from 19.3 to 70, the lowest score rated Strong, the score would rise from 32.8 to about 44.4.

Code composition: what the lines of code are
Business logic 21%Supporting code 63%Generated by tools 16%
Rebuild cost: about €23,000 · Estimate
Cost to rebuild€7,800 to €39,000, for 130 to 412 hours of work, about 0.2 person-years for one engineer
Difficulty of the problemStandard, judged from the kind of software and how it is built. Code that solves a harder problem, such as payments or medical bookings, costs more per line to write.
Quality factor×0.7 at a score of 33. Better code takes more work to write, so the factor is ×1.0 at a score of 70, lower below it and higher above it.
SizeMedium: 25,322 lines of product code
Comment linesThe estimate prices 22,611 lines. Comment lines count towards the size of 25,322 lines but aren't priced as work.
What it is notNot a quotation: nobody has offered to build it for that. Not a valuation: it says nothing about what the business is worth. Not a certified figure: no professional has signed it as one.

How the estimate is made: We price the hours a team would need to write this code again, at €60 to €95 an hour. Declarations and boilerplate are priced at a fast rate and logic at a slower one, and the logic is then multiplied by the difficulty of the problem and by the quality factor. The estimate can be about 30% off either way, and it moves most with the hourly rate and the difficulty.

Top priorities

The three actions that raise the score most for the work they take. The full ranked list is in the Roadmap.

1
Resolve the 1 Leaked secret finding(s) in Secret Scanning — start with REDACTED.
Raises the score by about 8.4 points · Low effort · Secret Scanning
2
Resolve the 3 End-of-life runtime finding(s) in Platform End-of-Life — start with MTApiService.csproj, TestServer.csproj, TestMtApi.vbproj.
Raises the score by about 4.5 points · Low effort · Platform End-of-Life
3
Authorize the service host, don't just host it: derive a ServiceAuthorizationManager and set it as the host's authorization policy (or decorate each [OperationContract] with [PrincipalPermission], or call an explicit guard on OperationContext.Current.ServiceSecurityContext at the top of every operation) so the caller's identity has to satisfy a named rule before the operation runs.
Raises the score by about 7.5 points · Medium effort · Access Controls

Diagnosis: what the measurements show together

Each conclusion below combines several dimensions into one point that no single dimension shows, and lists the measurements it rests on.

If you do one thing first · First action
Fix the build. The code didn't build, so the dimensions that need a working build were measured on an incomplete picture of the code, and every grade in this report is provisional. Once the build works, the next survey gives a final score. The compiler's first errors: MSB4278: The imported file "$(VCTargetsPath)/Microsoft.Cpp.Default.props" does not exist and appears to be part of a Visual Studio component. This file may require MSBuild.exe in order to be imported successfully, and so may fail to build in the dotnet CLI.; CS0246: The type or namespace name 'MtApi5' could not be found (are you missing a using directive or an assembly reference?)
Based on: Solution Shape
Where the investment is most exposed · Value at risk
This code would cost about €23,000 to build again, about 0.2 person-years of work. Its weakest lens is Production Readiness, at 19.3 (Critical). Production Readiness is about whether the product is ready to run in production and to change without breaking. Because the weakest lens counts most in the score, work on Production Readiness also moves the score most.
Based on: the rebuild estimate · the Production Readiness grade · how much each lens counts
What to do: Start with the Production Readiness actions in Top priorities.

Architecture — module dependency graph

Project dependencies, layered top-to-bottom; arrows show direction. Any dashed red edge points upward or sideways, which only happens where the projects form a dependency cycle. A graph without cycles has none.

arch HistoryOrderSample HistoryOrderSample MtApi5 MtApi5 HistoryOrderSample->MtApi5 MtClient MtClient HistoryOrderSample->MtClient MTApiService MTApiService MtApi MtApi MtApi->MtClient MtApi5->MtClient MtApi5TestClient MtApi5TestClient MtApi5TestClient->MtApi5 MtApiSetupActions MtApiSetupActions TestApiClientUI TestApiClientUI TestApiClientUI->MtApi TestMtApi TestMtApi TestMtApi->MtApi TestServer TestServer

Architecture: which parts of the code depend on which

The code is divided into modules, groups of code that each handle one part of the product, and a module depends on another when it uses code from it. The table lists the modules both down the side and across the top, in an order where each module should only use modules listed above it. A number in a cell means the module on that row uses the module in that column, and it counts the pairs of building blocks (types) that connect them. The one thing to look for is a mark above the diagonal line. It means two or more modules use each other in a loop (a dependency cycle), so none of them can be changed, tested or released on its own.

14 modules, with 8 dependencies between them. One loop runs through 2 of the modules, marked above the diagonal.

Which modules use which. The module on each row uses the module in each column, and the number counts the pairs of types that connect them. A cell above the diagonal is part of a loop.
uses →1 MTApiService2 MtApi.Events3 MtApi.MtProtocol4 MtApi.MtProtocol.ICustomRequest5 MtApi5.MtProtocol.ICustomRequest6 MtApiSetupActions7 MtClient8 thirdparty.include.boost.outcome.outcome9 thirdparty.include.boost.outcome.outcome.gdb10 MtApi11 MtApi5.MtProtocol12 MtApi.Monitors.Triggers13 MtApi514 MtApi.Monitors
1 MTApiService
2 MtApi.Events
3 MtApi.MtProtocol
4 MtApi.MtProtocol.ICustomRequest
5 MtApi5.MtProtocol.ICustomRequest
6 MtApiSetupActions
7 MtClient
8 thirdparty.include.boost.outcome.outcome
9 thirdparty.include.boost.outcome.outcome.gdb
10 MtApi24
11 MtApi5.MtProtocol5
12 MtApi.Monitors.Triggers2
13 MtApi543
14 MtApi.Monitors104
Uses a module listed above itPart of a loopThe module itself
1 MTApiService2 MtApi.Events3 MtApi.MtProtocol4 MtApi.MtProtocol.ICustomRequest5 MtApi5.MtProtocol.ICustomRequest6 MtApiSetupActions7 MtClient8 thirdparty.include.boost.outcome.outcome9 thirdparty.include.boost.outcome.outcome.gdb10 MtApi11 MtApi5.MtProtocol12 MtApi.Monitors.Triggers13 MtApi514 MtApi.MonitorsMTApiService1MtApi.Events2MtApi.MtProtocol3MtApi.MtProtocol.ICustomRequest4MtApi5.MtProtocol.ICustomRequest5MtApiSetupActions6MtClient7thirdparty.include.boost.outcome.outcome8thirdparty.include.boost.outcome.outcome.gdb9MtApi10MtApi5.MtProtocol11MtApi.Monitors.Triggers12MtApi513MtApi.Monitors14245243104

At a glance — Code Health · 46.7 · Weak · gated by D18, X1 ·

At a glance — Architecture · 71.6 · Adequate · gated by AX2 ·

At a glance — Maturity · 58.5 · Adequate · gated by M2 ·

At a glance — Readiness · 19.3 · Critical · gated by D8, P1, P3 ·

At a glance — Security · 29.3 · Weak · gated by D44, C2 ·

At a glance — Performance · 100.0 · Exemplary ·

Security & Compliance — OWASP Top-10 mapping

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 categoryFindingsSeverity
A07:2025 — Authentication Failures2High / Critical
A05:2025 — Injection1Medium
A03:2025 — Software Supply Chain Failures1Medium

Roadmap

Top priorities: Resolve the 1 No automated tests finding(s) in Code Coverage; Resolve the 1 Leaked secret finding(s) in Secret Scanning — start with REDACTED; Authorize the service host, don't just host it: derive a ServiceAuthorizationManager and set it as the host's authorization policy (or decorate each [OperationContract] with [PrincipalPermission], or call an explicit guard on OperationContext.Current.ServiceSecurityContext at the top of every operation) so the caller's identity has to satisfy a named rule before the operation runs.

Ranked by impact ÷ effort. "Helps" is the estimated gain on the 0–100 health score.

Do thisHelpsEffortDimension
Resolve the 1 Leaked secret finding(s) in Secret Scanning — start with REDACTED.+8.4 ptsLowSecret Scanning
Resolve the 3 End-of-life runtime finding(s) in Platform End-of-Life — start with MTApiService.csproj, TestServer.csproj, TestMtApi.vbproj.+4.5 ptsLowPlatform End-of-Life
Authorize the service host, don't just host it: derive a ServiceAuthorizationManager and set it as the host's authorization policy (or decorate each [OperationContract] with [PrincipalPermission], or call an explicit guard on OperationContext.Current.ServiceSecurityContext at the top of every operation) so the caller's identity has to satisfy a named rule before the operation runs.+7.5 ptsMediumAccess Controls
Resolve the 1 No automated tests finding(s) in Code Coverage.+12.9 ptsHighCode Coverage
Add a CI workflow that builds and runs the test suite on every push/PR.+5.6 ptsMediumCI/CD gates
Run what this repository's stack ships: CodeQL's csharp pack, or a .NET security analyzer package — or `semgrep --config=auto`, which runs on any language — locally for now, since there is no CI pipeline here yet, and as a step of the first workflow you add so a security regression fails the build instead of landing.+5.6 ptsMediumSecurity & performance tooling
Resolve the 1 WriteOnlyPrivateField finding(s) in Explicit Debt — start with MetaTrader.cs.+2.3 ptsLowExplicit Debt
Resolve the 3 EmptyCatchBlock finding(s) in Explicit Debt — start with TradeMonitor.cs (2), MtApi5Client.cs.+2.3 ptsLowExplicit Debt

File quality

Per-file score 0–10 — a quality signature. Of 35 files carrying findings, judged against the Production bar: 6% slop · 48% mixed · 46% near-clean.

FileScoreBandWorst signal
MtApi5/MtApi5Client.cs2.1SlopExplicit Debt: EmptyCatchBlock
MtApi/Monitors/TradeMonitor.cs3.2SlopExplicit Debt: EmptyCatchBlock
REDACTED4.4MixedSecret Scanning: Leaked secret: REDACTED
REDACTED5.7MixedStatic Analysis (SAST): Medium: REDACTED
TestClients/TestServer/MtQuoteExpert.cs.cs6.0MixedExplicit Debt: CommentedOutCode
MtApi/MtApiClient.cs6.0MixedExplicit Debt: ObsoleteWithCallers
TestClients/TestApiClientUI/Form1.cs6.0MixedExplicit Debt: CommentedOutCode
MtApi5/Mt5Enums.cs6.0MixedExplicit Debt: FixmeComment
MtApi5/MtProtocol/Mt5CommandType.cs6.4MixedExplicit Debt: TodoComment
MtApiSetupActions/CustomAction.cs6.9MixedExplicit Debt: CommentedOutCode
TestClients/MtApi5TestClient/ViewModel.cs7.1MixedGod Classes: TooManyMethods: ViewModel
MTApiService/MtRegistryManager.cs7.4MixedCode Duplication: Edited copies of one member (3 members, 40+ corresponding lines)
TestClients/TestMtApi/TestMtApi/TestMtApi.vbproj7.4MixedPlatform End-of-Life: End-of-life runtime: .NET Framework net45
TestClients/TestServer/MetaTrader.cs7.6MixedExplicit Debt: WriteOnlyPrivateField
TestClients/TestServer/Program.cs7.8MixedCognitive Complexity: Program.printCharts (cognitive 16)
MtApi/MtCommandType.cs7.8MixedCode Duplication: Duplicated block (33 lines × 2)
REDACTED7.9MixedDependency Vulnerabilities: Medium CVE: REDACTED
MTApiService/MTApiService.csproj7.9MixedPlatform End-of-Life: End-of-life runtime: .NET Framework net40
TestClients/TestServer/TestServer.csproj7.9MixedPlatform End-of-Life: End-of-life runtime: .NET Framework net40
MTApiService/MtService.cs8.5Near-cleanCode Duplication: Edited copy of a member (31 corresponding lines)

How the grades work

Every finding carries one of four grades. Three say how serious it is. The fourth says this survey could not settle it — and it is a grade, not a gap.

Critical — 8

A definite problem that already costs you something and drags the score down: a missing authorisation check, a dependency with a known exploit, a build that does not reproduce. Failure here tends to cause failures elsewhere.

Serious — 221

Likely wrong, but not failing yet. It degrades the codebase over a longer horizon and can cause failures elsewhere — not urgent this week, not something to carry for two years either.

Minor — 100

Recorded, with no effect on how the codebase functions. Present so the survey is complete, not because it needs doing.

Could not be resolved — 8

Something this survey could not settle from the outside, and which could be critical or serious. Either a control was required and no positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean result. These are excluded from the score rather than awarded a pass, so the number on the cover neither rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each one is named under Limitations.

Methodology & how to trust this report

This survey is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. All 54 evaluated dimensions are computed by tools and static analysis; no language model sets or judges any of them. Overall confidence is 0.9, the weighted average across measured dimensions.

Every figure here is one of two kinds, and we label which: ✓ Measured — a deterministic fact (LoC, complexity, coverage); ~ Modeled — an estimate from a stated model (cost, effort, value-at-risk), always a range with its assumptions, never a precise fact. We never present a modelled estimate as if it were measured. Perfect or absent scores carry their provenance too (ADR-0011): ✓ Tool-verified means the property itself was measured across the surface; ○ Nothing flagged means the probes came back clean — a claim bounded by what a repository can show; ⊘ Not evidenced means a working control (a tested restore, an automated rollback) showed no positive evidence — absence of evidence is not evidence of a control, so it's excluded from the score rather than awarded a spurious 10.

What we checked — 54 dimensions across the health lenses
D1D2D3D4D5D6D8D13D14D15D17D18D19D24D26D27D28D29D30D34D35D43D44AX10AX2AX3AX4AX5AX6C2GD1IC1M1M2M3P1P2P3P6PF3X1X12X13X16X18X2X20X23X25X26X27X29X3X5

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
  1. 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, 320 of 329 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.)
  2. Is there a tool behind the number? Every score below names the method that produced it: Roslyn, git or a scanner, not a narrative.
  3. 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.

MethodBacksVersionEvaluator
Roslyn static analysisComplexity, cohesion, coupling, dead code, API surface, layering5.3.0✓ deterministic
Native secret scannerHardcoded secrets / credentials1.0.0✓ deterministic
Canine Code Analyzer duplication detector (in-process)Code duplication1.0.0✓ deterministic
Coverage (coverlet / dotnet-coverage)Line & branch coverage10.0.400✓ deterministic
NuGet / dotnetOutdated, vulnerable & deprecated dependencies10.0.400✓ deterministic
git / LibGit2SharpChurn hotspots, knowledge concentration, history2.43.0 · 0.31.0✓ deterministic
gitleaks · semgrep · trivySecrets in history, SAST, CVEs, IaC & container, PII / GDPR1.86.0 · 0.69.3✓ deterministic

Every finding is locatable in findings.md. Run 01a1eb76-c65d-7ebd-8a77-2b74aa547172.

The exact command behind every deep-scan dimension — tool, version, invocation and retained raw output — is in Appendix B — Reproduction & audit trail.

Run transparency — what happened this run

What ran differently this time — a tool absent, degraded, or that fell back to an estimate. Named openly, not folded silently into the scores. A degraded run also records its exact cause in diagnostics.md.

  • D4 Code Duplication — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. The 16 duplicated block group(s) on this row were found in the languages this pass could tokenize, and they do NOT cover all of this repository's production source: .m (5,749 lines, 23% of production source) went unread, because no language model this pass could load exposed a clone-unit token stream for those file kinds. Duplication in that source is UNMEASURED — its absence from the count above is a gap in this analyzer's language coverage, not a finding that the code is free of duplication.
  • D11 Test Reliability — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Test reliability NOT MEASURED: the test run produced no results for any test tier, so no test ever ran and flakiness could not be exercised. The cause could not be attributed, so it is excluded from the score rather than read as an absence of tests.
  • D12 Dependency Hygiene — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. `dotnet list package` did not return usable output (restore or query failed); no outdated/vulnerable/deprecated data to assess. The tool said: error: The imported file "$(VCTargetsPath)/Microsoft.Cpp.Default.props" does not exist and appears to be part of a Visual Studio component. This file may require MSBuild.exe in order to be imported successfully, and so may fail to build in the dotnet CLI. /tmp/codehealth-iso-de7b981696134f0794c479….
  • D16 Bus Factor — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. Single-maintainer repository — bus factor is not applicable (15 contributor(s) across 471 commit(s) sampled, automation and bot accounts excluded). One of them holds 90% of the history; the other 14 hold 0.7% each on average, below the 5% at which there is somebody to hand the work to. That is a single maintainer with drive-by contributors, not a team whose knowledge has concentrated — so the bus factor is not applicable and there is nothing here for the owner to act on.
  • D17 Explicit Debt — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. The C# workspace loaded this repository's projects but reported a load failure, and the dead-code reference search is unreliable over a graph that did not load cleanly, so it was skipped. The other debt markers on this row were read; dead symbols were not, and their absence from the score is not a finding that the code has none. First load diagnostic: Failure: Cannot open project 'MtService/MtService.vcxproj' because the file extension '.vcxproj' is not associated with a language.
  • D17 Explicit Debt — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. The 45 deducted marker(s) and the 0.8/KLoC density on this row were taken over this repository's .NET projects ALONE: .m (5,749 lines, 23% of production source) went unread, because every marker collector on this path is reached through a C# workspace. D17's marker collectors need a compiler we do not have for that language, so none of its nine marker kinds were read there. The debt in that source is UNMEASURED — its absence from the score above is a gap in this analyzer's language coverage, not a finding that the code carries none.
  • D19 Documentation Quality — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This kind did not reach the 95 % precision gate in three adjudicated runs (docs/plans/deterministic-engine/adjudication/D19-sample3-v3.md), so by the pre-registered fallback it publishes no row until a re-measurement shows it does. The candidates are counted here, not reported as findings, and the score does not include them.
  • D21 Naming Consistency — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. D21's naming rules read C# through Roslyn and every other language through its sidecar model; these languages are left out (PHP's reading is its own change, a Roslyn-loaded VB or F# project has no population builder yet). Their declarations carry no naming verdict this run — this says nothing about whether their names are consistent.
  • D21 Naming Consistency — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. PREREGISTRATION version 20's fallback (adjudication D21-sample3-v3): this rule kind was adjudicated below the 95 % precision gate, so its candidates are counted here and not published, and the score covers only the acronym-spelling and awaitable-suffix rules. The kind returns as rows only after it shows a measured precision; this says nothing about whether these names are consistent.
  • D22 Internal API Consistency — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. The loaded project set declares no packable project and no `.Contracts` project, so there is no intentionally-exposed surface for API consistency to be judged over.
  • D24 Comment Value — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Each source language's comment syntax, and the code a comment annotates in it, needs its own proof before D24 judges it. Until then those comments are left unread, not counted as clean.
  • D27 Navigability — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Tracing effort is measured over resolved call sites, and all 835 sampled here came from .cs files. This repository's .m source is a material share of its production lines and contributed none, so the score above is a verdict about the part that was read. Not a finding that the unread half navigates well — it is unmeasured.
  • D30 Dependency Vulnerabilities — measured, with a gap in what it reached — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. The solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan. 1 of 2 declared ecosystem(s) (osv) WERE scanned and every vulnerability they reported is included in this result; nuget was not, so this dimension's score covers less than the dependency surface this repository declares, and nothing here is evidence that nuget is free of known-vulnerable dependencies.
  • D32 Data Compliance (PII/GDPR) — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. `MtApi/Monitors/AvailabilityOrdersEventArgs.cs`, `MtApi/MtApiClient.cs`, `MtApi/MtConnectionEventArgs.cs`, `MtApi/MtExecutionException.cs`, `MtApi/MtQuoteEventArgs.cs`, … (+6 more) produced a parse error, so every rule in this engine's `gdpr.yml` was absent there. That absence is NOT a clean result: these rules detect personal data crossing a boundary into a log sink, a URL or browser storage, and a file that was never parsed cannot report any of the three. The rest of the tree analysed normally and its rows above stand; only these files are unaccounted for. You can widen what we reach: fix the syntax error (or exclude the file deliberately) and re-scan to cover it.
  • AX6 Interface segregation — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • AXB1 Runtime evidence locked — no reproducible boot — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Subject: a native UI project (TestClients/MtApi5TestClient/App.xaml). The Runtime Evidence tier boots an app only via docker-compose, an Aspire AppHost, a Dockerfile, an npm dev script, a web service's own toolchain entry point (cargo, go, dotnet, Python, Spring Boot), or an Android app's own Gradle wrapper (run on an emulator); an Apple or Flutter app needs a host it lacks. None applied, so no live runtime a11y/egress/header evidence was collected. You can widen what we reach: add a docker-compose.yml (or an Aspire AppHost) that brings the app up with its dependencies. We then boot it in an isolated sandbox and gathers real runtime evidence — you change nothing in your pipeline (no CI step, no SDK).
  • IC1 Incompleteness & stubs — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • IC1 Incompleteness & stubs — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 1 further occurrence(s) are not listed individually; the score already reflects all 41.
  • P10 Library API & versioning — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Library API & versioning could not be assessed in this run — the check did not complete, so it is not scored. This is a gap in the analyzer, not a finding about this repository. Engine failure: ArgumentException: SyntaxTree is not part of the compilation (Parameter 'syntaxTree').
  • P11 BDD / executable specs — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. BDD / executable specs could not be assessed in this run — the check did not complete, so it is not scored. This is a gap in the analyzer, not a finding about this repository. Engine failure: ArgumentException: SyntaxTree is not part of the compilation (Parameter 'syntaxTree').
  • P5 DR & Backup — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. No backup/snapshot/replication config, RTO/RPO or restore-procedure documentation was found — and no production persistence was detected either (no data-access packages, no data-store services, no database resources), so there is nothing in this repository whose loss a DR control would recover. If this system's data lives in a platform or ops repo we can't see, that's where the DR evidence belongs.
  • P7 Outbound HTTP resilience — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Outbound HTTP resilience could not be assessed in this run — the check did not complete, so it is not scored. This is a gap in the analyzer, not a finding about this repository. Engine failure: ArgumentException: SyntaxTree is not part of the compilation (Parameter 'syntaxTree').
  • P8 Schema migrations — not measured this run — We could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Schema migrations could not be assessed in this run — the check did not complete, so it is not scored. This is a gap in the analyzer, not a finding about this repository. Engine failure: ArgumentException: SyntaxTree is not part of the compilation (Parameter 'syntaxTree').
  • X1 Async correctness — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X1 Async correctness — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 121 further occurrence(s) are not listed individually; the score already reflects all 161.
  • X12 Unreachable branch — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X13 Undrained process stream — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X16 Unfloored truncation loop — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X18 Disposal-pattern correctness — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X2 Cancellation propagation — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X2 Cancellation propagation — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 66 further occurrence(s) are not listed individually; the score already reflects all 106.
  • X23 Unguarded diagnostic materialisation — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X25 Inert configuration knob — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X26 Unsynchronised callback handoff — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X27 Collection changed while being enumerated — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X29 Per-element action decided by a fixed element — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.
  • X3 Exception handling — measured, with a gap in what it reached — We measured this, but not all of it. What we did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. This check's reader does not cover every language in this repository. The score describes the part it read, which is most of the product; the rest is a gap in this analyzer's language reach.

Repo exclusion declarations (.gitattributes linguist-generated/vendored, .editorconfig generated_code): none declared — every source file was scored.

Limitations & what we did not check

We assess the repository exactly as committed, and only the repository. By design we do not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.

Per-dimension blind spots

For each dimension that was measured, what a static, repo-only scan structurally cannot see — the honest edge of the measurement, not a failure of it.

  • D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
  • D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
  • D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
  • D4 Code Duplication: Duplication is token-similarity — an in-process token-stream comparison over sliding windows, with type-aware normalization — so it finds copy-paste, not semantic duplication expressed differently. Committed machine-written code (scaffolded migrations, designer/codegen output, protobuf/OpenAPI stubs, model snapshots) is EXCLUDED — its repetition is the tool's, not the team's — so the score reflects hand-written duplication only.
  • D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
  • D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
  • D8 Code Coverage: Coverage is measured by building and running the test suite inside our isolated image — the target repo is never modified, and nothing on your systems runs. So coverage exists only when the suite builds and runs within the inline time budget; one that needs external services, can't build, or exceeds the budget yields no coverage (D8 then degrades to not-measured, not a low score). Line coverage also says nothing about assertion quality.
  • D13 Secret Scanning: Secret detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
  • D14 License Compliance: License compatibility is checked against declared package metadata and a policy — mislabelled or missing license metadata, and obligations that depend on how you distribute, are not resolved here.
  • D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
  • D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
  • D18 Solution Shape: Build integrity reflects whether the solution compiled in this environment — a build that needs a private feed, a specific SDK, or a generated file absent from the repo can read as broken when it is merely unreproducible here.
  • D19 Documentation Quality: Documentation quality publishes two things only: a runnable or packaged unit with no example, and a multi-project root README that maps none of its parts. It does not judge clarity, and its other checks (overview, licence, boilerplate, structure, empty sections, XML-doc coverage) are withheld after adjudication: their candidates are counted in the card's gaps, not shown as rows. A false statement in a document is M4's; units are .NET projects only.
  • D24 Comment Value: Comment value is measured as redundancy only: a comment that repeats its code's words is found, but a paraphrase in other words, a vague comment, or one the code contradicts is not, and whether a comment is valuable is not claimed. Comments in other scripts or languages, and outside C#, are not judged.
  • D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
  • D27 Navigability: Indirection/navigability is structural — it measures hops to follow a call, not whether that indirection buys real flexibility or just ceremony.
  • D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
  • D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
  • D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
  • D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
  • D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
  • D43 Malicious Dependencies: Only packages some vulnerability database has already NAMED as malicious are seen — a compromise published in the last hours, or never reported at all, is invisible here, and this dimension reading 10 is not evidence that a dependency is trustworthy. There is no typosquat or dependency-confusion analysis: a package nobody has reported is simply absent from the feeds. Coverage is the dependency scan's: an ecosystem that could not be scanned is disclosed as unmeasured, never as clean.
  • D44 Platform End-of-Life: The support table is FROZEN, so it goes out of date by losing RECALL: a release that ended support after the table was written is missed until the table is refreshed, and this dimension reading 10 is not evidence that a platform is current. Only platforms the repository DECLARES in a place this pass reads are seen — a runtime named only in a Dockerfile (D31's subject), in a CI workflow (D29's), or in a file this pass does not parse (go.mod, a Gemfile ruby directive) is invisible here, which is why a repository declaring none of them abstains rather than scoring. Only frameworks with a PUBLISHED support policy are tracked: React, Flask and Express publish none, so their age cannot be judged and their absence from a report is not a statement that they are supported.
  • AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
  • 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.

Dimensions

D1 · Cyclomatic Complexity9.0 / 10Strong✓ Tool-verified

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.

Maturity: Documented → Verified → Prevented · effective 9.0 / 10 · rule-coverage 100% · ceiling Prevented

2 method(s) exceeded the cyclomatic complexity threshold of 15; the worst was MtQuoteExpert.runController at 35.

MtQuoteExpert.runController (cyclomatic 35)TestClients/TestServer/MtQuoteExpert.cs.cs:143
MtRpcClient.OnReceive (cyclomatic 17)REDACTED:196

What to do

  1. Bring the 2 bodies over 15 down to 15 or less in Cyclomatic Complexity — start with MtQuoteExpert.runController (cyclomatic 35), MtRpcClient.OnReceive (cyclomatic 17). — This score is capped by its worst body, so a finding fixed alone moves it by almost nothing — the next one down takes its place. Refactoring these 2 together lifts Cyclomatic Complexity from 9.0 to about 10.0/10, projected with the scoring formula itself and assuming each lands exactly at 15.

Detailed fixes: d1_recommendation.md · top locations in Appendix A, every location in findings.md.

D2 · Cognitive Complexity8.1 / 10Strong✓ Tool-verified

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.

Maturity: Documented → Verified → Prevented · effective 8.1 / 10 · rule-coverage 100% · ceiling Prevented

3 method(s) exceeded the cognitive complexity threshold of 15; the worst was MtQuoteExpert.runController at 76.

MtQuoteExpert.runController (cognitive 76)TestClients/TestServer/MtQuoteExpert.cs.cs:143
MtRpcClient.OnReceive (cognitive 16)REDACTED:196
Program.printCharts (cognitive 16)TestClients/TestServer/Program.cs:152

What to do

  1. Bring the 1 body over 30 down to 30 or less in Cognitive Complexity — start with MtQuoteExpert.runController (cognitive 76). — Refactoring it lifts Cognitive Complexity from 8.1 to about 9.0/10.

Detailed fixes: d2_recommendation.md · top locations in Appendix A, every location in findings.md.

D3 · God Classes8.5 / 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.

Maturity: Documented → Verified → Prevented · effective 8.5 / 10 · rule-coverage 100% · ceiling Prevented

11 god class(es) detected.

FileTooLong: MtApi/MtApiClient.cs · ×5MtApi/MtApiClient.cs
TooManyMethods: MtApiClient · ×4MtApi/MtApiClient.cs
MethodTooLong: MtQuoteExpert.runController · ×2TestClients/TestServer/MtQuoteExpert.cs.cs:143

What to do

  1. Resolve the 5 FileTooLong finding(s) in God Classes — start with MtApiClient.cs, MtApi5Client.cs, ViewModel.cs. — One of this dimension's main actionable groups (5 warning-level).
  2. Resolve the 4 TooManyMethods finding(s) in God Classes — start with MtApiClient.cs, MtApi5Client.cs, ViewModel.cs. — One of this dimension's main actionable groups (4 warning-level).
  3. Resolve the 2 MethodTooLong finding(s) in God Classes — start with MtQuoteExpert.cs.cs, ViewModel.cs. — One of this dimension's main actionable groups (2 warning-level).

Detailed fixes: d3_recommendation.md · top locations in Appendix A, every location in findings.md.

D4 · Code Duplication6.2 / 10Adequate✓ Tool-verified

What it measures: How much of the production code is copy-pasted: the share of production lines inside a reported copy (every copy of a duplicated block or of an edited member, each line once), 10 at none and 0 at a quarter of the lines.

Method: Code duplication via token-stream sliding windows with type-aware normalization (locals masked, type names preserved), scored on the share of production lines inside a reported copy (each line once; 10 at none, 0 at a quarter). Deterministic.

Maturity: Documented → Verified → Prevented · effective 6.2 / 10 · rule-coverage 100% · ceiling Verified

16 duplicated block group(s) detected. 9.6 % of the production lines (1,682 of 17,500) are in a reported copy. A further 32 rows report members as variants of one another; the share counts each copied line once, however many rows cite it. 10 of the 48 are in trees this repository does not ship — vendored, example/demo, project-template, fixture and benchmark code — and are ranked below the shipped groups rather than excluded from them: the duplication there is real and is still counted in this dimension's score. The dimensions that publish a production-file census leave those trees out of theirs, so this count is deliberately drawn over the wider population. Measured on part of this repository only: .m (23% of production source) was not exposed to the token comparison, so duplication there is unmeasured and is not in this count.

Edited copy of a member (6 corresponding lines) · ×3MtApi5/MtApi5Client.cs:3553
Duplicated block (12 lines × 2) · ×3MTApiService/MtRegistryManager.cs:174
Edited copy of a member (16 corresponding lines) · ×2MtApi5/MtApi5Client.cs:3446
Edited copy of a member (17 corresponding lines) · ×2MtApi5/MtApi5Client.cs:3464
Edited copy of a member (4 corresponding lines) · ×2MtApi5/MtApi5Client.cs:70

+ 34 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 3 Edited copy of a member (6 corresponding lines) finding(s) in Code Duplication — start with MtApi5Client.cs (3). — One of this dimension's main actionable groups (3 warning-level).
  2. Resolve the 3 Duplicated block (12 lines × 2) finding(s) in Code Duplication — start with MtRegistryManager.cs, MtApi5Client.cs, MtApiClient.cs. — One of this dimension's main actionable groups (3 warning-level).
  3. Resolve the 2 Edited copy of a member (16 corresponding lines) finding(s) in Code Duplication — start with MtApi5Client.cs (2). — One of this dimension's main actionable groups (2 warning-level).

Detailed fixes: d4_recommendation.md · top locations in Appendix A, every location in findings.md.

D5 · Coupling9.2 / 10Stronggated by 1 serious finding✓ Tool-verified

What it measures: Whether volatile projects sit underneath others that depend on them (so their churn ripples upward), and whether project dependencies form cycles. A widely-depended-on but stable shared/kernel project is healthy, not penalised.

Method: Dependency cycles via elementary-DFS over real .csproj references, plus Martin instability (afferent/efferent) per project. Exhaustive over the reference graph, deterministic.

Coverage: Exhaustive · type-level: afferent/efferent coupling + cycles computed over every production type — the population is all types, not a name convention.

Maturity: Documented → Verified → Prevented · effective 9.2 / 10 · rule-coverage 100% · ceiling Prevented

10 projects, 0 dependency cycle(s), 0 unstable depended-on project(s).

Off the main sequence: MtClientMtClient/MtClient.csproj:1

What to do

  1. Resolve the 1 Off the main sequence finding(s) in Coupling — start with MtClient.csproj. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d5_recommendation.md · top locations in Appendix A, every location in findings.md.

D6 · Cohesion (LCOM4)9.3 / 10Stronggated by 2 serious findings✓ Tool-verified

What it measures: Whether a class's methods are focused on a single responsibility.

Method: LCOM4 cohesion per production class with at least two methods: connected components of methods sharing state or calls, computed syntactically. Deterministic, not a proxy.

Coverage: Exhaustive · type-level: LCOM4 cohesion computed over every production class — the population is all types, not a name convention.

Maturity: Documented → Verified → Prevented · effective 9.3 / 10 · rule-coverage 100% · ceiling Verified

2 of 33 classes have LCOM4 above 3.

Low cohesion: MtApi5Client (LCOM4 6) · ×2MtApi5/MtApi5Client.cs:9

What to do

  1. Resolve the 2 Low cohesion finding(s) in Cohesion (LCOM4) — start with MtApi5Client.cs, MtApiClient.cs. — One of this dimension's main actionable groups (2 warning-level).

Detailed fixes: d6_recommendation.md · top locations in Appendix A, every location in findings.md.

D8 · Code Coverage0.0 / 10Critical✓ Tool-verified

What it measures: How much of the code is actually exercised by tests.

Method: Coverage from the analyzer's own run of the suite, computed per-file with structured exclusions for generated, trivial, and glue code. A coverage report found in the repository is never read. When the suite can't be built/run in-image, coverage is reported NOT-MEASURED (excluded from the score) with the precondition to make it measurable — never a LoC-ratio proxy folded in as if measured. Deterministic.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 100% · ceiling Verified

No automated tests — no test code was found in this repository.

No automated tests

What to do

  1. Resolve the 1 No automated tests finding(s) in Code Coverage. — One of this dimension's main actionable groups (1 issue-level).

Detailed fixes: d8_recommendation.md · top locations in Appendix A, every location in findings.md.

D13 · Secret Scanning5.0 / 10Adequate✓ Tool-verified

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.

Maturity: Documented → Verified → Prevented · effective 5.0 / 10 · rule-coverage 100% · ceiling Prevented

1 secret(s) detected.

REDACTED

What to do

  1. Resolve the 1 Leaked secret finding(s) in Secret Scanning — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).

Detailed fixes: d13_recommendation.md · top locations in Appendix A, every location in findings.md.

D14 · License Compliance10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether the licenses of third-party packages are compatible with your policy.

Method: Third-party package licenses resolved from declared package metadata and checked against the configured policy (allow/deny/copyleft). Deterministic; clean = no incompatible license found at metadata depth.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Verified

0 of 116 packages use a banned license. ★ DEPTH: this repository's MSBuild projects declare 2 direct `PackageReference`(s), and 113 further package(s) were reached beyond them by closing the graph over nuget.org's own nuspec dependency graph — so a banned licence pulled in only by a dependency's OWN dependencies is inside this verdict. A package whose licence nuget.org could not be asked for is not graded, and version ranges are taken at their lower bound, so this is the closure as that graph states it rather than a restored consumer's exact resolution.

✓ On the Gold path — maintain.

Detailed fixes: d14_recommendation.md.

D15 · Churn × Complexity Hotspots10.0 / 10Exemplary✓ Tool-verified

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.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

No churn × complexity hotspots in the window.

✓ On the Gold path — maintain.

Detailed fixes: d15_recommendation.md.

D17 · Explicit Debt8.4 / 10Adequategated by 4 critical findings✓ Tool-verified

What it measures: Acknowledged debt left in the code — TODOs, dead code, suppressed warnings.

Method: Roslyn syntactic debt markers (suppressions/TODO/FIXME/HACK/empty-catch/commented-code/Obsolete) plus SymbolFinder dead-code analysis; weighted-debt-per-KLoC density deducted 2.0x per unit. Deterministic, exhaustive.

Maturity: Documented → Verified → Prevented · effective 8.4 / 10 · rule-coverage 100% · ceiling Prevented

45 deducted debt markers + unmeasured dead symbols across 17500 LoC in the .NET projects (0.8/KLoC) → score 8.4. Dead code not measured: the solution did not load cleanly, so the reference search was skipped. Measured on the .NET source only: .m (23% of production source) was not read, and carries at least 0 uncounted task marker(s) in 0 file(s).

EmptyCatchBlock · ×3MtApi/Monitors/TradeMonitor.cs:52
WriteOnlyPrivateFieldTestClients/TestServer/MetaTrader.cs:214
ObsoleteWithCallers · ×16MtApi/MtApiClient.cs:138
TodoComment · ×10MtApi/Monitors/TradeMonitor.cs:54
CommentedOutCode · ×10MtApiSetupActions/CustomAction.cs:37

+ 1 more group(s) — more in Appendix A; the complete list is findings.md.

What to do

  1. Resolve the 3 EmptyCatchBlock finding(s) in Explicit Debt — start with TradeMonitor.cs (2), MtApi5Client.cs. — One of this dimension's main actionable groups (3 issue-level).
  2. Resolve the 1 WriteOnlyPrivateField finding(s) in Explicit Debt — start with MetaTrader.cs. — One of this dimension's main actionable groups (1 issue-level).
  3. Resolve the 16 ObsoleteWithCallers finding(s) in Explicit Debt — start with MtApiClient.cs (16). — One of this dimension's main actionable groups (16 warning-level).

Detailed fixes: d17_recommendation.md · top locations in Appendix A, every location in findings.md.

D18 · Solution Shape3.0 / 10Weak✓ Tool-verified

What it measures: Whether the solution is laid out in a sensible, conventional structure.

Method: Solution structure: project count, decomposition, shell-project detection, build success (confirmed failures cap the score); traced to actual .sln files and binaries. Deterministic.

Maturity: Documented → Verified → Prevented · effective 3.0 / 10 · rule-coverage 100% · ceiling Documented

10 projects, 152 source files, 17500 hand-written lines of code (17500 production / 0 test — the split is derived per file: test is what its project, its own path, or a compile-guarded region marks as test, and a file carrying no test signal counts as production), plus 2867 generated (machine-written code — designer, scaffolded and tool-emitted files — excluded from quality), 5 inter-project edges (build failed). Measured across 3 solutions loaded as one workspace: `MetaTraderApi_2022.sln`, `TestClients/TestMtApi/TestMtApi.sln`, `Examples/MtApi5Samples/MtApi5Samples.sln`.

Build failed
Thin analysable surface across projects: MtApiSetupActions · ×2MtApiSetupActions/MtApiSetupActions.csproj

What to do

  1. Resolve the 2 Thin analysable surface across projects finding(s) in Solution Shape — start with MtApiSetupActions.csproj, TestMtApi.vbproj. — One of this dimension's main actionable groups (2 recommendation-level).
  2. Resolve the 1 Build failed finding(s) in Solution Shape. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d18_recommendation.md · top locations in Appendix A, every location in findings.md.

D19 · Documentation Quality10.0 / 10Exemplary○ Nothing flagged

What it measures: Whether the project's documentation is clear, complete, and useful.

Method: Every README, docs/ document and root guide parsed by its markup and measured in Unicode letters. Published: a runnable or packaged .NET project whose README (or a document it links, or a root guide) shows no example, and a root README naming none of three or more projects. Overview, licence, boilerplate, wall-of-text, empty-section and XML-doc rows are measured and withheld (counted in gaps) after adjudication. Deterministic, exhaustive, advisory.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

2 of 2 documentation facets pass in full. 2 document(s) read across 6 unit(s).

✓ On the Gold path — maintain.

Detailed fixes: d19_recommendation.md.

D24 · Comment Value0.0 / 10Critical✓ Tool-verified

What it measures: Whether comments are worth it — explaining WHY (valuable) rather than WHAT (redundant).

Method: Every inline C# comment compared word by word with the identifiers, literals and constructs of the code it annotates (taken from the syntax); a comment whose words that code already contains is redundant, as are closing-brace labels and generator template text. Comments giving a reason or a reference are kept; other scripts and languages are not judged. Deterministic, exhaustive, advisory.

Maturity: Documented → Verified → Prevented · effective 0.0 / 10 · rule-coverage 99% · ceiling Documented

25 of 83 judged comments only repeat the code they sit on (30.1 %). 8 comment(s) in another language or script were not judged.

redundant comment · ×19MTApiService/Properties/AssemblyInfo.cs:5
doc comments repeat the names · ×2MtApi/Monitors/MtMonitorBase.cs:14

What to do

  1. Resolve the 19 redundant comment finding(s) in Comment Value — start with AssemblyInfo.cs (8), AssemblyInfo.vb (4), Form1.vb (2). — One of this dimension's main actionable groups (19 recommendation-level).

Detailed fixes: d24_recommendation.md · top locations in Appendix A, every location in findings.md.

D26 · Project Cohesion10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether each project is a focused, coherent unit rather than an oversized grab-bag.

Method: Project size overshoot penalties (LoC / public-type count / namespace count, 2-of-3 flag) weighted by log magnitude. Exhaustive across projects, deterministic.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

0 of 10 projects flagged as possibly oversized/incoherent.

✓ On the Gold path — maintain.

Detailed fixes: d26_recommendation.md.

D27 · Navigability9.4 / 10Exemplary✓ Tool-verified

What it measures: How far you must trace to follow a call — low indirection and co-located slices read easier.

Method: Call indirection (interface hops, cross-namespace calls, slice-locality scaled) over a sampled set of method invocations, size-aware baseline. Sampled; confidence discounted by symbol-resolution gaps. C# also names each pass-through layer (a class whose every public method only forwards its own parameters to one collaborator) as a located finding; the score is not affected.

Coverage: Slice locality from the first namespace segments, SAMPLED (≤400 methods) — not exhaustive.

Maturity: Documented → Verified → Prevented · effective 9.4 / 10 · rule-coverage 100% · ceiling Documented

35 % of calls cross a namespace and 6 % go through an interface, but 98 % of collaborators are co-located — so a call's collaborators sit together and tracing stays easy. Baseline: medium — clean/modular boundaries expected. Measured over the .cs source only — this repository's .m was not sampled for call sites, so this score covers part of the tree, not all of it.

Pass-through layer · ×3MtApi5/MtApi5Client.cs:3637

✓ On the Gold path — maintain.

Detailed fixes: d27_recommendation.md · top locations in Appendix A, every location in findings.md.

D28 · Secrets (history)9.0 / 10Adequategated by 1 critical finding✓ Tool-verified

What it measures: Whether any secrets were ever committed — scanned across the full git history, not just now.

Method: Secret scan via TWO gitleaks detect passes in an isolated checkout — the full git history, then a second --no-git pass over the working tree as it stands — merged and de-duplicated by (rule, file, line); each match flagged High. Both invocations are recorded in the audit trail. Exhaustive; when the tool is absent, or when its output cannot be parsed into the expected shape, the dimension is WITHHELD as an explicit measurement gap on our side — unscored and excluded from the lens, never a hedged middling score.

Maturity: Documented → Verified → Prevented · effective 9.0 / 10 · rule-coverage 100% · ceiling Documented

1 finding(s): 0 critical, 1 high, 0 medium, 0 low.

REDACTED

What to do

  1. Resolve the 1 High secret finding(s) in Secrets (history) — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).

Detailed fixes: d28_recommendation.md · top locations in Appendix A, every location in findings.md.

D29 · Static Analysis (SAST)9.5 / 10Stronggated by 1 serious finding✓ Tool-verified

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).

Maturity: Documented → Verified → Prevented · effective 9.5 / 10 · rule-coverage 100% · ceiling Documented

1 finding(s): 0 critical, 0 high, 1 medium, 0 low. semgrep hit a parse error in 14 file(s) — `MtApi/Monitors/AvailabilityOrdersEventArgs.cs` (line 3, lines 3–8, line 14), `MtApi/MtApiClient.cs` (lines 3347–3348, line 3394), `MtApi/MtConnectionEventArgs.cs` (line 3, line 5, line 8), `MtApi/MtExecutionException.cs` (line 3, line 5), `MtApi/MtQuoteEventArgs.cs` (lines 3–4, line 7), … (+9 more) — so no absence of findings in the named regions is evidence of anything; rows reported elsewhere in those files are real. Fix the syntax error (or exclude the file deliberately) and re-scan to cover them. In 11 of those file(s) — `MtApi/Monitors/AvailabilityOrdersEventArgs.cs`, `MtApi/MtApiClient.cs`, `MtApi/MtConnectionEventArgs.cs`, `MtApi/MtExecutionException.cs`, `MtApi/MtQuoteEventArgs.cs`, … (+6 more) — the break is a C# primary constructor, which semgrep's grammar cannot parse and which hides the type from every rule scoped to it; those files were re-scanned from a shadow copy with the constructor's parameter list blanked (line and column preserving), which restores the type to the rules, and 0 additional row(s) came from that pass. Only the header's own parameter list is unread in them.

REDACTED

What to do

  1. Resolve the 1 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d29_recommendation.md · top locations in Appendix A, every location in findings.md.

D30 · Dependency Vulnerabilities9.8 / 10Stronggated by 1 serious finding✓ Tool-verified

What it measures: Whether any dependency has a known published vulnerability (CVE), direct or transitive, in ANY ecosystem the repository declares — Dart pub, Elixir and Erlang via Hex, Go modules, Java and Kotlin via Maven/Gradle, JavaScript/npm, .NET/NuGet, PHP/Composer, Python/PyPI, RubyGems, Rust/Cargo and Swift.

Method: Dependency-CVE scan across every ecosystem the repository declares, scored ONCE. Three sources are unioned and deduplicated by advisory identity (rule id + alias closure, CVE<->GHSA) scoped to package+version, keeping the worst severity: `osv-scanner --recursive` over osv.dev for Dart pub, Elixir/Hex (and Erlang, whose `rebar.lock` syft first converts to a CycloneDX SBOM the scanner reads, with rows attributed back to the lock), Go, Java and Kotlin via Maven/Gradle (and Scala, whose sbt build's pinned direct declarations are written into a CycloneDX SBOM the scanner reads, with rows attributed back to the build file), npm, PHP/Composer, Python/PyPI, RubyGems, Rust/Cargo and Swift; `trivy fs --scanners vuln` for npm lockfiles; and `dotnet list package --vulnerable --include-transitive` for NuGet (with per-advisory collapse of the project x target-framework fan-out), plus a DECLARED-dependency arm that resolves a published gem's gemspec against rubygems.org where no Gemfile.lock is committed. `SeverityScore(c,h,m,l, normalizer 8.0)`. NotApplicable only when NO ecosystem is readable; if any applicable ecosystem could not be scanned the findings are REPORTED and the score is withheld. Supersedes the npm and OSV arms, retired 2026-09-05. Advisory since rubric-2026.11.2 (CAI decision 0006): every row is a match against a vulnerability database that changes daily, so the reading is shown and never moves a scored dimension, lens or the headline.

Maturity: Documented → Verified → Prevented · effective 9.8 / 10 · rule-coverage 100% · ceiling Documented

1 finding(s): 0 critical, 0 high, 1 medium, 0 low. Partial dependency scan: 1 of 2 declared ecosystem(s) were scanned (osv), and the findings above are real and complete for them. nuget was not scanned (nuget: the solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan), so this is not the whole dependency surface and the result is reported at reduced confidence.

REDACTED

What to do

  1. Resolve the 1 Medium CVE finding(s) in Dependency Vulnerabilities — start with REDACTED. — One of this dimension's main actionable groups (1 warning-level).

Detailed fixes: d30_recommendation.md · top locations in Appendix A, every location in findings.md.

D34 · Knowledge Freshness9.1 / 10Exemplary✓ Tool-verified

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.

Maturity: Documented → Verified → Prevented · effective 9.1 / 10 · rule-coverage 100% · ceiling Documented

3 of 33 significant source file(s) are orphaned — their living knowledge has decayed to nothing, so no one currently understands them. The largest is MtApi/Monitors/MtMonitorBase.cs. Counted over 33 of the 141 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.

Orphaned file · ×3MtApi/Monitors/MtMonitorBase.cs:1
Orphaned files with no living knowledge

✓ On the Gold path — maintain.

Detailed fixes: d34_recommendation.md · top locations in Appendix A, every location in findings.md.

D35 · Change Coupling10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether files that change together actually belong together — pairs that repeatedly co-change in git history despite having no explicit code dependency, surfacing the hidden/logical coupling (and boundaries in the wrong place) a static scan can't see.

Method: Pairwise co-occurrence over the per-commit file sets in git history (production source only — tests and generated dropped): Degree-of-Coupling = shared ÷ min individual revisions, reported above noise floors (each file ≥10 revisions, ≥5 shared commits, ≥50% strength); sweeping commits excluded. Deterministic over fixed history.

Coverage: Population: PRODUCTION source files only — test and generated files are dropped before pairing, so a class co-changing with its own test (trivially ~100%) can't drown the real production↔production coupling. Pairs ranked by Degree-of-Coupling. A non-source file is never a coupling PARTICIPANT either: documentation, schemas, config and data files are dropped with the rest, so a code↔docs pair — a command and the reference page that restates it — is not reported however strongly the two co-change; nor is coupling that runs THROUGH a build step or config file.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

No strong hidden change-coupling between production files.

✓ On the Gold path — maintain.

Detailed fixes: d35_recommendation.md.

D43 · Malicious Dependencies10.0 / 10Exemplary✓ Tool-verified

What it measures: Whether any dependency the repository declares is published as MALICIOUS rather than merely vulnerable — a package that is an attacker's work, in any ecosystem osv-scanner reads. Reported apart from D30 because the answer is binary: there is no safe version to upgrade to, and the fix is to remove the package and rotate every credential it could have read.

Method: The same dependency scan D30 reads, partitioned on the scanner's own classification rather than rescanned: a row is MALICIOUS when its id is in the `MAL-` space (the ossf/malicious-packages feed) OR its `database_specific.cwe_ids` carries `CWE-506` ("Embedded Malicious Code"). Both channels are structural; the summary text is deliberately NOT read, because a malicious-package record whose summary says only "Critical severity vulnerability" is a real shape ([GHSA redacted]) and a text matcher misses it. Scored BINARY: any surviving row is 0, whatever its severity and however many CVEs sit beside it — a hostile dependency is not a quantity. Applicability and degradation are D30's: NotApplicable only when no ecosystem is readable, and an unscannable ecosystem degrades rather than reading clean. Advisory since rubric-2026.11.2 (CAI decision 0006): the malicious-package feed is a database that changes daily, so the reading is shown and never moves a scored dimension, lens or the headline.

Maturity: Documented → Verified → Prevented · effective 10.0 / 10 · rule-coverage 100% · ceiling Documented

No dependency in any ecosystem this repository declares is published as malicious.

✓ On the Gold path — maintain.

Detailed fixes: d43_recommendation.md.

D44 · Platform End-of-Life2.0 / 10Critical✓ Tool-verified

What it measures: Whether anyone still ships security patches for the platform this repository RUNS ON — the runtime it pins and the framework majors its own constraints hold it to. Separate from D12 because the question differs: a current Django on an end-of-life Python is perfectly up to date and completely unsupported, and the fix is a migration rather than a version bump. What the repository says it merely SUPPORTS is never charged.

Method: End-of-life PLATFORM read from the repository's own declarations and graded against a FROZEN, dated table of vendor support dates — no network, no feed, no API, so this dimension answers identically inside a closed scan fence. Two subjects: a RUNTIME the project pins (a single or all-end-of-life TargetFramework, a .nvmrc or .python-version, a requires-python CAP) and a FRAMEWORK major a dependency constraint cannot move off (a caret, tilde or exact version; `vue@^2.7.16` pins Vue 2). A FLOOR is deliberately never charged — `requires-python = ">=3.8"` states what a package SUPPORTS, not what it runs on — and a multi-target project is charged only when EVERY target is out of support. Runtime 4.0/product capped 8.0, framework 1.5 capped 4.5. The table is safe to freeze because a statement about support that ended in the past cannot become false: it loses recall as it ages, never precision, and a test asserts every entry predates the freeze date. Disjoint from D31 (a container image's OS layer) and D29 (the toolchain a CI workflow installs). Abstains when the repository declares no platform this pass reads — never scores it clean.

Maturity: Documented → Verified → Prevented · effective 2.0 / 10 · rule-coverage 100% · ceiling Documented

2 end-of-life runtime(s) and 0 end-of-life framework(s), read from 10 platform declaration(s) and 0 dependency declaration(s). This dimension reads what the repository says about ITSELF — a pinned target framework, a version file, a capped requires-python, a Rust toolchain pin, a framework major a constraint cannot move off. A FLOOR is deliberately never charged: `requires-python = ">=3.8"` states what the package SUPPORTS, not what it runs on, and a well-maintained library declares exactly that while running its own CI on a current release. The end-of-life facts are FROZEN and dated, so this dimension needs no network and answers identically inside a closed scan fence; as the table ages it loses recall and never precision, because a statement about support that ended in the past cannot become false. The OS layer of a container image is D31's question and the toolchain a CI workflow installs is D29's; this row is neither.

End-of-life runtime: .NET Framework net40 · ×3MTApiService/MTApiService.csproj:14

What to do

  1. Resolve the 3 End-of-life runtime finding(s) in Platform End-of-Life — start with MTApiService.csproj, TestServer.csproj, TestMtApi.vbproj. — One of this dimension's main actionable groups (3 warning-level).

Detailed fixes: d44_recommendation.md · top locations in Appendix A, every location in findings.md.

Frontend & cross-cutting dimensions

R = React/JS · M = Maturity · P = Readiness.

AX10 · Code composition10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — How the codebase splits by code ROLE — domain, application, infrastructure, test, generated. The significance map behind the knowledge/coupling weighting, and a DDD signal in its own right: a thin domain core under fat infrastructure is the anemic-domain smell, quantified. How each file's role is decided, because the split is only as good as that: a generated name or a build-output tree makes it Generated, a test project makes it Test, and otherwise the file's NAMESPACE and PATH words are matched against fixed vocabularies in a fixed ORDER — domain, then infrastructure, then application — so a file whose words hit two layers is counted under the earlier one. A production file matching none of them counts as application, so that share reads 'application or unclassified' rather than a measured application layer. Roles come from naming convention, never from what the code does.

Method: Roslyn line-count by code ROLE: every source file classified Domain/Application/Infrastructure/Test/Generated by namespace + path convention (the shared CodeRoleClassifier), then significant lines summed per role. Deterministic; the advisory score is the business-logic (domain+application) share of production code.

Coverage: Population: ALL source files, each bucketed into ONE of five roles (Domain/Application/Infrastructure/Test/Generated) by namespace + path convention — a file whose layer isn't named in the convention falls to Application (the neutral default), and the split is line-count, not semantic depth or business value.

AX2 · Stateful singletons1.0 / 10Critical✓ Tool-verified

Other · Architecture — Whether singleton services avoid mutable shared instance state that concurrent callers would race on.

Method: Roslyn scan: singleton field mutations unguarded by lock or Interlocked, per type; syntax-based guard detection. Deterministic, traceable per field.

  • `ListBoxBehavior` keeps mutable `static` state — one slot for the whole process, shared by every thread that reaches the type however its instances are created — and mutates it outside any lock (Associations; e.g. `Associations` at line 63). Concurrent callers lose updates, and a collection that is not built for concurrent writers can corrupt. — TestClients/MtApi5TestClient/ListBoxBehavior.cs:10
  • `MtQuoteExpert` keeps mutable `static` state — one slot for the whole process, shared by every thread that reaches the type however its instances are created — and mutates it outside any lock (IDcount; e.g. `IDcount` at line 91). Concurrent callers lose updates, and a collection that is not built for concurrent writers can corrupt. — TestClients/TestServer/MtQuoteExpert.cs.cs:10

What to do

  • A `static` field is one slot for the whole process, however its type is created: back it with a thread-safe type (ConcurrentDictionary, Interlocked), take a lock around every write, or move it into a registered singleton that does.
AX3 · Project dependency cycles10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether the project-reference graph is acyclic (cycles block independent build/deploy and signal eroding boundaries).

Method: Project reference cycles via elementary-DFS over real .csproj references, using the engine shared with D5/D7; cyclic versus acyclic. Exhaustive, deterministic.

  • The namespaces MtApi5 ↔ MtApi5.MtProtocol depend on each other. The lightest dependency in the cycle is MtApi5 → MtApi5.MtProtocol (MtApi5.MqlTick → MtApi5.MtProtocol.MtTick, 3 type pair(s)); cut that one first, e.g. by moving the shared type to a namespace both can use or inverting it behind an interface. — MtApi5/MqlTick.cs:1

What to do

  • Break namespace cycles inside a project by moving the shared type to a namespace both sides can use, or by inverting the back edge behind an interface.
AX4 · Dependency direction10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether dependencies point inward (Domain ← Application ← Infrastructure/Web) — the clean-architecture dependency rule, checked across the project graph.

Method: Layer violations by name-segment inference (Domain/Core to Application to Infrastructure/Web) over the project-reference graph. Exhaustive over all projects, deterministic.

AX5 · Architecture & structure10.0 / 10Exemplary✓ Tool-verified

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.

AX6 · Interface segregation10.0 / 10Exemplary✓ Tool-verified

Other · Architecture — Whether interfaces stay focused rather than fat — the Interface-Segregation principle (SOLID 'I').

Method: Roslyn scan: public interface declared-member counts (accessors fold into their property/event); fat-interface threshold (over 15 declared members) flagged per type. Each finding also reports the distinct-OPERATION count — members counted by name, so an overload group counts once — which decides whether it states the caller-side ISP harm or the implementer-side burden of an overload set. TypeScript: exported interfaces that declare behaviour, counted over their REQUIRED operations (method signatures and function-typed properties with no `?`, once per signature) — data-shape interfaces and ambient .d.ts declarations are outside the population; JavaScript declares no interfaces and is not applicable. Deterministic, type-level.

C2 · Access Controls0.0 / 10Critical✓ Tool-verified

Other · Security — Whether access is authorized by default — a framework authorization attribute/decorator or policy, or imperative guard methods (throw-on-violation) called from handlers.

Method: Roslyn scan: [Authorize] usage and authorization policies, plus imperative throw-on-violation guard methods detected via syntax. Deterministic.

  • Service contract 'IMtApi' is hosted by a ServiceHost this repository opens itself — every operation on it is reachable by any caller that can connect. (MTApiService/MtServer.cs:119) Nothing in the source decides WHO may invoke those operations — no [PrincipalPermission], no ServiceAuthorizationManager, and no guard method that refuses the caller. A local IPC transport is not an access control: it authenticates the connection, it does not authorize the command.

What to do

  • Authorize the service host, don't just host it: derive a ServiceAuthorizationManager and set it as the host's authorization policy (or decorate each [OperationContract] with [PrincipalPermission], or call an explicit guard on OperationContext.Current.ServiceSecurityContext at the top of every operation) so the caller's identity has to satisfy a named rule before the operation runs.
GD1 · Unfinished & placeholder code10.0 / 10Exemplary✓ Tool-verified

Other · Code Health — Unreviewed-generation residue: shipped members still throwing NotImplementedException, and placeholder string literals left in non-test, non-generated code. Scored as a quality signature, never as a claim about authorship.

Method: Roslyn syntax scan: NotImplementedException throws and placeholder string literals in non-test, non-generated shipped code. Deterministic, code-shape signature.

  • A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface. (×5) — MtClient/MtMessage.cs:66, MtClient/MtMessage.cs:88, MtClient/MtMessage.cs:108, …

What to do

  • Finish or delete NotImplementedException stubs and replace placeholder literals before shipping.
IC1 · Incompleteness & stubs7.5 / 10Strong✓ Tool-verified

Other · Code Health — Unfinished work detected by code SHAPE, not keywords: members that only throw a "not implemented" exception, methods that take inputs and return a constant, async methods that never await, dead `if (false)` / `#if false` branches, and skeleton types most of whose members are holes. A real, objective slice of technical debt.

Method: Roslyn syntax scan: incompleteness by code shape (constant-returning methods, async-never-await, #if false branches, guards that return what the code already falls through to, tests an earlier guard already decided, comparisons against NaN, skeleton types), not keyword-gated. Deterministic, code-shape heuristic.

  • `GetMessageBody` is a shipped member whose whole body throws NotImplementedException — scaffolding that was never completed. Implement it or remove the dead surface. (×5) — MtClient/MtMessage.cs:66, MtClient/MtMessage.cs:88, MtClient/MtMessage.cs:108, …
  • `instrument_InstrumentUpdate` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it. — TestClients/TestServer/MetaTrader.cs:185
  • A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers). (×34) — MTApiService/LogConfigurator.cs:93, MtApiSetupActions/CustomAction.cs:18, MtApiSetupActions/CustomAction.cs:20, …

What to do

  • Finish or delete the unfinished stubs (NotImplementedException / empty / constant-returning bodies) — they are dead surface that looks live.
  • Clear the softer debt: remove commented-out code and dead branches, re-enable or delete skipped tests, and replace blanket warning suppressions with targeted ones.
M1 · Documentation (README)7.3 / 10Strong✓ Tool-verified

Maturity · Maturity — Whether the repository and its projects have a README, and whether it is substantive.

Method: Filesystem scan: README presence, word count, and headings for depth; git history for staleness. Exhaustive across root and project dirs, deterministic.

What to do

  • Explain in the README how to run the tests. Add a section called Testing to the README in the repository's top folder, saying how to run the test suite.
M2 · Architecture documentation2.0 / 10Critical✓ Tool-verified

Maturity · Maturity — Whether key decisions (ADRs) and the high-level shape (C4/diagrams) are written down.

Method: Filesystem scan: ADR folder/naming conventions or content, plus Mermaid/PlantUML/C4/architecture.md discovery. Exhaustive, deterministic.

  • No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.

What to do

  • Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them.
M3 · Folder & project structure8.0 / 10Strong✓ Tool-verified

Maturity · Maturity — Whether the repository is organised deliberately: production code and tests are set apart in a way its ecosystem or the repository itself declares.

Method: Filesystem scan: src/test folder separation and namespace-prefix consistency (majority RootNamespace agreement). Exhaustive across projects, deterministic.

P1 · CI/CD gates0.0 / 10Critical✓ Tool-verified

Readiness · Readiness — Whether an automated pipeline builds and tests every change.

Method: Filesystem scan: CI workflow files (.github/workflows, .gitlab-ci.yml, etc.) for build and test stages. Exhaustive, deterministic.

  • No CI workflow found (.github/workflows, azure-pipelines.yml, .gitlab-ci.yml, …) — changes aren't gated by an automated build/test.

What to do

  • Add a CI workflow that builds and runs the test suite on every push/PR.
P2 · Observability7.8 / 10Strong✓ Tool-verified

Readiness · Readiness — Whether the code is diagnosable in production — structured logging, tracing/metrics, health checks.

Method: Filesystem/Roslyn scan: structured-logging frameworks (Serilog, NLog), OpenTelemetry, and health-check endpoint patterns. Exhaustive, deterministic.

  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 34 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:34
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 37 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:37
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 49 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:49
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 62 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:62
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 68 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:68
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 82 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:82
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 92 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:92
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 122 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:122
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 125 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:125
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 137 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:137
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 158 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:158
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 171 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:171
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 177 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:177
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 180 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:180
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 193 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:193
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 194 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:194
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 195 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:195
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 207 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:207
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 208 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:208
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 209 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:209
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 210 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:210
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 211 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:211
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 233 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:233
  • `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 240 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters. — TestClients/TestServer/Program.cs:240

What to do

  • Replace `Console.Write…` in service code with the project's injected `ILogger<T>` (message templates with named properties), so delivery outcomes and failures reach the log pipeline with a level and a category.
P3 · Security & performance tooling0.0 / 10Critical✓ Tool-verified

Readiness · Readiness — Whether SAST, secret/dependency scanning and performance benchmarking are wired in (presence, not runtime).

Method: Filesystem scan: SAST configuration, dependency-update automation, secret scanning, and a benchmark harness or benchmark step — in this repository's own ecosystem. Exhaustive, deterministic.

  • No static application security testing detected. For this repository's stack, add CodeQL's csharp pack, or a .NET security analyzer package (or `semgrep --config=auto`, which runs on any language) — this repository has no CI pipeline yet, so run it locally to clear the existing findings, then make it a step of the first workflow you add so a regression fails the build. What was searched, so you can tell an absence from a miss: the 0 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
  • `MtApi/MtApi.csproj` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`. — MtApi/MtApi.csproj:11

What to do

  • Run what this repository's stack ships: CodeQL's csharp pack, or a .NET security analyzer package — or `semgrep --config=auto`, which runs on any language — locally for now, since there is no CI pipeline here yet, and as a step of the first workflow you add so a security regression fails the build instead of landing.
  • Enable Dependabot/Renovate or a dependency-review gate.
  • Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
P6 · Release Hygiene5.0 / 10Adequate✓ Tool-verified

Readiness · Readiness — Whether releases are traceable — a maintained changelog and explicit version stamping.

Method: Filesystem scan: changelog file presence and version tags in csproj or git tags. Exhaustive, deterministic.

  • No CHANGELOG/HISTORY/RELEASES file — what shipped when isn't easy to reconstruct for support or audit. (Versioning/tagging makes releases traceable, but a changelog records the what.)

What to do

  • Keep a changelog (e.g. Keep-a-Changelog) recording what shipped in each release.
PF3 · Async & latency hygiene10.0 / 10Exemplary✓ Tool-verified

Readiness · Performance — Whether asynchronous code stays responsive — it avoids sync-over-async blocking (a .NET .Wait()/.GetAwaiter().GetResult(), a time.sleep or blocking HTTP call inside a Python coroutine, a *Sync call inside an async JavaScript function, block_on inside a Rust async fn, runBlocking inside a Kotlin suspend function, block() inside a Reactor publisher) that stalls a thread or event loop and risks deadlock, and, where the code is a reusable library on .NET, awaits with ConfigureAwait(false) so it never captures and stalls its caller's context.

Method: Production-source scan: sync-over-async blocking counted everywhere — .Wait()/.GetAwaiter().GetResult() in .NET; off .NET, read from each language's code model, a blocking call inside an async function (Python, TS/JS, Rust, Kotlin, Swift, Dart) or inside a Java method returning a Reactor Mono/Flux or a Scala method returning a Future or effect — and, for a .NET library with ≥5 awaits, the share of awaits using ConfigureAwait(false). Deterministic, syntax/text detection.

X1 · Async correctness1.1 / 10Critical✓ Tool-verified

Other · Code Health — Whether the code avoids sync-over-async (deadlock-prone blocking on tasks) and async void.

Method: Roslyn syntax scan: async methods scanned for .Wait()/.GetAwaiter().GetResult() and async-void outside event handlers. Deterministic, hard fact per invocation.

  • `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained. (×39) — REDACTED:46, REDACTED:119, TestClients/MtApi5TestClient/ViewModel.cs:542, …
  • `WaitHandle.WaitOne` parks the thread until another thread signals it — inside a method that is already `async`, the wait should be awaitable (a `TaskCompletionSource`, `SemaphoreSlim.WaitAsync`, or `WaitHandle` bridged with `Task.Factory.FromAsync`). — REDACTED:132

What to do

  • async void method: Disconnect
X12 · Unreachable branch10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether any branch is dead by construction — a switch arm whose label can never equal a case-normalised subject, or an `else if` whose predicate the arm above has already swallowed.

Method: Roslyn syntax + semantics: switch labels compared against the subject's own case normaliser, and if/else-if chains checked for a literal an earlier arm's containment test already swallows. Deterministic, provable per finding. Advisory.

X13 · Undrained process stream10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a child process that has BOTH standard streams redirected drains both — reading one to the end while the other is never read deadlocks once the child fills the unread pipe.

Method: Roslyn syntax + semantics: ProcessStartInfo launches with both streams redirected, checked for a drain of each stream across the enclosing type. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same rule: a `spawn` imported from `child_process` whose stdout and stderr are both pipes (no options, no `stdio`, or `stdio` of `'pipe'`), bound to a local that never leaves its scope, where exactly one of the two streams is read, the other never, and the child’s `close`/`exit` (or the read stream’s end) is awaited; a shell redirect in the call’s arguments or a `kill` of the child suppresses it. The same rule reads Python’s `subprocess.Popen`, Dart’s `Process.start`, Ruby’s `Open3.popen3`, and Scala’s JDK process starts (`new ProcessBuilder(…).start()` with no `redirectErrorStream`/`redirectError`/`redirectOutput`/`inheritIO`, `Runtime.getRuntime.exec`) where one of `getInputStream`/`getErrorStream` is read and the other never while `waitFor()` is called or the read stream is read to its end. Deterministic, provable per finding. Advisory.

X16 · Unfloored truncation loop10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a loop that shortens a string until it fits a length budget has a floor — one with none grinds the value down to the empty string, or past it into a negative-length `Substring`.

Method: Roslyn syntax + semantics: while/do loops whose body's only effect on a string is to drop its last character, checked for whether anything — a direct comparison on the length, a body guard, a break — bounds that length below. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same rule: a `while`/`do` loop whose body’s one assignment to a value is `x = x.slice(0, -1)` or `x = x.slice|substring|substr(0, x.length - 1)`, driven by a condition that reads `x.length` only as a term of a larger expression — never compared directly, never tested for truthiness, and with no other read of `x` — and whose body has no `break`, `return`, `throw` or `if` naming `x`. Deterministic, provable per finding. Advisory.

X18 · Disposal-pattern correctness10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a type's disposal matches what it OWNS — releasing what it created, leaving alone what it was handed, and not declaring a finalizer for state that has nothing unmanaged to finalize.

Method: Roslyn syntax + semantics: every assignment to a disposable field is read to decide whether the type CREATED the value or was handed it, and the type's disposal is checked against that answer — an injected interface it disposes, a value it constructed and never releases, a finalizer on a type holding nothing unmanaged, and a disposable local whose every reference is a plain member read. A value handed to a container that disposes its contents (a parent control's `Controls` collection, a component `IContainer`) is released by that container and is not reported; generated code is out of population. On a repository with no .NET source the same ownership questions are read in JavaScript/TypeScript off the engine’s own token stream (test, vendored, generated and minified paths not): a class declaring `dispose()`, `[Symbol.dispose]()` or `[Symbol.asyncDispose]()` that disposes a field it was handed through a constructor parameter typed as a repository interface or resolved by a dependency-injection container; that assigns a field only ever from `new X(…)` of a disposable class and neither releases it anywhere in the class nor names it in its disposal member or a method that member calls, nor hands it to anything else; and a `const`/`let` local built from literals only whose every reference opens a statement operating on a non-release member of it. A class is disposable when every repository declaration of its name declares or inherits a disposal member, or when it is a documented library disposable (`vscode` EventEmitter, CancellationTokenSource and Disposable; three.js geometries, materials, textures, render targets, renderers, controls and composers). The finalizer arm has no JavaScript counterpart: a class cannot declare one. Dart is read for the owned-and-never-released arm: a Flutter `State` (or a class declaring `dispose()`/`close()`) whose library-private field is written only with direct creations of a framework controller, `FocusNode`, `StreamController` or periodic `Timer` (or a `.listen(…)` into a field declared `StreamSubscription`), which nothing in the class or its library releases (`dispose`/`close`/`cancel`) and which is never handed on except as a named argument. Ruby is read for the owned-and-never-released arm and the abandoned-local arm: a class declaring an instance `close`, `dispose`, `shutdown`, `stop`, `disconnect` or `terminate` whose instance variable is written only with a blockless core descriptor creation (`File.open`/`new`, `Tempfile`, `Dir.open`, `IO.popen`, the `socket` and `openssl` socket classes) that no method of the class closes and that is never handed on (passed, returned, stored, exposed by `attr_reader`, delegated) — a class whose superclass or mixin lies outside the repository is not judged — and a blockless creation read through and dropped (`File.open(path).read`) or held in a local that is never closed, returned, passed or stored (a `&:read` block-pass, an `autoclose: false` borrow and a `fileno` hand-over are not abandonment). PHP is read for the same two arms: a class (not a trait, and not one using a trait) declaring an instance `close`, `dispose`, `shutdown`, `stop`, `disconnect` or `terminate` whose `private` property (or a `final` class's `protected` one) is written only with a direct core `fopen`, `tmpfile`, `popen`, `proc_open`, `fsockopen`, `stream_socket_client`/`server` or `opendir` that nothing in the class closes (`fclose`, `pclose`, `closedir`, `unset`, a reset to `null`) and that is never handed on, and a handle held in a function's local, or read through as the argument of a reader, that is never closed, returned, passed, captured or stored; a `php://` stream, `curl_init`, `SplFileObject`, `PDO` and a function the repository declares under the core name are not read. Deterministic, provable per finding. Advisory.

X2 · Cancellation propagation4.0 / 10Weak✓ Tool-verified

Other · Code Health — Whether async methods accept a CancellationToken so work can be cancelled (adoption curve).

Method: Roslyn scan: every async method (excluding framework-fixed overrides/Blazor handlers) checked for CancellationToken parameter presence. Deterministic, adoption percentage. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same question: every named async function that itself makes a request an AbortSignal can cancel (global `fetch`, axios and its file-local instances, ky, ofetch) counts, and it is compliant when its parameters or body name a signal or it hands one of its own parameters to the request as options; signatures a framework fixes (JSX event handlers, route and lifecycle exports, request-first handlers, `override`, `'use server'` modules, TanStack `mutationFn`) are exempt unless they take a signal. Deterministic, adoption percentage.

  • Only 0/105 async methods accept a CancellationToken, so in-flight work can't be stopped early when the caller gives up — whatever ends it in your host (shutdown signal, timeout, abandoned request, user cancel). Thread a token through the call chain and honour it at each await and loop; where a method genuinely cannot be interrupted, omitting it is a deliberate choice — judge against your hosting model.
  • No CancellationToken parameter — this work can't be stopped early once started. (×39) — REDACTED:26, REDACTED:46, REDACTED:119, …

What to do

  • Thread a CancellationToken through async methods so work stops promptly on cancellation.
X20 · Mistyped argument guard5.2 / 10Adequate✓ Tool-verified

Other · Code Health — Whether an argument guard throws the exception its own condition describes — a guard that rejects a value for being EMPTY and reports it as `ArgumentNullException` tells the caller a parameter was null when it provably was not.

Method: Roslyn syntax: `throw new ArgumentNullException(nameof(p))` statements (or a repository exception type deriving from it) controlled by an `if` — directly or through the `using`, `lock` or `try` that wraps the throw — whose condition is read for a test that is true of a NON-null `p` — an emptiness test that dereferences it (`p.Count == 0`, `!p.Any()`) or a BCL predicate documented true of the empty value (`string.IsNullOrEmpty(p)`); in the `else` branch, for a conjunct of the admitting condition that is FALSE of a non-null `p`. Range guards are read for bounds that leave nothing and for a `p > C.Count` bound whose index then reaches `C[p]`, `C.RemoveAt(p)` or a method of the same type that indexes with it. Deterministic, provable per finding. Advisory.

  • The guard on line 103 rejects `host` and line 104 reports that rejection as `ArgumentNullException` — but the condition's own test `string.IsNullOrEmpty(host)` is true of a value that is NOT null: it is satisfied by an EMPTY `host`, and on that path `host` was already proven non-null by the very expression that decided it (`||` short-circuits, so the null test to its left had to be false to get here). So a caller who passes a valid empty argument is told a parameter was null. That is not a wording problem: the exception type is the contract. A caller catching `ArgumentNullException` to handle a real null swallows this case with it, and whoever reads the stack trace later is told a failure the source disproves. .NET separates the two on purpose — `ArgumentNullException.ThrowIfNull` and `ArgumentException.ThrowIfNullOrEmpty` are two helpers because they are two failures. Throw `ArgumentException` (or `ArgumentOutOfRangeException` for a bound) for what the condition actually tests, or split the guard and throw each on its own condition. — MtApi5/MtApi5Client.cs:104
  • The guard on line 26 rejects `host` and line 27 reports that rejection as `ArgumentNullException` — but the condition's own test `string.IsNullOrEmpty(host)` is true of a value that is NOT null: it is satisfied by an EMPTY `host`, and on that path `host` was already proven non-null by the very expression that decided it (`||` short-circuits, so the null test to its left had to be false to get here). So a caller who passes a valid empty argument is told a parameter was null. That is not a wording problem: the exception type is the contract. A caller catching `ArgumentNullException` to handle a real null swallows this case with it, and whoever reads the stack trace later is told a failure the source disproves. .NET separates the two on purpose — `ArgumentNullException.ThrowIfNull` and `ArgumentException.ThrowIfNullOrEmpty` are two helpers because they are two failures. Throw `ArgumentException` (or `ArgumentOutOfRangeException` for a bound) for what the condition actually tests, or split the guard and throw each on its own condition. — MTApiService/MtClient.cs:27

What to do

  • Each finding names the throw and the test in its own condition that is true of a NON-null value. Confirm from the two, then throw the exception that describes what was actually wrong: `ArgumentException` for a value that arrived empty, or the .NET 8 helpers that spell the whole guard in one line and pick the type for you — `ArgumentException.ThrowIfNullOrEmpty(s)` / `ThrowIfNullOrWhiteSpace(s)` for strings, `ArgumentNullException.ThrowIfNull(x)` followed by `ArgumentOutOfRangeException.ThrowIfZero(x.Count)` for a collection. Splitting the two conditions is usually clearer than picking one exception for both: they are different failures and the caller may want to handle them differently.
X23 · Unguarded diagnostic materialisation10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether the work a diagnostic log line costs is paid only when that line is wanted — C# evaluates a call's arguments BEFORE the call, so a trace/debug message joined or projected out of a collection is built in full on every pass, and then discarded by a sink the shipped configuration leaves switched off.

Method: Roslyn syntax: log calls at a diagnostic level (a `Log`-prefixed method naming Trace/Debug/Verbose, or a bare `Debug`/`Trace`/`Verbose` on a receiver named for a logger), whose argument list is read for a call whose cost scales with a sequence — a LINQ operator, a materialisation, `string.Join`, a serializer — with no enclosing level check or conditional-compilation region. On a repository with no .NET source it reads JavaScript/TypeScript off the engine’s own token stream (test, vendored and minified paths not) with the same rule: a `debug`/`trace`/`verbose` call on a receiver named for a logger, or a `log`-prefixed method naming the level, whose argument calls an array operator (`map`/`filter`/`reduce`/`sort`/…), `Array.from`, `Object.keys/values/entries`, `JSON.stringify`/`util.inspect` over anything but a literal, or an array `join` — outside any arrow or function passed as an argument, which the logger calls only when the level is on — with no enclosing `if`, `&&` or `?:` whose condition names a level, a level string, or the `NODE_ENV`/`__DEV__`/`DEV` build switch. Deterministic, provable per finding. Advisory.

X25 · Inert configuration knob10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a value the caller is invited to supply is the value the type actually uses — a constructor parameter stored in a private field that nothing ever reads while the default it was given is spelled out a second time at the site that should have read it, a keyed lookup that falls back to a different setting than the one its key names while the same type falls back to the matching one for that same key, or a culture-sensitive parse given no format provider by a type that feeds its own settable culture to the same kind of parse elsewhere, or a number an entry point writes to standard output under the host's culture while the same entry point formats with the invariant culture elsewhere. Either way, every caller who supplies a value silently gets something else.

Method: Roslyn syntax: private instance fields of a non-partial type assigned in a constructor from one of its own parameters with a `??` fallback, checked for whether anything in the type body reads the field and whether that same fallback expression is spelled out again outside the constructor; and `??` fallbacks onto a member access from a lookup call carrying exactly one string literal, grouped by that key across the type and checked for a fallback member whose folded name disagrees with the key while a sibling site for the same key agrees with it. On a repository with no .NET source the first two arms read JavaScript/TypeScript off the engine’s own token stream (tests included, bundles and vendored paths not): a `#x`, `private` or `private` parameter-property instance field filled in the constructor from a parameter (or one member of one) through `??`/`||` or a parameter default, never read anywhere in the file by name, whose constructed default is spelled again in the class body; and `lookup("key") ?? s.member` grouped by key per class, or per module outside every class. The culture arm has no JavaScript counterpart: its parses take no locale. Deterministic, provable per finding. Advisory.

X26 · Unsynchronised callback handoff10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a value handed from a callback to the body that waits on it crosses on something built to be crossed — a `Queue<T>`/`List<T>`/`Dictionary<K,V>` written inside an event handler and read back outside it is mutated by two flows at once, and the semaphore or completion source beside it orders how MANY items exist while leaving the collection's own head, tail and backing array unprotected.

Method: Roslyn syntax: method, accessor, local-function and lambda bodies that declare BOTH a non-thread-safe generic collection (`Queue`/`Stack`/`List`/`Dictionary`/`HashSet`/`Sorted*`/`LinkedList`) and a synchronisation primitive (`SemaphoreSlim`/`TaskCompletionSource`/`ManualResetEvent(Slim)`/`AutoResetEvent`/`CountdownEvent`) as locals, then read for a `+=`-registered lambda that raises that primitive while the body outside every lambda waits on it — and, in that scope, a mutating call on the collection inside the lambda paired with a mention of it outside. Any `lock` in the scope abstains it. On a repository with no .NET source the same handoff is read in Java off the engine’s own token stream (test source sets, vendored and demonstration paths not): an `ArrayList`/`LinkedList`/`ArrayDeque`/`PriorityQueue`/`Hash*`/`LinkedHash*`/`Tree*` local and a `CountDownLatch`/`Semaphore`/`CompletableFuture` local, a lambda or anonymous class that raises the primitive and mutates the collection, and a wait outside it; any `synchronized` or `lock()` abstains the body. Because each of those primitives orders what the callback wrote before raising it, only a touch that provably overlaps the callback is convicted: one after the registration and before the next wait, or one in a loop registered-before, waiting on every pass and not declaring the collection. Deterministic, provable per finding. Advisory.

X27 · Collection changed while being enumerated10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a `foreach` leaves the collection it is walking alone — a body that adds to or removes from the very collection the loop is enumerating invalidates the enumerator it is holding, so the next `MoveNext` throws `InvalidOperationException` and the remaining items are never seen.

Method: Roslyn syntax + semantics: `foreach` statements whose body calls a structural mutator (`Add`/`Remove`/`Clear`/`Insert`/…) on the very expression the loop is enumerating. Two arms. ARM A — the source is a concrete fragile BCL collection, or a live `Keys`/`Values` view over one, and the mutator resolves to that same collection's own member; concurrent and immutable collections and arrays are outside the population by construction, since their enumerators survive a structural change. ARM B — the source is an argument-less accessor CALL on a receiver whose body is in source: the accessor must return a stored field VERBATIM and a sibling member must structurally change that same field, both read off the implementations rather than from the members' names. A mutation the loop provably exits immediately after (`break`/`return`/`throw`/`goto`), or one written inside a nested loop or a lambda, is counted and never reported. Deterministic, provable per finding. Advisory.

X29 · Per-element action decided by a fixed element10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether a decision taken once per element is taken ABOUT that element — a test inside a counted loop that reads a fixed subscript of the very collection its guarded statement indexes by the loop variable applies element zero's answer to all of them, so the elements that differ from it are all handled wrongly, and in the same direction.

Method: Roslyn syntax only, no semantic model: every `for` statement declaring exactly ONE loop variable, and every `if` inside its body that is not under a nested loop or a lambda. A site enters the population when the `if`’s condition never mentions the loop variable while the statement it guards indexes some collection by that variable ALONE (`c[i]`; `c[i + 1]` and `c[i, j]` are outside it). A finding additionally needs the AGREEING TWIN at the same-collection grain: the condition must read THAT SAME collection at a subscript that does not move — written into the condition, or reached through a local declared BEFORE the loop, so an alias bound inside the body is not followed. Both collection expressions must be simple identifiers. On a repository with no .NET source the same rule reads JavaScript/TypeScript off the engine’s own token stream (tests included, bundles and vendored paths not): a `for (let|var|const x = …; …; …)` with one declarator and a braced body, an alias followed only when it is declared before the loop in a block that encloses it and never assigned inside the loop. Deterministic, provable per finding. Advisory.

X3 · Exception handling5.3 / 10Adequate✓ Tool-verified

Other · Code Health — Whether exceptions are handled rather than silently swallowed or rethrown with lost stack traces.

Method: Roslyn syntax scan: every catch clause counted; empty catches and bare rethrows flagged. Population is all catch clauses, not estimated. Deterministic, hard fact.

  • An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it. (×3) — MtApi5/MtApi5Client.cs:78, MtApi/Monitors/TradeMonitor.cs:52, MtApi/Monitors/TradeMonitor.cs:56
  • `catch (Exception)` does nothing with the exception it caught — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch. Log it through whatever this codebase already uses to report problems, or let it propagate; if one specific failure genuinely cannot matter, catch exactly that exception type and say why in a comment on the catch. (×2) — MtApi5/MtConverters.cs:25, MtApi5/MtConverters.cs:57

What to do

  • Swallowed exception (empty catch)
X5 · Nullable reference types10.0 / 10Exemplary○ Nothing flagged

Other · Code Health — Whether nullable reference types are enabled and not undermined by heavy `!` suppression.

Method: Roslyn compiler-options scan: NullableContextOptions per project; null-forgiving (!) suppression density per 1k syntax nodes. Deterministic, adoption plus suppression penalty.

Reference — by lens

The score is the rank-weighted fold of these lenses (worst-heaviest), each including its meta-dimensions; a lens with a Critical contributor is capped at Fair (its band reads "gated by …") and is never the strongest area however high its average.

LensScoreRatingImpact
Code Health46.7Weak — gated by D18, X1Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Architecture71.6Adequate — gated by AX2Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Maturity58.5Adequate — gated by M2Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Readiness19.3Critical — gated by D8, P1, P3Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Security29.3Weak — gated by D44, C2Capped at Fair by a Critical contributor — resolve it before relying on this lens.
Performance100.0ExemplaryStrongest area.
Unscored — 3 check(s) recorded observations but carry no score

These checks ran and found something, but they do not carry a score — either by design (an advisory check reports evidence rather than grading it) or because they could not be scored here. They are excluded from the score for that reason, not because there was nothing to see.

  • SC1 Supply-chain hygiene — 6 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
  • X10 Duplicated predicate — 6 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
  • X7 Silent fallback defaults — 1 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 2 control(s) we could not find positive evidence for

These checks grade a working control, and the repository shows no evidence of one. That is deliberately not scored as a zero: a repository cannot show an ops runbook, a database TTL or an infrastructure-side audit log, so absence of evidence here is not evidence the control is missing. It is also not a statement that the check is irrelevant to this codebase — the thing it grades applies; we just could not see it. Excluded from the score either way.

  • P4 Deployment & Rollback — not evidenced — no deploy/rollback/approval signal in the repo; absence of evidence is not evidence of a manual release
  • P5 DR & Backup — not evidenced — repo shows no backup/RTO/RPO controls; absence of evidence is not evidence of a working control
Not included — 59 check(s) not relevant to this codebase

These checks had nothing to measure here (no tests, no git history, the codebase is small, or the architecture style doesn't apply), so they're omitted above rather than scored low.

  • AC1 Text alternatives — No web markup found — accessibility is not applicable to this repository.
  • AC2 Forms & labels — No web markup found — accessibility is not applicable to this repository.
  • AC3 Page structure — No web markup found — accessibility is not applicable to this repository.
  • AC4 Keyboard semantics — No web markup found — accessibility is not applicable to this repository.
  • AC5 ARIA correctness — No web markup found — accessibility is not applicable to this repository.
  • AC6 Visual & motion safety — No web markup found — accessibility is not applicable to this repository.
  • AX1 Captive dependencies — no DI registrations detected
  • AX7 Slice cohesion — not applicable — not a vertical-slice architecture
  • AX8 Test isolation — no test/production split to check
  • AX9 CQS / query purity — no CQRS query handlers detected — query purity is not applicable to this codebase
  • AXB1 Runtime evidence locked — no reproducible boot — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • C1 Data Protection — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
  • C3 Audit Trail — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
  • C4 Data Retention — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
  • C5 Data-Subject Rights — No personal data detected in the analyzed source — no PII-typed entity/column names (Email, FirstName, DateOfBirth, …), no ASP.NET Identity / user-account model, and no stored user credentials. GDPR data-protection controls are therefore N/A here. If this is intentional, record the no-PII posture in an ADR; if the app does process personal data, name those fields conventionally so this dimension activates.
  • D10 Test Quality — No tests were found in the analyzed repository to assess for quality.
  • D11 Test Reliability — Test reliability not measured — no test run produced results
  • D12 Dependency Hygiene — Dependency hygiene not measured
  • D16 Bus Factor — single-maintainer repository — bus factor is not applicable
  • 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.
  • D21 Naming Consistency — Naming consistency does not read Visual Basic yet; not measured.
  • D22 Internal API Consistency — No intentionally-exposed public API to evaluate for consistency.
  • D23 Boundary Type-Coupling — small single-context codebase (17,500 production LoC in the .NET projects) — bounded contexts are not needed at this size No bounded-context organisation was detected either — neither a context-shaped layout, nor 2+ sibling source directories each declaring an aggregate root, nor 2+ sibling projects each declaring an entity of their own or taking another project's integration events. Declaring this codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
  • D25 ADR Conformance — no ADRs to check
  • D31 IaC & Container Security — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.
  • D32 Data Compliance (PII/GDPR) — 11 file(s) were not parsed by semgrep — the PII/GDPR ruleset never ran over them
  • D36 Supply-chain Provenance & Signing — No CI/build pipeline found (.github/.forgejo/.gitea workflows, .circleci, .buildkite, .woodpecker, .teamcity, .gitlab-ci.yml, .travis.yml, bitbucket-pipelines.yml, .drone.yml, .cirrus.yml, .woodpecker.yml, appveyor.yml, azure-pipelines*.yml, .pipelines/, .vsts-ci/, .azuredevops/, Jenkinsfile); there is no build to attest provenance for.
  • D37 Vulnerability-disclosure Policy — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.
  • D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
  • D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
  • D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
  • D7 Architectural Integrity — no checkable ADRs and no dependency cycles — architectural integrity not assessed
  • DM1 Domain Modelling — not scored — this repository shows none of the 3 signals this lens looks for
  • ED1 Event-Driven — not scored — this repository shows none of the 3 signals this lens looks for
  • ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
  • ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
  • M4 Documentation accuracy — Not applicable: the 2 current-state document(s) make no claim of a kind M4 checks.
  • P10 Library API & versioning — Library API & versioning could not be assessed in this run — the check did not complete, so it is not scored. This is a gap in the analyzer, not a finding about this repository.
  • P11 BDD / executable specs — BDD / executable specs could not be assessed in this run — the check did not complete, so it is not scored. This is a gap in the analyzer, not a finding about this repository.
  • P12 CI test-gate honesty — no CI workflow found
  • P7 Outbound HTTP resilience — Outbound HTTP resilience could not be assessed in this run — the check did not complete, so it is not scored. This is a gap in the analyzer, not a finding about this repository.
  • P8 Schema migrations — Schema migrations could not be assessed in this run — the check did not complete, so it is not scored. This is a gap in the analyzer, not a finding about this repository.
  • P9 Domain vs controller coverage — coverage not measured: this check compares the coverage of the analyzer's own test run across the domain and web layers, and that run measured none here — Test coverage (D8) says why
  • PF1 Benchmark discipline — Performance is assessed only for perf-relevant repos — a packaged library, one that ships benchmarks, or one already using allocation-aware APIs. This repo isn't one, so the Performance lens is not applicable and is excluded from the score.
  • PF2 Allocation hygiene — Not scored: this check counted allocation-aware idioms (Span, pools, stackalloc) per line, which describes what kind of code a repository is rather than whether it has an allocation problem, so it was withdrawn. Nothing here is a finding about your code.
  • S1 Web-Security Posture — No web surface detected in the analyzed source — no HTTP API or web-UI project (no controllers/minimal-API endpoints, no Razor/Blazor views) and no web middleware (HTTPS redirection, HSTS, security headers, cookies). Transport security, security headers, secure cookies, CSRF/input-validation and middleware-order controls are therefore N/A here — this is a library/CLI/worker, not a web app. Crypto hygiene was still checked and found nothing to flag. If this codebase becomes web-facing, the dimension reactivates automatically.
  • X14 Bypassable address classification — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X15 Unvalidated length from an untrusted reader — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X17 Uncapped recursion over a caller-supplied document — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X19 Unrestored process-global state — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X21 Side-effecting pattern guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X22 Contradicted release guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X24 Document value interpolated into markup unescaped — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X28 Index access outside its own emptiness guard — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X30 Support guard that admits what it rejects — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X32 Type resolved by simple name across every loaded assembly — not applicable — the code was read and holds no site of this kind, so there is nothing for this check to judge
  • X4 Structured logging — This check asks whether log calls keep a message's values apart from its text, which needs a logger that can carry them as fields. This repository's C# was read, and every log call in it goes through a logger that takes one finished message — its own wrapper, log4net, Console or Debug — so an interpolated message there loses nothing the API could have kept. Calls through Microsoft.Extensions.Logging, Serilog, NLog or ZLogger, or any logger with a message-template overload, would be judged.
  • X6 Hand-rolled structured-format parsing — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
  • X9 Subsumed condition operand — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.

Appendix A — Findings (grouped)

The findings behind the scores, grouped by severity, then by dimension and kind. The high-severity issues are enumerated in full below; items per group are capped at 25 with any overflow stated explicitly per group, never silently truncated. The complete machine-readable list of every finding (all severities) is the companion findings.md in this report's bundle.

Critical — 8 finding(s)
D17 · Explicit Debt · EmptyCatchBlock · ×3
  • EmptyCatchBlock MtApi/Monitors/TradeMonitor.cs:52 — empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
  • EmptyCatchBlock MtApi/Monitors/TradeMonitor.cs:56 — empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
  • EmptyCatchBlock MtApi5/MtApi5Client.cs:78 — empty catch block — the error is discarded with nothing recorded, so a failure here leaves no trace anywhere. Record it through whatever this codebase already uses to report problems, or let it propagate. Where swallowing one specific failure really is correct — as it often is on a teardown/dispose path where throwing would mask the original failure — catch exactly that exception type and write down WHY in a comment on the catch. Both are needed: a comment on a catch-all still swallows every failure nobody anticipated, and a note that only restates the swallow ("ignored", "do nothing") is read as no explanation at all.
AX3 · Project dependency cycles · Namespace dependency cycle · ×1
  • Namespace dependency cycle MtApi5/MqlTick.cs:1 — The namespaces MtApi5 ↔ MtApi5.MtProtocol depend on each other. The lightest dependency in the cycle is MtApi5 → MtApi5.MtProtocol (MtApi5.MqlTick → MtApi5.MtProtocol.MtTick, 3 type pair(s)); cut that one first, e.g. by moving the shared type to a namespace both can use or inverting it behind an interface.
D13 · Secret Scanning · Leaked secret · ×1
  • REDACTED
D17 · Explicit Debt · WriteOnlyPrivateField · ×1
  • WriteOnlyPrivateField TestClients/TestServer/MetaTrader.cs:214 — private List<string> OpTypes — assigned 1 time(s), read never — this field is written and never read anywhere its type can be reached from, so the state it keeps answers no question: every assignment to it computes a value that nothing observes, on every instance, for the lifetime of each one. It reads as a flag the code branches on, and nothing branches on it. Delete the field and its assignments — or, if the value was MEANT to be consulted, the missing read is the defect this row is pointing at, and the branch that should have depended on it is not there.
D28 · Secrets (history) · High secret · ×1
  • REDACTED
D8 · Code Coverage · No automated tests · ×1
  • No automated tests — No automated tests — no test code was found in this repository. Untested code is the largest single risk to changing it safely. Start with the code you change most often: add a suite in a framework a runner can collect (xUnit, NUnit or MSTest), and run it in CI so the gap cannot reopen.
Serious — 221 finding(s)
X1 · Async correctness · async void method · ×39
  • async void method: Disconnect REDACTED:46 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: DoWrite REDACTED:119 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteOrderSend TestClients/MtApi5TestClient/ViewModel.cs:542 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteOrderCheck TestClients/MtApi5TestClient/ViewModel.cs:557 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecutePositionGetTicket TestClients/MtApi5TestClient/ViewModel.cs:571 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteHistoryOrderGetInteger TestClients/MtApi5TestClient/ViewModel.cs:584 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteHistoryDealGetDouble TestClients/MtApi5TestClient/ViewModel.cs:594 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteHistoryDealGetInteger TestClients/MtApi5TestClient/ViewModel.cs:604 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteHistoryDealGetString TestClients/MtApi5TestClient/ViewModel.cs:614 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteHistoryDealMethods TestClients/MtApi5TestClient/ViewModel.cs:624 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteAccountInfoDouble TestClients/MtApi5TestClient/ViewModel.cs:643 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteAccountInfoInteger TestClients/MtApi5TestClient/ViewModel.cs:651 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteAccountInfoString TestClients/MtApi5TestClient/ViewModel.cs:659 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteTerminalInfoDouble TestClients/MtApi5TestClient/ViewModel.cs:667 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteTerminalInfoInteger TestClients/MtApi5TestClient/ViewModel.cs:675 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteTerminalInfoString TestClients/MtApi5TestClient/ViewModel.cs:683 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteCopyTime TestClients/MtApi5TestClient/ViewModel.cs:692 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteCopyOpen TestClients/MtApi5TestClient/ViewModel.cs:722 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteCopyHigh TestClients/MtApi5TestClient/ViewModel.cs:752 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteCopyLow TestClients/MtApi5TestClient/ViewModel.cs:782 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteCopyClose TestClients/MtApi5TestClient/ViewModel.cs:812 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteIndicatorCreate TestClients/MtApi5TestClient/ViewModel.cs:843 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteIndicatorRelease TestClients/MtApi5TestClient/ViewModel.cs:877 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteICustom TestClients/MtApi5TestClient/ViewModel.cs:885 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • async void method: ExecuteIBullsPowerCommand TestClients/MtApi5TestClient/ViewModel.cs:895 — `async void` can't be awaited and its exceptions crash the process instead of propagating. Return `Task` — or, where the delegate contract requires void (timer/event/callback registrations), make this a thin void shim that awaits a Task-returning inner method inside try/catch so exceptions are contained.
  • + 14 more in this group — see findings.md.
X2 · Cancellation propagation · Async method without CancellationToken · ×39
  • Async method without CancellationToken: Connect REDACTED:26 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: Disconnect REDACTED:46 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: DoWrite REDACTED:119 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: DoReceive REDACTED:150 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: Connect MtApi5/MtApi5Client.cs:101 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteOrderSend TestClients/MtApi5TestClient/ViewModel.cs:542 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteOrderCheck TestClients/MtApi5TestClient/ViewModel.cs:557 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecutePositionGetTicket TestClients/MtApi5TestClient/ViewModel.cs:571 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteHistoryOrderGetInteger TestClients/MtApi5TestClient/ViewModel.cs:584 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteHistoryDealGetDouble TestClients/MtApi5TestClient/ViewModel.cs:594 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteHistoryDealGetInteger TestClients/MtApi5TestClient/ViewModel.cs:604 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteHistoryDealGetString TestClients/MtApi5TestClient/ViewModel.cs:614 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteHistoryDealMethods TestClients/MtApi5TestClient/ViewModel.cs:624 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteAccountInfoDouble TestClients/MtApi5TestClient/ViewModel.cs:643 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteAccountInfoInteger TestClients/MtApi5TestClient/ViewModel.cs:651 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteAccountInfoString TestClients/MtApi5TestClient/ViewModel.cs:659 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteTerminalInfoDouble TestClients/MtApi5TestClient/ViewModel.cs:667 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteTerminalInfoInteger TestClients/MtApi5TestClient/ViewModel.cs:675 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteTerminalInfoString TestClients/MtApi5TestClient/ViewModel.cs:683 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteCopyTime TestClients/MtApi5TestClient/ViewModel.cs:692 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteCopyOpen TestClients/MtApi5TestClient/ViewModel.cs:722 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteCopyHigh TestClients/MtApi5TestClient/ViewModel.cs:752 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteCopyLow TestClients/MtApi5TestClient/ViewModel.cs:782 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteCopyClose TestClients/MtApi5TestClient/ViewModel.cs:812 — No CancellationToken parameter — this work can't be stopped early once started.
  • Async method without CancellationToken: ExecuteIndicatorCreate TestClients/MtApi5TestClient/ViewModel.cs:843 — No CancellationToken parameter — this work can't be stopped early once started.
  • + 14 more in this group — see findings.md.
D17 · Explicit Debt · ObsoleteWithCallers · ×16
  • ObsoleteWithCallers MtApi/MtApiClient.cs:138 — [Obsolete] OrderClosePrice
  • ObsoleteWithCallers MtApi/MtApiClient.cs:151 — [Obsolete] OrderCloseTime
  • ObsoleteWithCallers MtApi/MtApiClient.cs:158 — [Obsolete] OrderComment
  • ObsoleteWithCallers MtApi/MtApiClient.cs:164 — [Obsolete] OrderCommission
  • ObsoleteWithCallers MtApi/MtApiClient.cs:170 — [Obsolete] OrderExpiration
  • ObsoleteWithCallers MtApi/MtApiClient.cs:177 — [Obsolete] OrderLots
  • ObsoleteWithCallers MtApi/MtApiClient.cs:183 — [Obsolete] OrderMagicNumber
  • ObsoleteWithCallers MtApi/MtApiClient.cs:189 — [Obsolete] OrderOpenPrice
  • ObsoleteWithCallers MtApi/MtApiClient.cs:202 — [Obsolete] OrderOpenTime
  • ObsoleteWithCallers MtApi/MtApiClient.cs:209 — [Obsolete] OrderProfit
  • ObsoleteWithCallers MtApi/MtApiClient.cs:215 — [Obsolete] OrderStopLoss
  • ObsoleteWithCallers MtApi/MtApiClient.cs:221 — [Obsolete] OrderSymbol
  • ObsoleteWithCallers MtApi/MtApiClient.cs:227 — [Obsolete] OrderTakeProfit
  • ObsoleteWithCallers MtApi/MtApiClient.cs:233 — [Obsolete] OrderTicket
  • ObsoleteWithCallers MtApi/MtApiClient.cs:239 — [Obsolete] OrderType
  • ObsoleteWithCallers MtApi/MtApiClient.cs:245 — [Obsolete] OrderSwap
D17 · Explicit Debt · TodoComment · ×10
  • TodoComment MtApi/Monitors/TradeMonitor.cs:54 — //TODO: write error to log — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi/Monitors/TradeMonitor.cs:58 — //TODO: write error to log — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi5/MtProtocol/Mt5CommandType.cs:229 — //TODO — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi5/MtProtocol/Mt5CommandType.cs:230 — //TODO — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi5/MtProtocol/Mt5CommandType.cs:231 — //TODO — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi5/MtProtocol/Mt5CommandType.cs:232 — //TODO — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi5/MtProtocol/Mt5CommandType.cs:233 — //TODO — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi5/MtProtocol/Mt5CommandType.cs:234 — //TODO — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi5/MtProtocol/Mt5CommandType.cs:237 — //TODO — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • TodoComment MtApi5/MtProtocol/Mt5CommandType.cs:238 — //TODO — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
D17 · Explicit Debt · CommentedOutCode · ×10
  • CommentedOutCode MtApiSetupActions/CustomAction.cs:37 — 3 consecutive commented-code lines
  • CommentedOutCode MtApiSetupActions/CustomAction.cs:41 — 3 consecutive commented-code lines
  • CommentedOutCode MtApiSetupActions/CustomAction.cs:49 — 3 consecutive commented-code lines
  • CommentedOutCode TestClients/TestServer/MtQuoteExpert.cs.cs:195 — 3 consecutive commented-code lines
  • CommentedOutCode TestClients/TestServer/MtQuoteExpert.cs.cs:378 — 3 consecutive commented-code lines
  • CommentedOutCode TestClients/TestApiClientUI/Form1.cs:573 — 7 consecutive commented-code lines
  • CommentedOutCode TestClients/TestServer/MtQuoteExpert.cs.cs:199 — 5 consecutive commented-code lines
  • CommentedOutCode TestClients/TestServer/MtQuoteExpert.cs.cs:231 — 5 consecutive commented-code lines
  • CommentedOutCode TestClients/TestServer/MtQuoteExpert.cs.cs:273 — 5 consecutive commented-code lines
  • CommentedOutCode TestClients/TestServer/MtQuoteExpert.cs.cs:205 — 6 consecutive commented-code lines
SC1 · Supply-chain hygiene · NuGet dependencies are not locked · ×6
  • NuGet dependencies are not locked REDACTED:3 — REDACTED declares NuGet packages that no committed packages.lock.json resolves and no central package management pins — restores aren't reproducible or pinned (SSDF PW.4.4). Enable <RestorePackagesWithLockFile>true</RestorePackagesWithLockFile> (commit the lockfile) or adopt Directory.Packages.props. Advisory — never scored.
  • NuGet dependencies are not locked MtApi/MtApi.csproj:11 — MtApi/MtApi.csproj declares NuGet packages that no committed packages.lock.json resolves and no central package management pins — restores aren't reproducible or pinned (SSDF PW.4.4). Enable <RestorePackagesWithLockFile>true</RestorePackagesWithLockFile> (commit the lockfile) or adopt Directory.Packages.props. Advisory — never scored.
  • NuGet dependencies are not locked MtApi/packages.config:3 — MtApi/packages.config declares NuGet packages that no committed packages.lock.json resolves and no central package management pins — restores aren't reproducible or pinned (SSDF PW.4.4). Enable <RestorePackagesWithLockFile>true</RestorePackagesWithLockFile> (commit the lockfile) or adopt Directory.Packages.props. Advisory — never scored.
  • NuGet dependencies are not locked MtApi5/MtApi5.csproj:11 — MtApi5/MtApi5.csproj declares NuGet packages that no committed packages.lock.json resolves and no central package management pins — restores aren't reproducible or pinned (SSDF PW.4.4). Enable <RestorePackagesWithLockFile>true</RestorePackagesWithLockFile> (commit the lockfile) or adopt Directory.Packages.props. Advisory — never scored.
  • NuGet dependencies are not locked MtApi5/packages.config:3 — MtApi5/packages.config declares NuGet packages that no committed packages.lock.json resolves and no central package management pins — restores aren't reproducible or pinned (SSDF PW.4.4). Enable <RestorePackagesWithLockFile>true</RestorePackagesWithLockFile> (commit the lockfile) or adopt Directory.Packages.props. Advisory — never scored.
  • NuGet dependencies are not locked MtApiSetupActions/MtApiSetupActions.csproj:10 — MtApiSetupActions/MtApiSetupActions.csproj declares NuGet packages that no committed packages.lock.json resolves and no central package management pins — restores aren't reproducible or pinned (SSDF PW.4.4). Enable <RestorePackagesWithLockFile>true</RestorePackagesWithLockFile> (commit the lockfile) or adopt Directory.Packages.props. Advisory — never scored.
D17 · Explicit Debt · FixmeComment · ×5
  • FixmeComment MtApi5/Mt5Enums.cs:247 — //FIXME: Undocumented! — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment MtApi5/Mt5Enums.cs:248 — //FIXME: Undocumented! — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment MtApi5/Mt5Enums.cs:249 — //FIXME: Undocumented! — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment MtApi5/Mt5Enums.cs:250 — //FIXME: Undocumented! — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
  • FixmeComment MtApi5/Mt5Enums.cs:251 — //FIXME: Undocumented! — source code is not a task system: move the work to your tracker and leave a reference instead (e.g. `// REF: #123`), so the task is planned where tasks live and the ticket links back to the code.
D3 · God Classes · FileTooLong · ×5
  • FileTooLong: MtApi/MtApiClient.cs MtApi/MtApiClient.cs — FileTooLong — 1400 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 900 over it, 2.80× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: MtApi5/MtApi5Client.cs MtApi5/MtApi5Client.cs — FileTooLong — 1247 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 747 over it, 2.49× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: MtApi5TestClient/ViewModel.cs TestClients/MtApi5TestClient/ViewModel.cs — FileTooLong — 1115 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 615 over it, 2.23× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: TestApiClientUI/Form1.cs TestClients/TestApiClientUI/Form1.cs — FileTooLong — 805 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 305 over it, 1.61× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
  • FileTooLong: MtApi5/Mt5Enums.cs MtApi5/Mt5Enums.cs — FileTooLong — 691 significant lines (blank, comment-only and punctuation-only lines excluded). The bar is 500 significant lines; this is 191 over it, 1.38× the bar. To reduce it, split the file along the responsibilities already in it: move each cohesive group of declarations into its own sibling file in the same module or package, so no one file has to be read whole to change one of them.
GD1 · Unfinished & placeholder code · Unfinished stub · ×5
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:66 — A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:88 — A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:108 — A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:128 — A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:156 — A shipped member still throws NotImplementedException — generated scaffolding that was never completed. Implement it or remove the dead surface.
IC1 · Incompleteness & stubs · Unfinished stub · ×5
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:66 — `GetMessageBody` is a shipped member whose whole body throws NotImplementedException — scaffolding that was never completed. Implement it or remove the dead surface.
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:88 — `GetMessageBody` is a shipped member whose whole body throws NotImplementedException — scaffolding that was never completed. Implement it or remove the dead surface.
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:108 — `GetMessageBody` is a shipped member whose whole body throws NotImplementedException — scaffolding that was never completed. Implement it or remove the dead surface.
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:128 — `GetMessageBody` is a shipped member whose whole body throws NotImplementedException — scaffolding that was never completed. Implement it or remove the dead surface.
  • Unfinished stub — throws NotImplementedException MtClient/MtMessage.cs:156 — `GetMessageBody` is a shipped member whose whole body throws NotImplementedException — scaffolding that was never completed. Implement it or remove the dead surface.
D3 · God Classes · TooManyMethods · ×4
  • TooManyMethods: MtApiClient MtApi/MtApiClient.cs — TooManyMethods — 1371 significant lines (blank, comment-only and punctuation-only lines excluded), 291 methods. The bar is 30 methods; this is 261 over it, 9.70× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: MtApi5Client MtApi5/MtApi5Client.cs — TooManyMethods — 1225 significant lines (blank, comment-only and punctuation-only lines excluded), 242 methods. The bar is 30 methods; this is 212 over it, 8.07× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: ViewModel TestClients/MtApi5TestClient/ViewModel.cs — TooManyMethods — 1094 significant lines (blank, comment-only and punctuation-only lines excluded), 128 methods. The bar is 30 methods; this is 98 over it, 4.27× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
  • TooManyMethods: Form1 TestClients/TestApiClientUI/Form1.cs — TooManyMethods — 800 significant lines (blank, comment-only and punctuation-only lines excluded), 127 methods. The bar is 30 methods; this is 97 over it, 4.23× the bar. To reduce it, group the members that share the same data into a smaller type of their own and delegate to it, so no single type carries every responsibility.
D4 · Code Duplication · Edited copy of a member (6 corresponding lines) · ×3
  • Edited copy of a member (6 corresponding lines) MtApi5/MtApi5Client.cs:3553 — MtApi5/MtApi5Client.cs:3553-3558 | MtApi/MtApiClient.cs:3242-3247 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) MtApi5/MtApi5Client.cs:3512 — MtApi5/MtApi5Client.cs:3512-3521 | MtApi/MtApiClient.cs:3225-3230 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (6 corresponding lines) MtApi5/MtApi5Client.cs:2388 — MtApi5/MtApi5Client.cs:2388-2393 | MtApi/MtApiClient.cs:2554-2564 — These two members are one piece of code written twice and then edited apart: 6 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (12 lines × 2) · ×3
  • Duplicated block (12 lines × 2) MTApiService/MtRegistryManager.cs:174 — MTApiService/MtRegistryManager.cs:174-185 | MTApiService/MtRegistryManager.cs:222-233 — 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 `MTApiService/MtRegistryManager.cs:174` 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) MtApi5/MtApi5Client.cs:1663 — MtApi5/MtApi5Client.cs:1663-1674 | MtApi5/MtApi5Client.cs:1691-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 `MtApi5/MtApi5Client.cs:1663` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The matched lines also transfer control out of the body holding them, which cannot survive a move into a called unit unchanged: have the extracted unit return that decision and let each site act on it.
  • Duplicated block (12 lines × 2) MtApi/MtApiClient.cs:3251 — MtApi/MtApiClient.cs:3251-3262 | MtApi5/MtApi5Client.cs:3420-3431 — 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 `MtApi/MtApiClient.cs:3251` 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.
D44 · Platform End-of-Life · End-of-life runtime · ×3
  • End-of-life runtime: .NET Framework net40 MTApiService/MTApiService.csproj:14 — MTApiService/MTApiService.csproj declares .NET Framework net40 as this project's target framework version, and .NET Framework 4.0, support ended 2016-01-12. An unsupported runtime receives no security patches, so every vulnerability disclosed in it since 2016-01-12 is present and unfixable without moving off it. This is a migration rather than an upgrade: there is no newer release of a runtime that has ended.
  • End-of-life runtime: .NET Framework net40 TestClients/TestServer/TestServer.csproj:13 — TestClients/TestServer/TestServer.csproj declares .NET Framework net40 as this project's target framework version, and .NET Framework 4.0, support ended 2016-01-12. An unsupported runtime receives no security patches, so every vulnerability disclosed in it since 2016-01-12 is present and unfixable without moving off it. This is a migration rather than an upgrade: there is no newer release of a runtime that has ended.
  • End-of-life runtime: .NET Framework net45 TestClients/TestMtApi/TestMtApi/TestMtApi.vbproj:16 — TestClients/TestMtApi/TestMtApi/TestMtApi.vbproj declares .NET Framework net45 as this project's target framework version, and .NET Framework 4.5, support ended 2016-01-12. An unsupported runtime receives no security patches, so every vulnerability disclosed in it since 2016-01-12 is present and unfixable without moving off it. This is a migration rather than an upgrade: there is no newer release of a runtime that has ended.
X3 · Exception handling · Swallowed exception (empty catch) · ×3
  • Swallowed exception (empty catch) MtApi5/MtApi5Client.cs:78 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) MtApi/Monitors/TradeMonitor.cs:52 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
  • Swallowed exception (empty catch) MtApi/Monitors/TradeMonitor.cs:56 — An empty catch block silently discards the error — failures vanish with no log and no rethrow. Log it, handle it, or don't catch it.
AX2 · Stateful singletons · Process-global static state · ×2
  • Process-global static state: ListBoxBehavior TestClients/MtApi5TestClient/ListBoxBehavior.cs:10 — `ListBoxBehavior` keeps mutable `static` state — one slot for the whole process, shared by every thread that reaches the type however its instances are created — and mutates it outside any lock (Associations; e.g. `Associations` at line 63). Concurrent callers lose updates, and a collection that is not built for concurrent writers can corrupt.
  • Process-global static state: MtQuoteExpert TestClients/TestServer/MtQuoteExpert.cs.cs:10 — `MtQuoteExpert` keeps mutable `static` state — one slot for the whole process, shared by every thread that reaches the type however its instances are created — and mutates it outside any lock (IDcount; e.g. `IDcount` at line 91). Concurrent callers lose updates, and a collection that is not built for concurrent writers can corrupt.
D3 · God Classes · MethodTooLong · ×2
  • MethodTooLong: MtQuoteExpert.runController TestClients/TestServer/MtQuoteExpert.cs.cs:143 — MethodTooLong — runController runs 131 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 31 over it, 1.31× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
  • MethodTooLong: ViewModel.InitCommands TestClients/MtApi5TestClient/ViewModel.cs:391 — MethodTooLong — InitCommands runs 106 significant lines (blank, comment-only and punctuation-only lines excluded) in one body. The bar is 100 significant lines; this is 6 over it, 1.06× the bar. This is length, not branching: a long straight-line body scores low on complexity and is still read whole to change any part of it, so the complexity numbers beside this row neither confirm nor excuse it. To reduce it, extract each cohesive step of the body — the runs of statements that work on the same values and would earn the same name — into its own named unit, and have this one call them in order.
D4 · Code Duplication · Edited copy of a member (16 corresponding lines) · ×2
  • Edited copy of a member (16 corresponding lines) MtApi5/MtApi5Client.cs:3446 — MtApi5/MtApi5Client.cs:3446-3461 | MtApi/MtApiClient.cs:3281-3296 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (16 corresponding lines) MtApi5/MtApi5Client.cs:3524 — MtApi5/MtApi5Client.cs:3524-3542 | MtApi/MtApiClient.cs:3207-3222 — These two members are one piece of code written twice and then edited apart: 16 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (17 corresponding lines) · ×2
  • Edited copy of a member (17 corresponding lines) MtApi5/MtApi5Client.cs:3464 — MtApi5/MtApi5Client.cs:3464-3483 | MtApi/MtApiClient.cs:3299-3315 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (17 corresponding lines) TestClients/TestApiClientUI/Form1.cs:663 — TestClients/TestApiClientUI/Form1.cs:663-682 | TestClients/TestApiClientUI/Form1.cs:685-701 — These two members are one piece of code written twice and then edited apart: 17 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (4 corresponding lines) · ×2
  • Edited copy of a member (4 corresponding lines) MtApi5/MtApi5Client.cs:70 — MtApi5/MtApi5Client.cs:70-82 | MtApi/MtApiClient.cs:56-59 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
  • Edited copy of a member (4 corresponding lines) MtApi5/MtApi5Client.cs:226 — MtApi5/MtApi5Client.cs:226-229 | MtApi/MtApiClient.cs:507-510 — These two members are one piece of code written twice and then edited apart: 4 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (18 lines × 2) · ×2
  • Duplicated block (18 lines × 2) MtApi/MtApiClient.cs:3047 — MtApi/MtApiClient.cs:3047-3064 | MtApi5/MtApi5Client.cs:116-133 — 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 `MtApi/MtApiClient.cs:3047` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
  • Duplicated block (18 lines × 2) MtApi/EnumObject.cs:22 — MtApi/EnumObject.cs:22-39 | MtApi5/Mt5Enums.cs:726-743 — 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.
D4 · Code Duplication · Duplicated block (6 lines × 2) · ×2
  • Duplicated block (6 lines × 2) MtApi/MtApiClient.cs:350 — MtApi/MtApiClient.cs:350-355 | MtApi/MtApiClient.cs:362-367 — 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 `MtApi/MtApiClient.cs:350` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that. The `return` at the foot of the matched lines is the enclosing body's own terminal exit, not an early one: it moves with them unchanged, and each site calls the extracted unit from the position that `return` occupied — no decision has to be handed back and re-acted on.
  • Duplicated block (6 lines × 2) MtApi/MtApiClient.cs:1890 — MtApi/MtApiClient.cs:1890-1895 | MtApi5/MtApi5Client.cs:1861-1866 — 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 `MtApi/MtApiClient.cs:1890` 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.
D6 · Cohesion (LCOM4) · Low cohesion · ×2
  • Low cohesion: MtApi5Client (LCOM4 6) MtApi5/MtApi5Client.cs:9 — MtApi5Client's methods fall into 6 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 6 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
  • Low cohesion: MtApiClient (LCOM4 5) MtApi/MtApiClient.cs:12 — MtApiClient's methods fall into 5 groups that share no field and call none of each other, against a bar of more than 3 for this run (LCOM4, configurable — your repository's bar is the one quoted here). Each group is a set of methods reachable from one another through shared fields or direct calls, so 5 groups means the type has that many internally-connected clusters with nothing tying them together. Types whose shape makes a high count expected — and which would otherwise dominate this list — are excluded before this row is raised, so this is a genuine split candidate rather than a metric reading. It is still a shape, not a defect: confirm the groups match responsibilities you can name before splitting.
X20 · Mistyped argument guard · Argument guard throws the exception its own condition disproves · ×2
  • Argument guard throws the exception its own condition disproves MtApi5/MtApi5Client.cs:104 — The guard on line 103 rejects `host` and line 104 reports that rejection as `ArgumentNullException` — but the condition's own test `string.IsNullOrEmpty(host)` is true of a value that is NOT null: it is satisfied by an EMPTY `host`, and on that path `host` was already proven non-null by the very expression that decided it (`||` short-circuits, so the null test to its left had to be false to get here). So a caller who passes a valid empty argument is told a parameter was null. That is not a wording problem: the exception type is the contract. A caller catching `ArgumentNullException` to handle a real null swallows this case with it, and whoever reads the stack trace later is told a failure the source disproves. .NET separates the two on purpose — `ArgumentNullException.ThrowIfNull` and `ArgumentException.ThrowIfNullOrEmpty` are two helpers because they are two failures. Throw `ArgumentException` (or `ArgumentOutOfRangeException` for a bound) for what the condition actually tests, or split the guard and throw each on its own condition.
  • Argument guard throws the exception its own condition disproves MTApiService/MtClient.cs:27 — The guard on line 26 rejects `host` and line 27 reports that rejection as `ArgumentNullException` — but the condition's own test `string.IsNullOrEmpty(host)` is true of a value that is NOT null: it is satisfied by an EMPTY `host`, and on that path `host` was already proven non-null by the very expression that decided it (`||` short-circuits, so the null test to its left had to be false to get here). So a caller who passes a valid empty argument is told a parameter was null. That is not a wording problem: the exception type is the contract. A caller catching `ArgumentNullException` to handle a real null swallows this case with it, and whoever reads the stack trace later is told a failure the source disproves. .NET separates the two on purpose — `ArgumentNullException.ThrowIfNull` and `ArgumentException.ThrowIfNullOrEmpty` are two helpers because they are two failures. Throw `ArgumentException` (or `ArgumentOutOfRangeException` for a bound) for what the condition actually tests, or split the guard and throw each on its own condition.
X3 · Exception handling · Swallowed exception (caught, then discarded) · ×2
  • Swallowed exception (caught, then discarded) MtApi5/MtConverters.cs:25 — `catch (Exception)` does nothing with the exception it caught — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch. Log it through whatever this codebase already uses to report problems, or let it propagate; if one specific failure genuinely cannot matter, catch exactly that exception type and say why in a comment on the catch.
  • Swallowed exception (caught, then discarded) MtApi5/MtConverters.cs:57 — `catch (Exception)` does nothing with the exception it caught — the body neither logs it, rethrows it, nor even names it, so the failure is discarded as completely as by an empty catch. Log it through whatever this codebase already uses to report problems, or let it propagate; if one specific failure genuinely cannot matter, catch exactly that exception type and say why in a comment on the catch.
C2 · Access Controls · Unauthorized service host · ×1
  • Unauthorized service host — Service contract 'IMtApi' is hosted by a ServiceHost this repository opens itself — every operation on it is reachable by any caller that can connect. (MTApiService/MtServer.cs:119) Nothing in the source decides WHO may invoke those operations — no [PrincipalPermission], no ServiceAuthorizationManager, and no guard method that refuses the caller. A local IPC transport is not an access control: it authenticates the connection, it does not authorize the command.
D1 · Cyclomatic Complexity · MtQuoteExpert.runController (cyclomatic 35) · ×1
  • MtQuoteExpert.runController (cyclomatic 35) TestClients/TestServer/MtQuoteExpert.cs.cs:143 — MtQuoteExpert.runController has cyclomatic complexity 35 (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.
D1 · Cyclomatic Complexity · MtRpcClient.OnReceive (cyclomatic 17) · ×1
  • MtRpcClient.OnReceive (cyclomatic 17) REDACTED:196 — MtRpcClient.OnReceive 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.
D18 · Solution Shape · Build failed · ×1
  • Build failed — The target solution did not build cleanly (errors: 7), which caps Solution Shape at 3/10 — the most basic shape signal is that it compiles. First errors: MSB4278: The imported file "$(VCTargetsPath)/Microsoft.Cpp.Default.props" does not exist and appears to be part of a Visual Studio component. This file may require MSBuild.exe in order to be imported successfully, and so may fail to build in the dotnet CLI.; CS0246: The type or namespace name 'MtApi5' could not be found (are you missing a using directive or an assembly reference?).
D2 · Cognitive Complexity · MtQuoteExpert.runController (cognitive 76) · ×1
  • MtQuoteExpert.runController (cognitive 76) TestClients/TestServer/MtQuoteExpert.cs.cs:143 — MtQuoteExpert.runController has cognitive complexity 76 (threshold 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · MtRpcClient.OnReceive (cognitive 16) · ×1
  • MtRpcClient.OnReceive (cognitive 16) REDACTED:196 — MtRpcClient.OnReceive has cognitive complexity 16 (threshold 15). To reduce it, split the body into named stages: move each independent step or branch into its own named function so the body reads as a short sequence of named calls rather than one long body.
D2 · Cognitive Complexity · Program.printCharts (cognitive 16) · ×1
  • Program.printCharts (cognitive 16) TestClients/TestServer/Program.cs:152 — Program.printCharts has cognitive complexity 16 (threshold 15). To reduce it, flatten the nesting: invert conditions into early returns or guard clauses so the happy path stays at one level, and lift the deepest nested block into its own named function.
D29 · Static Analysis (SAST) · REDACTED · ×1
  • REDACTED
D30 · Dependency Vulnerabilities · Medium CVE · ×1
  • REDACTED
D4 · Code Duplication · Edited copy of a member (66 corresponding lines) · ×1
  • Edited copy of a member (66 corresponding lines) MtApi5/MtApi5Client.cs:102 — MtApi5/MtApi5Client.cs:102-167 | MtApi/MtApiClient.cs:3032-3106 — These two members are one piece of code written twice and then edited apart: 66 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (18 corresponding lines) · ×1
  • Edited copy of a member (18 corresponding lines) MtApi5/MtApi5Client.cs:1858 — MtApi5/MtApi5Client.cs:1858-1875 | MtApi/MtApiClient.cs:1885-1904 — These two members are one piece of code written twice and then edited apart: 18 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (25 corresponding lines) · ×1
  • Edited copy of a member (25 corresponding lines) MtApi5/MtApi5Client.cs:3419 — MtApi5/MtApi5Client.cs:3419-3443 | MtApi/MtApiClient.cs:3250-3278 — These two members are one piece of code written twice and then edited apart: 25 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 40+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 40+ corresponding lines) MTApiService/MtRegistryManager.cs:45 — MTApiService/MtRegistryManager.cs:45-85 | MTApiService/MtRegistryManager.cs:171-216 | MTApiService/MtRegistryManager.cs:219-258 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 40 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (26 corresponding lines) · ×1
  • Edited copy of a member (26 corresponding lines) MtApi5/MtApi5Client.cs:3561 — MtApi5/MtApi5Client.cs:3561-3586 | MtApi/MtApiClient.cs:3109-3135 — These two members are one piece of code written twice and then edited apart: 26 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 14+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 14+ corresponding lines) MtApi5/MtApi5Client.cs:1061 — MtApi5/MtApi5Client.cs:1061-1074 | MtApi5/MtApi5Client.cs:1085-1098 | MtApi5/MtApi5Client.cs:1109-1123 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 14 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (35 corresponding lines) · ×1
  • Edited copy of a member (35 corresponding lines) MtApi5/MtApi5Client.cs:3594 — MtApi5/MtApi5Client.cs:3594-3628 | MtApi/MtApiClient.cs:3143-3177 — These two members are one piece of code written twice and then edited apart: 35 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (31 corresponding lines) · ×1
  • Edited copy of a member (31 corresponding lines) MTApiService/MtService.cs:62 — MTApiService/MtService.cs:62-99 | MTApiService/MtService.cs:102-132 — These two members are one piece of code written twice and then edited apart: 31 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (4 members, 12+ corresponding lines) · ×1
  • Edited copies of one member (4 members, 12+ corresponding lines) MtApi/MtApiClient.cs:1858 — MtApi/MtApiClient.cs:1858-1870 | MtApi5/MtApi5Client.cs:1657-1674 | MtApi5/MtApi5Client.cs:1685-1702 | MtApi5/MtApi5Client.cs:1832-1843 — These 4 members are one piece of code written 4 times and then edited apart: every two of them correspond over at least 12 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 4 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (10 corresponding lines) · ×1
  • Edited copy of a member (10 corresponding lines) MtApi/MtApiClient.cs:346 — MtApi/MtApiClient.cs:346-355 | MtApi/MtApiClient.cs:358-367 — These two members are one piece of code written twice and then edited apart: 10 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 15+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 15+ corresponding lines) MtApi5/MtApi5Client.cs:252 — MtApi5/MtApi5Client.cs:252-266 | MtApi5/MtApi5Client.cs:281-295 | MtApi5/MtApi5Client.cs:361-375 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 15 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (24 corresponding lines) · ×1
  • Edited copy of a member (24 corresponding lines) MTApiService/MtRegistryManager.cs:261 — MTApiService/MtRegistryManager.cs:261-298 | MTApiService/MtRegistryManager.cs:301-324 — These two members are one piece of code written twice and then edited apart: 24 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 10+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 10+ corresponding lines) MtApi5/MtApi5Client.cs:759 — MtApi5/MtApi5Client.cs:759-768 | MtApi5/MtApi5Client.cs:826-837 | MtApi5/MtApi5Client.cs:851-862 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 10 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 20+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 20+ corresponding lines) MTApiService/MtAdapter.cs:101 — MTApiService/MtAdapter.cs:101-120 | MTApiService/MtAdapter.cs:123-142 | MTApiService/MtAdapter.cs:145-164 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 20 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (6 members, 9+ corresponding lines) · ×1
  • Edited copies of one member (6 members, 9+ corresponding lines) MtApi/MtApiClient.cs:256 — MtApi/MtApiClient.cs:256-265 | MtApi/MtApiClient.cs:269-278 | MtApi/MtApiClient.cs:282-290 | MtApi/MtApiClient.cs:294-302 | MtApi/MtApiClient.cs:305-313 | MtApi/MtApiClient.cs:439-447 — These 6 members are one piece of code written 6 times and then edited apart: every two of them correspond over at least 9 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 6 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (5 corresponding lines) · ×1
  • Edited copy of a member (5 corresponding lines) MtApi5/MtApi5Client.cs:3269 — MtApi5/MtApi5Client.cs:3269-3273 | MtApi/MtApiClient.cs:1053-1057 — These two members are one piece of code written twice and then edited apart: 5 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (40 lines × 2) · ×1
  • Duplicated block (40 lines × 2) MtApi/EnumChartPropertyInteger.cs:13 — MtApi/EnumChartPropertyInteger.cs:13-52 | MtApi5/Mt5Enums.cs:68-107 — 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.
D4 · Code Duplication · Duplicated block (33 lines × 2) · ×1
  • Duplicated block (33 lines × 2) MtApi/MtCommandType.cs:229 — MtApi/MtCommandType.cs:229-261 | MtApi5/MtProtocol/Mt5CommandType.cs:180-212 — 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.
D4 · Code Duplication · Duplicated block (25 lines × 2) · ×1
  • Duplicated block (25 lines × 2) MtApi/EnumSymbolInfoDouble.cs:20 — MtApi/EnumSymbolInfoDouble.cs:20-44 | MtApi5/Mt5Enums.cs:238-262 — 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.
D4 · Code Duplication · Duplicated block (24 lines × 2) · ×1
  • Duplicated block (24 lines × 2) MtApi/MtTypes.cs:22 — MtApi/MtTypes.cs:22-45 | MtApi5/Mt5Enums.cs:10-33 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice. Read the line range as the matched WINDOW rather than a finished unit: at `MtApi/MtTypes.cs:22` it does not close everything it opens, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (19 lines × 2) · ×1
  • Duplicated block (19 lines × 2) MtApi/EnumTerminalInfoInteger.cs:5 — MtApi/EnumTerminalInfoInteger.cs:5-23 | MtApi5/Mt5Enums.cs:134-152 — 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 `MtApi/EnumTerminalInfoInteger.cs:5` 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.
D4 · Code Duplication · Duplicated block (17–18 lines × 2) · ×1
  • Duplicated block (17–18 lines × 2) MtApi/MtCommandType.cs:198 — MtApi/MtCommandType.cs:198-215 | MtApi5/MtProtocol/Mt5CommandType.cs:115-131 — the copies span different directories, so extracting a shared function means choosing where it lives: put it somewhere both call sites can already reach — a location they all depend on today, or a new shared one if there is none — and call it from each site; until then, every change has to be made twice.
D4 · Code Duplication · Duplicated block (10 lines × 2) · ×1
  • Duplicated block (10 lines × 2) MtApi5/MtApi5Client.cs:253 — MtApi5/MtApi5Client.cs:253-262 | MtApi5/MtApi5Client.cs:282-291 — 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.
D4 · Code Duplication · Edited copies of one member (3 members, 24+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 24+ corresponding lines) TestClients/TestApiClientUI/Form1.cs:953 — TestClients/TestApiClientUI/Form1.cs:953-976 | TestClients/TestApiClientUI/Form1.cs:980-1003 | TestClients/TestApiClientUI/Form1.cs:1007-1030 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 24 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (14 corresponding lines) · ×1
  • Edited copy of a member (14 corresponding lines) TestClients/TestApiClientUI/Form1.cs:771 — TestClients/TestApiClientUI/Form1.cs:771-784 | TestClients/TestApiClientUI/Form1.cs:788-807 — These two members are one piece of code written twice and then edited apart: 14 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (34 corresponding lines) · ×1
  • Edited copy of a member (34 corresponding lines) TestClients/TestApiClientUI/Form1.cs:398 — TestClients/TestApiClientUI/Form1.cs:398-434 | TestClients/TestApiClientUI/Form1.cs:888-921 — These two members are one piece of code written twice and then edited apart: 34 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copies of one member (5 members, 28+ corresponding lines) · ×1
  • Edited copies of one member (5 members, 28+ corresponding lines) TestClients/MtApi5TestClient/ViewModel.cs:693 — TestClients/MtApi5TestClient/ViewModel.cs:693-720 | TestClients/MtApi5TestClient/ViewModel.cs:723-750 | TestClients/MtApi5TestClient/ViewModel.cs:753-780 | TestClients/MtApi5TestClient/ViewModel.cs:783-810 | TestClients/MtApi5TestClient/ViewModel.cs:813-841 — These 5 members are one piece of code written 5 times and then edited apart: every two of them correspond over at least 28 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 5 times and the copies will drift further apart.
D4 · Code Duplication · Edited copies of one member (3 members, 29+ corresponding lines) · ×1
  • Edited copies of one member (3 members, 29+ corresponding lines) TestClients/MtApi5TestClient/ViewModel.cs:980 — TestClients/MtApi5TestClient/ViewModel.cs:980-1008 | TestClients/MtApi5TestClient/ViewModel.cs:1011-1039 | TestClients/MtApi5TestClient/ViewModel.cs:1042-1070 — These 3 members are one piece of code written 3 times and then edited apart: every two of them correspond over at least 29 lines, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below: the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain. Factor the shared implementation out once and have all of them call it with their differences as parameters or as an injected step, or, where the difference is systematic, generate them from one template. Left alone, the next edit has to be made 3 times and the copies will drift further apart.
D4 · Code Duplication · Edited copy of a member (28 corresponding lines) · ×1
  • Edited copy of a member (28 corresponding lines) TestClients/TestServer/Program.cs:27 — TestClients/TestServer/Program.cs:27-54 | TestClients/TestServer/Program.cs:57-87 — These two members are one piece of code written twice and then edited apart: 28 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Edited copy of a member (12 corresponding lines) · ×1
  • Edited copy of a member (12 corresponding lines) TestClients/TestApiClientUI/Form1.cs:811 — TestClients/TestApiClientUI/Form1.cs:811-823 | TestClients/TestApiClientUI/Form1.cs:827-838 — These two members are one piece of code written twice and then edited apart: 12 consecutive lines correspond almost exactly, broken only by small local edits. Most of that correspondence is NOT reported as duplicated blocks below — the edits cut it into fragments and only the largest of them clear the block floor, so the rows below understate it. The repair is at the members' grain — factor the shared implementation into one the two call with their differences as parameters or as an injected step, or, where the difference is systematic (an extra return value, one transport against another), generate one from the other. Left alone, the next edit has to be made twice and the two will drift further apart.
D4 · Code Duplication · Duplicated block (14 lines × 3) · ×1
  • Duplicated block (14 lines × 3) TestClients/TestApiClientUI/Form1.cs:963 — TestClients/TestApiClientUI/Form1.cs:963-976 | TestClients/TestApiClientUI/Form1.cs:990-1003 | TestClients/TestApiClientUI/Form1.cs:1017-1030 — 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 `TestClients/TestApiClientUI/Form1.cs:963` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D4 · Code Duplication · Duplicated block (7 lines × 2) · ×1
  • Duplicated block (7 lines × 2) TestClients/TestApiClientUI/Form1.cs:778 — TestClients/TestApiClientUI/Form1.cs:778-784 | TestClients/TestApiClientUI/Form1.cs:796-802 — 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 `TestClients/TestApiClientUI/Form1.cs:778` it runs out through the closing brace of the declaration holding it — the window is that declaration's tail, not a fragment that begins part-way through something, so those exact lines cannot be lifted as they stand — widen the region to the smallest complete statement or declaration that contains it, and extract that.
D5 · Coupling · Off the main sequence · ×1
  • Off the main sequence: MtClient MtClient/MtClient.csproj:1 — MtClient: abstractness 0.13, instability 0.00, distance 0.88 — zone of pain — concrete and depended on by 2 project(s), so it's rigid to change.
IC1 · Incompleteness & stubs · Empty method body · ×1
  • Empty method body — does nothing with its inputs TestClients/TestServer/MetaTrader.cs:185 — `instrument_InstrumentUpdate` takes parameters but its body is empty — it accepts inputs and does nothing. Either implement it or remove it.
P1 · CI/CD gates · No CI pipeline · ×1
  • No CI pipeline — No CI workflow found (.github/workflows, azure-pipelines.yml, .gitlab-ci.yml, …) — changes aren't gated by an automated build/test.
X1 · Async correctness · Blocking `WaitHandle.WaitOne` inside an `async` method · ×1
  • Blocking `WaitHandle.WaitOne` inside an `async` method REDACTED:132 — `WaitHandle.WaitOne` parks the thread until another thread signals it — inside a method that is already `async`, the wait should be awaitable (a `TaskCompletionSource`, `SemaphoreSlim.WaitAsync`, or `WaitHandle` bridged with `Task.Factory.FromAsync`).
Minor — 98 finding(s)
IC1 · Incompleteness & stubs · Commented-out code · ×34
  • Commented-out code MTApiService/LogConfigurator.cs:93 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:18 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:20 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:22 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:26 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:27 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:31 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:32 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:34 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:38 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:42 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:45 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code MtApiSetupActions/CustomAction.cs:50 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/MtApi5TestClient/ViewModel.cs:1121 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/MtApi5TestClient/ViewModel.cs:1122 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestApiClientUI/Form1.cs:577 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:89 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:106 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:110 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:111 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:196 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:200 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:201 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:202 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • Commented-out code TestClients/TestServer/MtQuoteExpert.cs.cs:207 — A line of code has been commented out rather than removed — dead weight that rots and confuses. Delete it (version control remembers).
  • + 9 more in this group — see findings.md.
P2 · Observability · Console output used as the logging channel · ×24
  • Console output used as the logging channel TestClients/TestServer/Program.cs:34 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 34 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:37 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 37 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:49 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 49 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:62 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 62 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:68 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 68 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:82 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 82 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:92 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 92 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:122 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 122 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:125 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 125 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:137 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 137 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:158 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 158 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:171 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 171 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:177 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 177 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:180 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 180 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:193 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 193 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:194 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 194 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:195 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 195 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:207 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 207 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:208 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 208 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:209 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 209 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:210 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 210 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:211 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 211 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:233 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 233 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
  • Console output used as the logging channel TestClients/TestServer/Program.cs:240 — `TestClients/TestServer/Program.cs` reports through `Console.Write…` at line 240 although other files in its project log through a logger. Console lines carry no level, category or structured properties and never reach the log pipeline or its exporters.
D24 · Comment Value · redundant comment · ×19
  • redundant comment MTApiService/Properties/AssemblyInfo.cs:5 — "General Information about an assembly is controlled through the following set of attributes. Change these attribute values to modify the information associated …" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment MTApiService/Properties/AssemblyInfo.cs:17 — "Setting ComVisible to false makes the types in this assembly not visible to COM components. If you need to access a type in this assembly from COM, set the ComV …" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment MTApiService/Properties/AssemblyInfo.cs:22 — "The following GUID is for the ID of the typelib if this project is exposed to COM" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment MTApiService/Properties/AssemblyInfo.cs:25 — "Version information for an assembly consists of the following four values: Major Version Minor Version Build Number Revision You can specify all the values or y …" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment MtApi/Monitors/TimeframeTradeMonitor.cs:15 — "Sync-Trigger set to true, to have the same behavior as before" repeats the code it sits on: 4 of its 5 words (sync, trigger, set, true) are already in `SyncTrigger = true; //Sync-Trigger set to true, to have the same behavior as before`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment MtApi/Monitors/TimerTradeMonitor.cs:31 — "Sync-Trigger set to true, to have the same behavior as before" repeats the code it sits on: 4 of its 5 words (sync, trigger, set, true) are already in `SyncTrigger = true; //Sync-Trigger set to true, to have the same behavior as before`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment MtApi/Monitors/TradeMonitor.cs:82 — "check open orders" repeats the code it sits on: 3 of its 3 words (check, open, orders) are already in `openedOrders = tradesOrders.Where(to => prevOrders.Find(a => a.Ticket == to.Ticket) == null).ToList();`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment MtApi5/MtApi5Client.cs:2305 — "Count the additional coordinates" repeats the code it sits on: 3 of its 3 words (count, additional, coordinates) are already in `int iAdditionalCoordinates = (listOfCoordinates != null) ? listOfCoordinates.Count : 0;`. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestApiClientUI/Form1.cs:1121 — 7 comments in this file only repeat the code they sit on (lines 1121, 1181, 1274, 1330, 1363, 1412, 1419), for example "SymbolInfoTick". Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestMtApi/TestMtApi/Form1.vb:9 — "This call is required by the designer." is Visual Studio form constructor template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestMtApi/TestMtApi/Form1.vb:12 — "Add any initialization after the InitializeComponent() call." is Visual Studio form constructor template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestMtApi/TestMtApi/My Project/AssemblyInfo.vb:5 — "General Information about an assembly is controlled through the following set of attributes. Change these attribute values to modify the information associated …" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestMtApi/TestMtApi/My Project/AssemblyInfo.vb:9 — "Review the values of the assembly attributes" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestMtApi/TestMtApi/My Project/AssemblyInfo.vb:20 — "The following GUID is for the ID of the typelib if this project is exposed to COM" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestMtApi/TestMtApi/My Project/AssemblyInfo.vb:23 — "Version information for an assembly consists of the following four values: Major Version Minor Version Build Number Revision You can specify all the values or y …" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestServer/Properties/AssemblyInfo.cs:5 — "General Information about an assembly is controlled through the following set of attributes. Change these attribute values to modify the information associated …" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestServer/Properties/AssemblyInfo.cs:17 — "Setting ComVisible to false makes the types in this assembly not visible to COM components. If you need to access a type in this assembly from COM, set the ComV …" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestServer/Properties/AssemblyInfo.cs:22 — "The following GUID is for the ID of the typelib if this project is exposed to COM" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
  • redundant comment TestClients/TestServer/Properties/AssemblyInfo.cs:25 — "Version information for an assembly consists of the following four values: Major Version Minor Version Build Number Revision You can specify all the values or y …" is Visual Studio AssemblyInfo template text, left in place. Delete it, or replace it with what the code cannot say (why it is done here, a constraint, or a consequence).
X10 · Duplicated predicate · Duplicated predicate · ×6
  • Duplicated predicate MtApi5/MtApi5Client.cs:3555 — `e == null || string.IsNullOrEmpty(e.Instrument)` appears character-identically in 2 files — MtApi/MtApiClient.cs, MtApi5/MtApi5Client.cs. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate MtApi5/MtApi5Client.cs:3526 — `e == null || string.IsNullOrEmpty(e.Instrument) || e.Tick == null` appears character-identically in 2 files — MtApi/MtApiClient.cs, MtApi5/MtApi5Client.cs. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate MtApi5/MtApi5Client.cs:3514 — `e == null || string.IsNullOrEmpty(e.Symbol)` appears character-identically in 2 files — MtApi/MtApiClient.cs, MtApi5/MtApi5Client.cs. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate MtApi5/MtApi5Client.cs:3468 — `q == null || string.IsNullOrEmpty(q.Instrument) || q.Tick == null` appears character-identically in 2 files — MtApi/MtApiClient.cs, MtApi5/MtApi5Client.cs. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate MtApi5/MtApi5Client.cs:1861 — `response != null && response.Result != null && response.Result.TryGetValue("SubWindow", out object? mtSubWindow) && response.Result.TryGetVa…` appears character-identically in 2 files — MtApi/MtApiClient.cs, MtApi5/MtApi5Client.cs. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
  • Duplicated predicate MtApi5/MtApi5Client.cs:1837 — `response != null && response.Result != null && response.Result.TryGetValue("X", out x) && response.Result.TryGetValue("Y", out y)` appears character-identically in 2 files — MtApi/MtApiClient.cs, MtApi5/MtApi5Client.cs. It is one line, so the duplication detector's token window never sees it; the copies drift when only one is corrected. Give the condition a name and one home.
D27 · Navigability · Pass-through layer · ×3
  • Pass-through layer MtApi5/MtApi5Client.cs:3637 — RpcClientLogger: all 4 public methods forward their arguments unchanged to logger_ and add no behaviour — an extra hop (and usually an extra interface) to trace through. Call logger_ directly, or give the layer a job.
  • Pass-through layer MtApi/MtApiClient.cs:3347 — RpcClientLogger: all 4 public methods forward their arguments unchanged to logger_ and add no behaviour — an extra hop (and usually an extra interface) to trace through. Call logger_ directly, or give the layer a job.
  • Pass-through layer MTApiService/LogConfigurator.cs:11 — MtLog: all 5 public methods forward their arguments unchanged to _log and add no behaviour — an extra hop (and usually an extra interface) to trace through. Call _log directly, or give the layer a job.
D34 · Knowledge Freshness · Orphaned file · ×3
  • Orphaned file MtApi/Monitors/MtMonitorBase.cs:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file MtApi/Monitors/OrderModification/ModifiedOrdersMonitor.cs:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
  • Orphaned file MtApi/Monitors/Triggers/TimeElapsedTrigger.cs:1 — No one still active in this repository holds living knowledge of this file: everyone who made a meaningful change to it has gone quiet, or what the current team did to it (moves, reformatting, log-level or import edits, renames) never needed understanding it. If it breaks, no one currently understands it. Attach the read to the next change that touches it: have a second person review that change, and leave behind a short comment or test recording what the file is for.
D18 · Solution Shape · Thin analysable surface across projects · ×2
  • Thin analysable surface across projects: MtApiSetupActions MtApiSetupActions/MtApiSetupActions.csproj — 2 project(s) carry only a thin slice of real code; `MtApiSetupActions` has 18 significant line(s). The mean analysable-surface weight is 89 %; this project lowers Solution Shape by about 0.64 point(s). Consolidate it or grow it into a substantial, well-scoped assembly.
  • Thin analysable surface across projects: TestMtApi TestClients/TestMtApi/TestMtApi/TestMtApi.vbproj — 2 project(s) carry only a thin slice of real code; `TestMtApi` has 36 significant line(s). The mean analysable-surface weight is 89 %; this project lowers Solution Shape by about 0.28 point(s). Consolidate it or grow it into a substantial, well-scoped assembly.
D34 · Knowledge Freshness · Orphaned files with no living knowledge · ×1
  • Orphaned files with no living knowledge — 3 of 33 analysed file(s) have no living knowledge left — their last meaningful change has decayed away, so if one breaks, no one currently understands it (counted over production source files of roughly 2,400 bytes or more, excluding vendored, generated, example/demo and scaffolding-template trees and test files identified by path convention, largest first; 33 of the 141 production source files in this repository met that bar). None is large enough to earn a read-through of its own, so this row stands in for the per-file rows rather than raising one each — most significant first: MtApi/Monitors/MtMonitorBase.cs, MtApi/Monitors/OrderModification/ModifiedOrdersMonitor.cs, MtApi/Monitors/Triggers/TimeElapsedTrigger.cs. 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.
M2 · Architecture documentation · No ADRs · ×1
  • No ADRs — No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
P3 · Security & performance tooling · No SAST · ×1
  • No SAST — No static application security testing detected. For this repository's stack, add CodeQL's csharp pack, or a .NET security analyzer package (or `semgrep --config=auto`, which runs on any language) — this repository has no CI pipeline yet, so run it locally to clear the existing findings, then make it a step of the first workflow you add so a regression fails the build. What was searched, so you can tell an absence from a miss: the 0 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
P3 · Security & performance tooling · No dependency-update automation · ×1
  • No dependency-update automation MtApi/MtApi.csproj:11 — `MtApi/MtApi.csproj` declares packages, and nothing in the repository keeps them current: no Dependabot or Renovate configuration that schedules updates, and no dependency-review gate on pull requests. A pinned dependency stays at the version it was added at until someone notices — including after an advisory is published against it. Add a `.github/dependabot.yml` with one `package-ecosystem` entry per ecosystem the tree uses (or an enabled `renovate.json`), and gate pull requests with `actions/dependency-review-action`.
P6 · Release Hygiene · No changelog · ×1
  • No changelog — No CHANGELOG/HISTORY/RELEASES file — what shipped when isn't easy to reconstruct for support or audit. (Versioning/tagging makes releases traceable, but a changelog records the what.)
X2 · Cancellation propagation · Not all async methods take a CancellationToken · ×1
  • Not all async methods take a CancellationToken — Only 0/105 async methods accept a CancellationToken, so in-flight work can't be stopped early when the caller gives up — whatever ends it in your host (shutdown signal, timeout, abandoned request, user cancel). Thread a token through the call chain and honour it at each await and loop; where a method genuinely cannot be interrupted, omitting it is a deliberate choice — judge against your hosting model.
X7 · Silent fallback defaults · Silent fallback default in catch · ×1
  • Silent fallback default in catch MTApiService/MtRegistryManager.cs:155 — `ExportKey` swallows every exception into `return false;` — a data error becomes a silent behavior change with no trail. Log the failure or let validation throw.
Minor — 2 finding(s)
D24 · Comment Value · doc comments repeat the names · ×2
  • doc comments repeat the names MtApi/Monitors/MtMonitorBase.cs:14 — 31 of 211 documented parameters and 6 of 154 summaries in `MtApi` only repeat the member or parameter name (e.g. "ApiClient" for `ApiClient`). Delete the restating tags, or add what the name does not say.
  • doc comments repeat the names MtApi5/MtApi5Client.cs:331 — 67 of 639 documented parameters and 4 of 224 summaries in `MtApi5` only repeat the member or parameter name (e.g. "Open price." for `priceOpen`). Delete the restating tags, or add what the name does not say.

Appendix B — Reproduction & audit trail

Every external tool invocation behind a deep-scan dimension — the tool, its captured version, the exact command, how many findings it yielded, and a link to the retained raw output. To reproduce any finding: check out the same commit and run the command shown (repo-relative — never an absolute scratch path). The complete raw scanner output is retained verbatim under artifacts/raw/ (indexed in artifacts/raw/index.json); per-invocation exit codes and wall-clock durations are in sidecar.json — kept out of this table so the rendered report stays byte-identical across runs of the same commit.

DimensionToolVersionCommandFindingsRaw output
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=0 --max-count=200" --report-format json --report-path /tmp/watchdog-gitleaks-2438dfb140f64ddfac2fc6eefceceeaa/history.json --exit-code 0 --source .0artifacts/raw/gitleaks-history.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=200 --max-count=242" --report-format json --report-path /tmp/watchdog-gitleaks-2438dfb140f64ddfac2fc6eefceceeaa/history-1.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-1.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --log-opts "--full-history --all --skip=442 --max-count=29" --report-format json --report-path /tmp/watchdog-gitleaks-2438dfb140f64ddfac2fc6eefceceeaa/history-2.json --exit-code 0 --source .0artifacts/raw/gitleaks-history-2.json
D28 · Secrets (history)gitleaks—gitleaks detect --no-git --no-banner --config /opt/gitleaks-rules/canine-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-2438dfb140f64ddfac2fc6eefceceeaa/tree.json --exit-code 0 --source .0artifacts/raw/gitleaks-tree.json
D29 · Static Analysis (SAST)semgrep—semgrep --config /opt/semgrep-rules/security-audit.yml --config /opt/semgrep-rules/owasp-top-ten.yml --config /opt/semgrep-rules/canine-sast.yml --json --quiet --timeout 10 --timeout-threshold 3 --metrics off --exclude *.arrow --exclude *.avro --exclude *.csv --exclude *.dat --exclude *.db --exclude *.feather --exclude *.geojson --exclude *.h5 --exclude *.hdf5 --exclude *.jsonl --exclude *.log --exclude *.ndjson --exclude *.npy --exclude *.npz --exclude *.orc --exclude *.parquet --exclude *.pickle --exclude *.pkl --exclude *.psv --exclude *.sqlite --exclude *.sqlite3 --exclude *.tfrecord --exclude *.tsv --exclude *.txt --exclude thirdparty/include/boost/compatibility --exclude thirdparty/include/boost/fusion/algorithm/iteration/detail/preprocessed --exclude thirdparty/include/boost/fusion/algorithm/transformation/detail/preprocessed --exclude thirdparty/include/boost/fusion/container/deque/detail/cpp03/preprocessed --exclude thirdparty/include/boost/fusion/container/generation/detail --exclude thirdparty/include/boost/fusion/container/list/detail/cpp03/preprocessed --exclude thirdparty/include/boost/fusion/container/map/detail/cpp03/preprocessed --exclude thirdparty/include/boost/fusion/container/set/detail/cpp03/preprocessed --exclude thirdparty/include/boost/fusion/container/vector/detail/cpp03/preprocessed --exclude thirdparty/include/boost/fusion/tuple/detail/preprocessed --exclude thirdparty/include/boost/math/tools/detail --exclude thirdparty/include/boost/mpl/aux_/preprocessed --exclude thirdparty/include/boost/mpl/list/aux_/preprocessed --exclude thirdparty/include/boost/mpl/map/aux_/preprocessed --exclude thirdparty/include/boost/mpl/set/aux_/preprocessed --exclude thirdparty/include/boost/mpl/vector/aux_/preprocessed --exclude thirdparty/include/boost/qvm/gen --exclude thirdparty/include/boost/spirit/home/support/char_encoding/unicode .1artifacts/raw/semgrep.json
D30 · Dependency Vulnerabilitiesnuget—nuget: not applicable — nuget: the solution did not restore on the analyzer's .NET SDK (an SDK/target-framework/restore mismatch, common for an older codebase), so there was no restored dependency graph to scan0—
D30 · Dependency Vulnerabilitiesosv-scanner—osv-scanner --format json --recursive --experimental-disable-plugins transitivedependency/requirements --experimental-disable-plugins dotnet/csproj --experimental-disable-plugins dotnet/nugetcpm . /tmp/codehealth-osv-sbom-2acbb28b204b4965b5d64ee8258f970f1artifacts/raw/osv-scanner.json
D31 · IaC & Container Securitytrivy—trivy: not applicable — No Infrastructure-as-Code or container manifests found (Dockerfile, Docker Compose, Terraform, Kubernetes/Helm, CloudFormation, ARM, Bicep, Ansible); nothing to scan.0—
D32 · Data Compliance (PII/GDPR)semgrep—semgrep: not applicable — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that. semgrep could not parse 11 file(s) — `MtApi/Monitors/AvailabilityOrdersEventArgs.cs`, `MtApi/MtApiClient.cs`, `MtApi/MtConnectionEventArgs.cs`, `MtApi/MtExecutionException.cs`, `MtApi/MtQuoteEventArgs.cs`, … (+6 more) — so the PII/GDPR sweep did not cover the unparsed regions of them; rows reported elsewhere in those files are real.0—
D36 · Supply-chain Provenance & Signingprovenance—provenance: not applicable — No CI/build pipeline found (.github/.forgejo/.gitea workflows, .circleci, .buildkite, .woodpecker, .teamcity, .gitlab-ci.yml, .travis.yml, bitbucket-pipelines.yml, .drone.yml, .cirrus.yml, .woodpecker.yml, appveyor.yml, azure-pipelines*.yml, .pipelines/, .vsts-ci/, .azuredevops/, Jenkinsfile); there is no build to attest provenance for.0—
D37 · Vulnerability-disclosure Policydisclosure—disclosure: not applicable — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.0—
D40 · Network Egress Confinementruntime-hardening—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.0—
D41 · Kernel & Syscall Confinementruntime-hardening—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.0—
D42 · Runtime Threat Enforcementruntime-hardening—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—
D43 · Malicious Dependenciesosv-scanner—osv-scanner --format json --recursive --experimental-disable-plugins transitivedependency/requirements --experimental-disable-plugins dotnet/csproj --experimental-disable-plugins dotnet/nugetcpm . /tmp/codehealth-osv-sbom-2acbb28b204b4965b5d64ee8258f970f0artifacts/raw/osv-scanner.json

Run 01a1eb76-c65d-7ebd-8a77-2b74aa547172 · every finding is also locatable in findings.md, and the complete scoring record (with exit codes + durations) in sidecar.json.

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.

⬇ Findings, MITRE CWE-tagged .sarif⬇ Health changelog .md